From 9597014bc294d7c894c368beb63da44d10b9ddbb Mon Sep 17 00:00:00 2001 From: AzaezelX Date: Thu, 11 Apr 2019 12:31:15 -0500 Subject: [PATCH] resource count and type sync with the computeForwardProbes call-insertion for shadergen. probly going to need to cook up a cubearray type --- .../source/shaderGen/HLSL/shaderFeatureHLSL.cpp | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/Engine/source/shaderGen/HLSL/shaderFeatureHLSL.cpp b/Engine/source/shaderGen/HLSL/shaderFeatureHLSL.cpp index 1eca130f2..650d36562 100644 --- a/Engine/source/shaderGen/HLSL/shaderFeatureHLSL.cpp +++ b/Engine/source/shaderGen/HLSL/shaderFeatureHLSL.cpp @@ -3167,11 +3167,8 @@ ShaderFeature::Resources ReflectionProbeFeatHLSL::getResources(const MaterialFea { Resources res; - //res.numTex = 4; - //res.numTexReg = 4; - - res.numTex = 4; - res.numTexReg = 4; + res.numTex = 5; + res.numTexReg = 5; return res; } @@ -3183,8 +3180,16 @@ void ReflectionProbeFeatHLSL::setTexData(Material::StageData &stageDat, { if (stageFeatures.features[MFT_ReflectionProbes]) { + passData.mSamplerNames[texIndex] = "BRDFTexture"; + passData.mTexType[texIndex++] = Material::Standard; // assuming here that it is a scenegraph cubemap - passData.mSamplerNames[texIndex] = "inProbeCubemap"; + passData.mSamplerNames[texIndex] = "specularCubemapAR"; + passData.mTexType[texIndex++] = Material::SGCube; + passData.mSamplerNames[texIndex] = "irradianceCubemapAR"; + passData.mTexType[texIndex++] = Material::SGCube; + passData.mSamplerNames[texIndex] = "skylightSpecularMap"; + passData.mTexType[texIndex++] = Material::SGCube; + passData.mSamplerNames[texIndex] = "skylightIrradMap"; passData.mTexType[texIndex++] = Material::SGCube; } }