Merge branch 'master' of github.com:bkaradzic/bgfx

This commit is contained in:
Branimir Karadžić 2018-11-25 20:11:27 -08:00
commit b50c64289a
9 changed files with 38 additions and 37 deletions

View File

@ -346,11 +346,11 @@ public:
const double freq = double(bx::getHPFrequency() );
float time = (float)( (now-m_timeOffset)/freq);
// Reference:
// Weighted, Blended Order-Independent Transparency
// http://jcgt.org/published/0002/02/09/
// http://casual-effects.blogspot.com/2014/03/weighted-blended-order-independent.html
// Reference(s):
// - Weighted, Blended Order-Independent Transparency
// https://web.archive.org/save/http://jcgt.org/published/0002/02/09/
// https://web.archive.org/web/20181126040455/http://casual-effects.blogspot.com/2014/03/weighted-blended-order-independent.html
//
const bx::Vec3 at = { 0.0f, 0.0f, 0.0f };
const bx::Vec3 eye = { 0.0f, 0.0f, -7.0f };

View File

@ -4,13 +4,11 @@
*/
/*
* References:
*
* Experiments in GPU-based occlusion culling
* https://web.archive.org/web/20180920045301/https://interplayoflight.wordpress.com/2017/11/15/experiments-in-gpu-based-occlusion-culling/
*
* Experiments in GPU-based occlusion culling part 2: MultiDrawIndirect and mesh lodding
* https://web.archive.org/web/20180920045332/https://interplayoflight.wordpress.com/2018/01/15/experiments-in-gpu-based-occlusion-culling-part-2-multidrawindirect-and-mesh-lodding/
* Reference(s):
* - Experiments in GPU-based occlusion culling
* https://web.archive.org/web/20180920045301/https://interplayoflight.wordpress.com/2017/11/15/experiments-in-gpu-based-occlusion-culling/
* - Experiments in GPU-based occlusion culling part 2: MultiDrawIndirect and mesh lodding
* https://web.archive.org/web/20180920045332/https://interplayoflight.wordpress.com/2018/01/15/experiments-in-gpu-based-occlusion-culling-part-2-multidrawindirect-and-mesh-lodding/
*/
#include "common.h"

View File

@ -4,10 +4,9 @@
*/
/*
* References:
*
* Next Generation Post Processing in Call of Duty: Advanced Warfare
* https://web.archive.org/web/20180920045230/http://www.iryoku.com/next-generation-post-processing-in-call-of-duty-advanced-warfare
* Reference(s):
* - Next Generation Post Processing in Call of Duty: Advanced Warfare
* https://web.archive.org/web/20180920045230/http://www.iryoku.com/next-generation-post-processing-in-call-of-duty-advanced-warfare
*/
#include "common.h"

View File

