|
|
|
|
|
|
|
|
|
|
#include "LightingUtils.hlsl" |
|
|
|
|
|
|
|
// these uniforms are only needed for when OPAQUES_ONLY is NOT defined |
|
|
|
// but there's a problem with our front-end compilation of compute shaders with multiple kernels causing it to error |
|
|
|
//#ifndef OPAQUES_ONLY |
|
|
|
uniform float g_fClustScale; |
|
|
|
uniform float g_fClustBase; |
|
|
|
uniform float g_fNearPlane; |
|
|
|
uniform float g_fFarPlane; |
|
|
|
uniform int g_iLog2NumClusters; // We need to always define these to keep constant buffer layouts compatible |
|
|
|
|
|
|
|
uniform uint g_isLogBaseBufferEnabled; |
|
|
|
uniform uint g_isOpaquesOnlyEnabled; |
|
|
|
//#endif |
|
|
|
|
|
|
|
|
|
|
|
StructuredBuffer<SFiniteLightData> g_vLightData; |
|
|
|
Buffer<uint> g_vLightListGlobal; |
|
|
|
|
|
|
|
|
|
|
#else |
|
|
|
|
|
|
|
uniform float g_fClustScale; |
|
|
|
uniform float g_fClustBase; |
|
|
|
uniform float g_fNearPlane; |
|
|
|
uniform float g_fFarPlane; |
|
|
|
uniform int g_iLog2NumClusters; // We need to always define these to keep constant buffer layouts compatible |
|
|
|
|
|
|
|
|
|
|
|
uniform uint g_isLogBaseBufferEnabled; |
|
|
|
uniform uint g_isOpaquesOnlyEnabled; |
|
|
|
|
|
|
|
|
|
|
|
void GetCountAndStart(out uint uStart, out uint uNrLights, uint2 tileIDX, int nrTilesX, int nrTilesY, float linDepth, uint model) |
|
|
|