@ -48,8 +48,9 @@ void toAabb(Aabb& _aabb, const Sphere& _sphere)
void toAabb(Aabb& _aabb, const Disk& _disk)
{
// Reference:
// https://web.archive.org/web/20181113055756/http://iquilezles.org/www/articles/diskbbox/diskbbox.htm
// Reference(s):
// - https://web.archive.org/web/20181113055756/http://iquilezles.org/www/articles/diskbbox/diskbbox.htm
//
const bx::Vec3 nsq = bx::mul(_disk.m_normal, _disk.m_normal);
const bx::Vec3 one = { 1.0f, 1.0f, 1.0f };
const bx::Vec3 tmp = bx::sub(one, nsq);
@ -68,8 +69,9 @@ void toAabb(Aabb& _aabb, const Disk& _disk)
void toAabb(Aabb& _aabb, const Cylinder& _cylinder)
{
// Reference:
// https://web.archive.org/web/20181113055756/http://iquilezles.org/www/articles/diskbbox/diskbbox.htm
// Reference(s):
// - https://web.archive.org/web/20181113055756/http://iquilezles.org/www/articles/diskbbox/diskbbox.htm
//
const bx::Vec3 axis = bx::sub(_cylinder.m_end, _cylinder.m_pos);
const bx::Vec3 asq = bx::mul(axis, axis);
const bx::Vec3 nsq = bx::mul(asq, 1.0f/bx::dot(axis, axis) );

View File

@ -4758,13 +4758,13 @@ extern "C"
// When laptop setup has integrated and discrete GPU, following driver workarounds will
// select discrete GPU:
// Reference:
// - https://web.archive.org/web/20180722051003/https://docs.nvidia.com/gameworks/content/technologies/desktop/optimus.htm
// Reference(s):
// - https://web.archive.org/web/20180722051003/https://docs.nvidia.com/gameworks/content/technologies/desktop/optimus.htm
//
__declspec(dllexport) uint32_t NvOptimusEnablement = UINT32_C(1);
// Reference:
// - https://web.archive.org/web/20180722051032/https://gpuopen.com/amdpowerxpressrequesthighperformance/
// Reference(s):
// - https://web.archive.org/web/20180722051032/https://gpuopen.com/amdpowerxpressrequesthighperformance/
//
__declspec(dllexport) uint32_t AmdPowerXpressRequestHighPerformance = UINT32_C(1);
}

View File

@ -11,9 +11,9 @@ namespace bgfx
/*
* NVAPI
*
* Reference:
* http://docs.nvidia.com/gameworks/content/gameworkslibrary/coresdk/nvapi/index.html
* https://github.com/jNizM/AHK_NVIDIA_NvAPI/blob/master/info/NvAPI_IDs.txt
* Reference(s):
* - https://web.archive.org/web/20181126035649/https://docs.nvidia.com/gameworks/content/gameworkslibrary/coresdk/nvapi/index.html
* - https://web.archive.org/web/20181126035710/https://github.com/jNizM/AHK_NVIDIA_NvAPI/blob/master/info/NvAPI_IDs.txt
*/
struct NvPhysicalGpuHandle;
@ -72,8 +72,8 @@ namespace bgfx
/*
* NVIDIA Aftermath
*
* Reference:
* https://developer.nvidia.com/nvidia-aftermath
* Reference(s):
* - https://web.archive.org/web/20181126035743/https://developer.nvidia.com/nvidia-aftermath
*/
typedef int32_t (*PFN_NVAFTERMATH_DX11_INITIALIZE)(int32_t _version, int32_t _flags, const ID3D11Device* _device);

View File

@ -560,8 +560,8 @@ namespace bgfx { namespace d3d11
/*
* AMD GPU Services (AGS) library
*
* Reference:
* https://github.com/GPUOpen-LibrariesAndSDKs/AGS_SDK
* Reference(s):
* - https://web.archive.org/web/20181126035805/https://github.com/GPUOpen-LibrariesAndSDKs/AGS_SDK
*/
enum AGS_RETURN_CODE
{

View File

@ -2089,10 +2089,11 @@ BX_TRACE("%d, %d, %d, %s", _array, _srgb, _mipAutogen, getName(_format) );
// EXT_texture_format_BGRA8888 wants both format and internal
// format to be BGRA.
//
// Reference:
// https://www.khronos.org/registry/gles/extensions/EXT/EXT_texture_format_BGRA8888.txt
// https://www.opengl.org/registry/specs/EXT/bgra.txt
// https://www.khronos.org/registry/gles/extensions/APPLE/APPLE_texture_format_BGRA8888.txt
// Reference(s):
// - https://web.archive.org/web/20181126035829/https://www.khronos.org/registry/OpenGL/extensions/EXT/EXT_texture_format_BGRA8888.txt
// - https://web.archive.org/web/20181126035841/https://www.khronos.org/registry/OpenGL/extensions/EXT/EXT_bgra.txt
// - https://web.archive.org/web/20181126035851/https://www.khronos.org/registry/OpenGL/extensions/APPLE/APPLE_texture_format_BGRA8888.txt
//
if (!s_extension[Extension::EXT_bgra ].m_supported
&& !s_extension[Extension::APPLE_texture_format_BGRA8888].m_supported)
{

View File

@ -15,8 +15,9 @@ BX_ERROR_RESULT(BGFX_SHADER_SPIRV_INVALID_INSTRUCTION, BX_MAKEFOURCC('S', 'H', 0
namespace bgfx
{
// Reference: https://www.khronos.org/registry/spir-v/specs/1.0/SPIRV.html
// Reference(s):
// - https://web.archive.org/web/20181126035927/https://www.khronos.org/registry/spir-v/specs/1.0/SPIRV.html
//
struct SpvOpcode
{
enum Enum