diff --git a/Engine/source/T3D/lighting/reflectionProbe.cpp b/Engine/source/T3D/lighting/reflectionProbe.cpp index 671433878..8c6f11cfe 100644 --- a/Engine/source/T3D/lighting/reflectionProbe.cpp +++ b/Engine/source/T3D/lighting/reflectionProbe.cpp @@ -89,7 +89,11 @@ ImplementEnumType(ReflectionModeEnum, //----------------------------------------------------------------------------- // Object setup and teardown //----------------------------------------------------------------------------- -ReflectionProbe::ReflectionProbe() +ReflectionProbe::ReflectionProbe() : + cubeDescId(0), + reflectorDesc(nullptr), + mSphereVertCount(0), + mSpherePrimitiveCount(0) { // Flag this object so that it will always // be sent across the network to clients @@ -247,11 +251,11 @@ bool ReflectionProbe::_setReflectionMode(void *object, const char *index, const { ReflectionProbe* probe = reinterpret_cast(object); - if (data == "Static Cubemap") + if (!dStrcmp(data,"Static Cubemap")) { probe->mReflectionModeType = StaticCubemap; } - else if (data == "Baked Cubemap") + else if (!dStrcmp(data, "Baked Cubemap")) { //Clear our cubemap if we changed it to be baked, just for cleanliness probe->mReflectionModeType = BakedCubemap; @@ -589,6 +593,8 @@ void ReflectionProbe::processDynamicCubemap() else mProbeInfo->mIsEnabled = false; + mCubemapDirty = false; + //Update the probe manager with our new texture! //if (!mProbeInfo->mIsSkylight && mProbeInfo->mPrefilterCubemap->isInitialized() && mProbeInfo->mIrradianceCubemap->isInitialized()) // PROBEMGR->updateProbeTexture(mProbeInfo->mProbeIdx); @@ -637,8 +643,10 @@ void ReflectionProbe::processBakedCubemap() { mProbeInfo->mIsEnabled = true; + mCubemapDirty = false; + //Update the probe manager with our new texture! - PROBEMGR->updateProbeTexture(mProbeInfo->mProbeIdx); + PROBEMGR->updateProbeTexture(mProbeInfo); } } @@ -728,8 +736,10 @@ void ReflectionProbe::processStaticCubemap() { mProbeInfo->mIsEnabled = true; + mCubemapDirty = false; + //Update the probe manager with our new texture! - PROBEMGR->updateProbeTexture(mProbeInfo->mProbeIdx); + PROBEMGR->updateProbeTexture(mProbeInfo); } } diff --git a/Engine/source/T3D/lighting/reflectionProbe.h b/Engine/source/T3D/lighting/reflectionProbe.h index 61d0b58db..4c40f5e2b 100644 --- a/Engine/source/T3D/lighting/reflectionProbe.h +++ b/Engine/source/T3D/lighting/reflectionProbe.h @@ -151,9 +151,6 @@ protected: U32 mDynamicLastBakeMS; U32 mRefreshRateMS; - GBitmap* mCubeFaceBitmaps[6]; - U32 mCubemapResolution; - F32 mMaxDrawDistance; bool mResourcesCreated; diff --git a/Engine/source/gfx/D3D11/gfxD3D11Cubemap.cpp b/Engine/source/gfx/D3D11/gfxD3D11Cubemap.cpp index 1451df186..abf26218d 100644 --- a/Engine/source/gfx/D3D11/gfxD3D11Cubemap.cpp +++ b/Engine/source/gfx/D3D11/gfxD3D11Cubemap.cpp @@ -26,7 +26,7 @@ #include "gfx/D3D11/gfxD3D11EnumTranslate.h" #include "gfx/bitmap/imageUtils.h" -GFXD3D11Cubemap::GFXD3D11Cubemap() : mTexture(NULL), mSRView(NULL), mDSView(NULL) +GFXD3D11Cubemap::GFXD3D11Cubemap() : mTexture(NULL), mSRView(NULL), mDSView(NULL), mTexSize(0) { mDynamic = false; mAutoGenMips = false; @@ -568,4 +568,4 @@ void GFXD3D11CubemapArray::zombify() void GFXD3D11CubemapArray::resurrect() { // Static cubemaps are handled by D3D -} \ No newline at end of file +} diff --git a/Engine/source/materials/processedCustomMaterial.cpp b/Engine/source/materials/processedCustomMaterial.cpp index 7c3b04bd6..a6c03cfba 100644 --- a/Engine/source/materials/processedCustomMaterial.cpp +++ b/Engine/source/materials/processedCustomMaterial.cpp @@ -541,4 +541,4 @@ MaterialParameters* ProcessedCustomMaterial::allocMaterialParameters() } } return ret; -} \ No newline at end of file +} diff --git a/Engine/source/materials/processedShaderMaterial.cpp b/Engine/source/materials/processedShaderMaterial.cpp index 5c911be1e..6b2b0632a 100644 --- a/Engine/source/materials/processedShaderMaterial.cpp +++ b/Engine/source/materials/processedShaderMaterial.cpp @@ -1360,7 +1360,7 @@ void ProcessedShaderMaterial::setSceneInfo(SceneRenderState * state, const Scene LIGHTMGR->setLightInfo(this, mMaterial, sgData, state, pass, shaderConsts); - PROBEMGR->setProbeInfo(this, mMaterial, sgData, state, pass, shaderConsts); + //PROBEMGR->setProbeInfo(this, mMaterial, sgData, state, pass, shaderConsts); } void ProcessedShaderMaterial::setBuffers( GFXVertexBufferHandleBase *vertBuffer, GFXPrimitiveBufferHandle *primBuffer ) diff --git a/Engine/source/postFx/postEffect.cpp b/Engine/source/postFx/postEffect.cpp index d75d170a9..2d1285102 100644 --- a/Engine/source/postFx/postEffect.cpp +++ b/Engine/source/postFx/postEffect.cpp @@ -183,6 +183,16 @@ void PostEffect::EffectConst::set(const F32 &newVal) mValueType = FloatType; } +void PostEffect::EffectConst::set(const int& newVal) +{ + if (mIntVal == newVal) + return; + + mIntVal = newVal; + mDirty = true; + mValueType = IntType; +} + void PostEffect::EffectConst::set(const Point4F &newVal) { if (mPointVal == newVal) @@ -326,6 +336,21 @@ void PostEffect::EffectConst::setToBuffer( GFXShaderConstBufferRef buff ) const char* err = avar("PostEffect::EffectConst::setToBuffer $s type is not implemented", mName.c_str()); Con::errorf(err); GFXAssertFatal(0, err); +#endif + } + } + else if (mValueType == IntType) + { + if (type == GFXSCT_Int) + { + buff->set(mHandle, mIntVal); + } + else + { +#if TORQUE_DEBUG + const char* err = avar("PostEffect::EffectConst::setToBuffer $s type is not implemented", mName.c_str()); + Con::errorf(err); + GFXAssertFatal(0, err); #endif } } @@ -1676,6 +1701,20 @@ void PostEffect::setShaderConst(const String &name, const F32 &val) iter->value->set(val); } +void PostEffect::setShaderConst(const String& name, const int& val) +{ + PROFILE_SCOPE(PostEffect_SetShaderConst_Float); + + EffectConstTable::Iterator iter = mEffectConsts.find(name); + if (iter == mEffectConsts.end()) + { + EffectConst* newConst = new EffectConst(name, val); + iter = mEffectConsts.insertUnique(name, newConst); + } + + iter->value->set(val); +} + void PostEffect::setShaderConst(const String &name, const Point4F &val) { PROFILE_SCOPE(PostEffect_SetShaderConst_Point); diff --git a/Engine/source/postFx/postEffect.h b/Engine/source/postFx/postEffect.h index 84ea55c4f..e1ab050e7 100644 --- a/Engine/source/postFx/postEffect.h +++ b/Engine/source/postFx/postEffect.h @@ -230,6 +230,14 @@ protected: set(val); } + EffectConst(const String& name, const int& val) + : mName(name), + mHandle(NULL), + mDirty(true) + { + set(val); + } + EffectConst(const String &name, const Point4F &val) : mName(name), mHandle(NULL), @@ -264,6 +272,7 @@ protected: void set( const String &newVal ); void set(const F32 &newVal); + void set(const int& newVal); void set(const Point4F &newVal); void set(const MatrixF &newVal); void set(const Vector &newVal); @@ -277,6 +286,7 @@ protected: String mStringVal; + S32 mIntVal; F32 mFloatVal; Point4F mPointVal; MatrixF mMatrixVal; @@ -287,6 +297,7 @@ protected: enum { StringType, + IntType, FloatType, PointType, MatrixType, @@ -427,6 +438,7 @@ public: /// void setShaderConst( const String &name, const String &val ); void setShaderConst(const String &name, const F32 &val); + void setShaderConst(const String& name, const int& val); void setShaderConst(const String &name, const Point4F &val); void setShaderConst(const String &name, const MatrixF &val); void setShaderConst(const String &name, const Vector &val); diff --git a/Engine/source/renderInstance/renderProbeMgr.cpp b/Engine/source/renderInstance/renderProbeMgr.cpp index 74603dd81..0b7186f1b 100644 --- a/Engine/source/renderInstance/renderProbeMgr.cpp +++ b/Engine/source/renderInstance/renderProbeMgr.cpp @@ -87,7 +87,8 @@ ProbeRenderInst::ProbeRenderInst() : mAtten(0.0), mCubemapIndex(0), mIsSkylight(false), - mProbeIdx(0) + mProbeIdx(0), + mProbeShapeType(Box) { } @@ -132,7 +133,8 @@ ProbeShaderConstants::ProbeShaderConstants() mBRDFTextureMap(NULL), mSkylightSpecularMap(NULL), mSkylightIrradMap(NULL), - mHasSkylight(NULL) + mHasSkylight(NULL), + mWorldToObjArraySC(NULL) { } @@ -202,7 +204,10 @@ RenderProbeMgr::RenderProbeMgr() mLastShader(nullptr), mLastConstants(nullptr), mProbesDirty(false), - mHasSkylight(false) + mHasSkylight(false), + mSkylightCubemapIdx(-1), + mCubeMapCount(0), + mDefaultSkyLight(nullptr) { mEffectiveProbeCount = 0; mMipCount = 0; @@ -376,7 +381,7 @@ void RenderProbeMgr::unregisterProbe(U32 probeIdx) mRegisteredProbes.erase(probeIdx); //rebuild our probe data - _setupStaticParameters(); + mProbesDirty = true; } // @@ -409,7 +414,7 @@ void RenderProbeMgr::_setupStaticParameters() U32 probeCount = mRegisteredProbes.size(); mEffectiveProbeCount = 0; - mMipCount = 0; + mMipCount = 1; mHasSkylight = false; mSkylightCubemapIdx = -1; @@ -429,11 +434,7 @@ void RenderProbeMgr::_setupStaticParameters() probeWorldToObjData.fill(MatrixF::Identity); probeBBMinData.fill(Point4F::Zero); probeBBMaxData.fill(Point4F::Zero); - probeConfigData.fill(Point4F::Zero); - - Vector cubemapIdxes; - - mMipCount = 1; + probeConfigData.fill(Point4F(-1,0,0,0)); for (U32 i = 0; i < probeCount; i++) { @@ -444,13 +445,12 @@ void RenderProbeMgr::_setupStaticParameters() if (!curEntry.mIsEnabled) continue; - U32 mips = mRegisteredProbes[0].mPrefilterCubemap.getPointer()->getMipMapLevels(); - mMipCount = mips != 0 && mips > mMipCount ? mips : 0; + U32 mips = mRegisteredProbes[i].mPrefilterCubemap.getPointer()->getMipMapLevels(); + mMipCount = mips != 0 && mips >= mMipCount ? mips : 0; - if (curEntry.mProbeShapeType == ProbeRenderInst::ProbeShapeType::Skylight || curEntry.mIsSkylight) + if (curEntry.mIsSkylight) { mSkylightCubemapIdx = curEntry.mCubemapIndex; - mHasSkylight = true; continue; } @@ -471,25 +471,32 @@ void RenderProbeMgr::_setupStaticParameters() curEntry.mAtten, curEntry.mCubemapIndex); - cubemapIdxes.push_back(i); - mEffectiveProbeCount++; } mProbesDirty = false; } -void RenderProbeMgr::updateProbeTexture(U32 probeIdx) +void RenderProbeMgr::updateProbeTexture(ProbeRenderInst* probeInfo) { - if (probeIdx >= mRegisteredProbes.size()) + if (probeInfo->mIrradianceCubemap.isNull() || !probeInfo->mIrradianceCubemap->isInitialized()) + { + Con::errorf("RenderProbeMgr::updateProbeTexture() - tried to update a probe's texture with an invalid or uninitialized irradiance map!"); return; + } - const U32 cubeIndex = mRegisteredProbes[probeIdx].mCubemapIndex; - mIrradianceArray->updateTexture(mRegisteredProbes[probeIdx].mIrradianceCubemap, cubeIndex); - mPrefilterArray->updateTexture(mRegisteredProbes[probeIdx].mPrefilterCubemap, cubeIndex); + if (probeInfo->mPrefilterCubemap.isNull() || !probeInfo->mPrefilterCubemap->isInitialized()) + { + Con::errorf("RenderProbeMgr::updateProbeTexture() - tried to update a probe's texture with an invalid or uninitialized specular map!"); + return; + } - Con::warnf("UpdatedProbeTexture - probeIdx: %u on cubeIndex %u, Irrad validity: %d, Prefilter validity: %d", probeIdx, cubeIndex, - mRegisteredProbes[probeIdx].mIrradianceCubemap->isInitialized(), mRegisteredProbes[probeIdx].mPrefilterCubemap->isInitialized()); + const U32 cubeIndex = probeInfo->mCubemapIndex; + mIrradianceArray->updateTexture(probeInfo->mIrradianceCubemap, cubeIndex); + mPrefilterArray->updateTexture(probeInfo->mPrefilterCubemap, cubeIndex); + + Con::warnf("UpdatedProbeTexture - probeIdx: %u on cubeIndex %u, Irrad validity: %d, Prefilter validity: %d", probeInfo->mProbeIdx, cubeIndex, + probeInfo->mIrradianceCubemap->isInitialized(), probeInfo->mPrefilterCubemap->isInitialized()); } void RenderProbeMgr::_setupPerFrameParameters(const SceneRenderState *state) @@ -669,7 +676,7 @@ void RenderProbeMgr::_update4ProbeConsts(const SceneData &sgData, if (curEntry.mIsSkylight) { - if (curEntry.mPrefilterCubemap.isValid() && curEntry.mPrefilterCubemap.isValid()) + if (curEntry.mPrefilterCubemap->isInitialized() && curEntry.mIrradianceCubemap->isInitialized()) { GFX->setCubeTexture(probeShaderConsts->mSkylightSpecularMap->getSamplerRegister(), curEntry.mPrefilterCubemap); GFX->setCubeTexture(probeShaderConsts->mSkylightIrradMap->getSamplerRegister(), curEntry.mIrradianceCubemap); @@ -739,7 +746,7 @@ void RenderProbeMgr::render( SceneRenderState *state ) _setupStaticParameters(); // Early out if nothing to draw. - if (!RenderProbeMgr::smRenderReflectionProbes || !state->isDiffusePass() || (mRegisteredProbes.size() == 0 || (mEffectiveProbeCount == 0 && !mHasSkylight))) + if (!RenderProbeMgr::smRenderReflectionProbes || !state->isDiffusePass() || (mEffectiveProbeCount == 0 && mSkylightCubemapIdx == -1)) { getProbeArrayEffect()->setSkip(true); return; @@ -765,23 +772,24 @@ void RenderProbeMgr::render( SceneRenderState *state ) String useDebugContrib = Con::getVariable("$Probes::showProbeContrib", "0"); mProbeArrayEffect->setShaderMacro("DEBUGVIZ_CONTRIB", useDebugContrib); + + if(mHasSkylight && mEffectiveProbeCount == 0) + mProbeArrayEffect->setShaderMacro("SKYLIGHT_ONLY", "1"); - if (mHasSkylight || mEffectiveProbeCount != 0) - { - mProbeArrayEffect->setTexture(3, mBRDFTexture); - mProbeArrayEffect->setCubemapArrayTexture(4, mPrefilterArray); - mProbeArrayEffect->setCubemapArrayTexture(5, mIrradianceArray); - } + mProbeArrayEffect->setTexture(3, mBRDFTexture); + mProbeArrayEffect->setCubemapArrayTexture(4, mPrefilterArray); + mProbeArrayEffect->setCubemapArrayTexture(5, mIrradianceArray); - mProbeArrayEffect->setShaderConst("$hasSkylight", (float)mHasSkylight); - if (mHasSkylight) - { - mProbeArrayEffect->setShaderConst("$skylightCubemapIdx", mSkylightCubemapIdx); - } - - mProbeArrayEffect->setShaderConst("$numProbes", (float)mEffectiveProbeCount); + mProbeArrayEffect->setShaderConst("$numProbes", (S32)mEffectiveProbeCount); + mProbeArrayEffect->setShaderConst("$skylightCubemapIdx", mSkylightCubemapIdx); mProbeArrayEffect->setShaderConst("$cubeMips", (float)mMipCount); + + //also set up some colors + Vector contribColors; + + contribColors.setSize(MAXPROBECOUNT); + if (mEffectiveProbeCount != 0) { if (useDebugContrib == String("1")) @@ -789,11 +797,6 @@ void RenderProbeMgr::render( SceneRenderState *state ) MRandomLCG RandomGen; RandomGen.setSeed(mEffectiveProbeCount); - //also set up some colors - Vector contribColors; - - contribColors.setSize(MAXPROBECOUNT); - for (U32 i = 0; i < mEffectiveProbeCount; i++) { //we're going to cheat here a little for consistent debugging behavior. The first 3 probes will always have R G and then B for their colors, every other will be random @@ -806,18 +809,18 @@ void RenderProbeMgr::render( SceneRenderState *state ) else contribColors[i] = Point4F(RandomGen.randF(0, 1), RandomGen.randF(0, 1), RandomGen.randF(0, 1), 1); } - - mProbeArrayEffect->setShaderConst("$probeContribColors", contribColors); } - - mProbeArrayEffect->setShaderConst("$inProbePosArray", probePositionsData); - mProbeArrayEffect->setShaderConst("$inRefPosArray", probeRefPositionsData); - mProbeArrayEffect->setShaderConst("$worldToObjArray", probeWorldToObjData); - mProbeArrayEffect->setShaderConst("$bbMinArray", probeBBMinData); - mProbeArrayEffect->setShaderConst("$bbMaxArray", probeBBMaxData); - mProbeArrayEffect->setShaderConst("$probeConfigData", probeConfigData); } + mProbeArrayEffect->setShaderConst("$probeContribColors", contribColors); + + mProbeArrayEffect->setShaderConst("$inProbePosArray", probePositionsData); + mProbeArrayEffect->setShaderConst("$inRefPosArray", probeRefPositionsData); + mProbeArrayEffect->setShaderConst("$worldToObjArray", probeWorldToObjData); + mProbeArrayEffect->setShaderConst("$bbMinArray", probeBBMinData); + mProbeArrayEffect->setShaderConst("$bbMaxArray", probeBBMaxData); + mProbeArrayEffect->setShaderConst("$probeConfigData", probeConfigData); + // Make sure the effect is gonna render. getProbeArrayEffect()->setSkip(false); diff --git a/Engine/source/renderInstance/renderProbeMgr.h b/Engine/source/renderInstance/renderProbeMgr.h index 8eba74431..911e05a21 100644 --- a/Engine/source/renderInstance/renderProbeMgr.h +++ b/Engine/source/renderInstance/renderProbeMgr.h @@ -292,7 +292,7 @@ public: U32 pass, GFXShaderConstBuffer *shaderConsts); - void updateProbeTexture(U32 probeIdx); + void updateProbeTexture(ProbeRenderInst* probeInfo); /// Debug rendering static bool smRenderReflectionProbes; diff --git a/Engine/source/util/settings.cpp b/Engine/source/util/settings.cpp index 96fd2d5c8..299898e8d 100644 --- a/Engine/source/util/settings.cpp +++ b/Engine/source/util/settings.cpp @@ -709,4 +709,4 @@ DefineEngineMethod(Settings, clearGroups, void, (), , "settingObj.clearGroups(); DefineEngineMethod(Settings, getCurrentGroups, const char*, (), , "settingObj.getCurrentGroups();") { return object->getCurrentGroups(); -} \ No newline at end of file +} diff --git a/Templates/BaseGame/game/core/lighting/scripts/advancedLighting_Shaders.cs b/Templates/BaseGame/game/core/lighting/scripts/advancedLighting_Shaders.cs index 3a52199b4..bc70856ad 100644 --- a/Templates/BaseGame/game/core/lighting/scripts/advancedLighting_Shaders.cs +++ b/Templates/BaseGame/game/core/lighting/scripts/advancedLighting_Shaders.cs @@ -322,8 +322,6 @@ singleton ShaderData( PFX_ReflectionProbeArray ) samplerNames[3] = "$BRDFTexture"; samplerNames[4] = "$specularCubemapAR"; samplerNames[5] = "$irradianceCubemapAR"; - samplerNames[6] = "$skylightSpecularMap"; - samplerNames[7] = "$skylightIrradMap"; pixVersion = 2.0; }; @@ -345,7 +343,6 @@ singleton GFXStateBlockData( PFX_ReflectionProbeArrayStateBlock ) zEnable = false; zWriteEnable = false; - samplersDefined = true; samplerStates[0] = SamplerClampPoint; samplerStates[1] = SamplerClampPoint; @@ -353,6 +350,4 @@ singleton GFXStateBlockData( PFX_ReflectionProbeArrayStateBlock ) samplerStates[3] = SamplerClampPoint; samplerStates[4] = SamplerClampLinear; samplerStates[5] = SamplerClampLinear; - samplerStates[6] = SamplerClampLinear; - samplerStates[7] = SamplerClampLinear; }; \ No newline at end of file diff --git a/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeArrayP.glsl b/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeArrayP.glsl index 2298c958c..12d8b3c36 100644 --- a/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeArrayP.glsl +++ b/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeArrayP.glsl @@ -19,7 +19,8 @@ uniform vec3 eyePosWorld; //cubemap arrays require all the same size. so shared mips# value uniform float cubeMips; -uniform float numProbes; +uniform int numProbes; + uniform samplerCubeArray specularCubemapAR; uniform samplerCubeArray irradianceCubemapAR; @@ -34,9 +35,7 @@ uniform vec4 probeConfigData[MAX_PROBES]; //r,g,b/mode,radius,atten uniform vec4 probeContribColors[MAX_PROBES]; #endif -uniform samplerCube skylightSpecularMap; -uniform samplerCube skylightIrradMap; -uniform float hasSkylight; +uniform float skylightCubemapIdx; out vec4 OUT_col; @@ -56,6 +55,7 @@ void main() float alpha = 1; +#if SKYLIGHT_ONLY == 0 int i = 0; float blendFactor[MAX_PROBES]; float blendSum = 0; @@ -64,8 +64,9 @@ void main() float probehits = 0; //Set up our struct data float contribution[MAX_PROBES]; - if (alpha > 0) - { + + //if (alpha > 0) + //{ //Process prooooobes for (i = 0; i < numProbes; ++i) { @@ -83,6 +84,8 @@ void main() if (contribution[i]>0.0) probehits++; } + else + continue; contribution[i] = max(contribution[i],0); @@ -106,20 +109,21 @@ void main() } // Normalize blendVal -#if DEBUGVIZ_ATTENUATION == 0 //this can likely be removed when we fix the above normalization behavior - if (blendFacSum == 0.0f) // Possible with custom weight - { - blendFacSum = 1.0f; - } -#endif + if (blendFacSum == 0.0f) // Possible with custom weight + { + blendFacSum = 1.0f; + } float invBlendSumWeighted = 1.0f / blendFacSum; for (i = 0; i < numProbes; ++i) { blendFactor[i] *= invBlendSumWeighted; contribution[i] *= blendFactor[i]; + alpha -= contribution[i]; } } + else + alpha -= blendSum; #if DEBUGVIZ_ATTENUATION == 1 float contribAlpha = 1; @@ -142,12 +146,14 @@ void main() } //Skylight coloration for anything not covered by probes above - finalContribColor += vec3(0.3, 0.3, 0.3) * contribAlpha; + if(skylightCubemapIdx != -1) + finalContribColor += vec3(0.3, 0.3, 0.3) * contribAlpha; OUT_col = vec4(finalContribColor, 1); return; #endif - } + //} +#endif vec3 irradiance = vec3(0, 0, 0); vec3 specular = vec3(0, 0, 0); @@ -159,27 +165,27 @@ void main() float lod = 0; #endif +#if SKYLIGHT_ONLY == 0 alpha = 1; for (i = 0; i < numProbes; ++i) { float contrib = contribution[i]; if (contrib != 0) { - float cubemapIdx = probeConfigData[i].a; + int cubemapIdx = probeConfigData[i].a; vec3 dir = boxProject(surface.P, surface.R, worldToObjArray[i], bbMinArray[i].xyz, bbMaxArray[i].xyz, inRefPosArray[i].xyz); irradiance += textureLod(irradianceCubemapAR, vec4(dir, cubemapIdx), 0).xyz * contrib; specular += textureLod(specularCubemapAR, vec4(dir, cubemapIdx), lod).xyz * contrib; - //irradiance += vec3(1,1,1) * contrib; - //specular += vec3(1,1,1) * contrib; alpha -= contrib; } } +#endif - if (hasSkylight == 1 && alpha > 0.001) + if (skylightCubemapIdx != -1 && alpha > 0.001) { - irradiance += textureLod(skylightIrradMap, surface.R, 0).xyz * alpha; - specular += textureLod(skylightSpecularMap, surface.R, lod).xyz * alpha; + irradiance += textureLod(irradianceCubemapAR, vec4(surface.R, skylightCubemapIdx), 0).xyz * alpha; + specular += textureLod(specularCubemapAR, vec4(surface.R, skylightCubemapIdx), lod).xyz * alpha; } #if DEBUGVIZ_SPECCUBEMAP == 1 && DEBUGVIZ_DIFFCUBEMAP == 0 diff --git a/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeP.glsl b/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeP.glsl deleted file mode 100644 index fee0b8783..000000000 --- a/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeP.glsl +++ /dev/null @@ -1,162 +0,0 @@ -//----------------------------------------------------------------------------- -// Copyright (c) 2012 GarageGames, LLC -// -// Permission is hereby granted, free of charge, to any person obtaining a copy -// of this software and associated documentation files (the "Software"), to -// deal in the Software without restriction, including without limitation the -// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or -// sell copies of the Software, and to permit persons to whom the Software is -// furnished to do so, subject to the following conditions: -// -// The above copyright notice and this permission notice shall be included in -// all copies or substantial portions of the Software. -// -// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING -// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS -// IN THE SOFTWARE. -//----------------------------------------------------------------------------- -#include "../../../gl/hlslCompat.glsl" -#include "shadergen:/autogenConditioners.h" -#include "farFrustumQuad.glsl" -#include "../../../gl/torque.glsl" -#include "../../../gl/lighting.glsl" -#line 27 - -in vec4 pos; -in vec4 wsEyeDir; -in vec4 ssPos; -in vec4 vsEyeDir; - -uniform sampler2D deferredBuffer; -uniform sampler2D colorBuffer; -uniform sampler2D matInfoBuffer; -uniform samplerCube cubeMap; -uniform samplerCube irradianceCubemap; -uniform sampler2D BRDFTexture; -uniform float cubeMips; - -uniform vec4 rtParams0; - -uniform vec3 probeWSPos; -uniform vec3 probeLSPos; -uniform vec4 vsFarPlane; - -uniform float radius; -uniform vec2 attenuation; - -uniform mat4 worldToObj; -uniform mat4 cameraToWorld; - -uniform vec3 eyePosWorld; -uniform vec3 bbMin; -uniform vec3 bbMax; - -uniform float useSphereMode; - -// Box Projected IBL Lighting -// Based on: http://www.gamedev.net/topic/568829-box-projected-cubemap-environment-mapping/ -// and https://seblagarde.wordpress.com/2012/09/29/image-based-lighting-approaches-and-parallax-corrected-cubemap/ -vec3 boxProject(vec3 wsPosition, vec3 reflectDir, vec3 boxWSPos, vec3 boxMin, vec3 boxMax) -{ - vec3 nrdir = reflectDir; - vec3 offset = wsPosition; - vec3 plane1vec = (boxMax - offset) / nrdir; - vec3 plane2vec = (boxMin - offset) / nrdir; - - vec3 furthestPlane = max(plane1vec, plane2vec); - float dist = min(min(furthestPlane.x, furthestPlane.y), furthestPlane.z); - vec3 posonbox = offset + nrdir * dist; - - return posonbox - boxWSPos; -} - -vec3 iblBoxSpecular(vec3 normal, vec3 wsPos, float roughness, vec3 surfToEye, - sampler2D brdfTexture, - samplerCube radianceCube, - vec3 boxPos, - vec3 boxMin, - vec3 boxMax) -{ - float ndotv = clamp(dot(normal, surfToEye), 0.0, 1.0); - - // BRDF - vec2 brdf = textureLod(brdfTexture, vec2(roughness, ndotv),0).xy; - - // Radiance (Specular) - float maxmip = pow(cubeMips+1,2); - float lod = roughness*maxmip; - vec3 r = reflect(surfToEye, normal); - vec3 cubeR = normalize(r); - cubeR = boxProject(wsPos, cubeR, boxPos, boxMin, boxMax); - - vec3 radiance = textureLod(radianceCube, cubeR, lod).xyz * (brdf.x + brdf.y); - - return radiance; -} - -float defineBoxSpaceInfluence(vec3 surfPosWS, vec3 probePos, float radius, float atten) -{ - vec3 surfPosLS = tMul( worldToObj, vec4(surfPosWS,1.0)).xyz; - - vec3 boxMinLS = probePos-(vec3(1,1,1)*radius); - vec3 boxMaxLS = probePos+(vec3(1,1,1)*radius); - - float boxOuterRange = length(boxMaxLS - boxMinLS); - float boxInnerRange = boxOuterRange / atten; - - vec3 localDir = vec3(abs(surfPosLS.x), abs(surfPosLS.y), abs(surfPosLS.z)); - localDir = (localDir - boxInnerRange) / (boxOuterRange - boxInnerRange); - - return max(localDir.x, max(localDir.y, localDir.z)) * -1; -} -out vec4 OUT_col; - -void main() -{ - - // Compute scene UV - vec2 uvScene = getUVFromSSPos( ssPos.xyz/ssPos.w, rtParams0 ); - - //eye ray WS/LS - vec3 vsEyeRay = getDistanceVectorToPlane( -vsFarPlane.w, vsEyeDir.xyz, vsFarPlane ); - vec3 wsEyeRay = tMul(cameraToWorld, vec4(vsEyeRay, 0)).xyz; - - //unpack normal and linear depth - vec4 normDepth = deferredUncondition(deferredBuffer, uvScene); - - //create surface - Surface surface = createSurface( normDepth, colorBuffer, matInfoBuffer, - uvScene, eyePosWorld, wsEyeRay, cameraToWorld); - float blendVal = 1.0; - if(useSphereMode>0) - { - vec3 L = probeWSPos - surface.P; - blendVal = 1.0-length(L)/radius; - clip(blendVal); - } - else - { - float tempAttenVal = 3.5; - blendVal = defineBoxSpaceInfluence(surface.P, probeWSPos, radius, tempAttenVal); - clip(blendVal); - float compression = 0.05; - blendVal=(1.0-compression)+blendVal*compression; - } - //render into the bound space defined above - vec3 surfToEye = normalize(surface.P - eyePosWorld); - vec3 irradiance = textureLod(irradianceCubemap, surface.N,0).xyz; - vec3 specular = iblBoxSpecular(surface.N, surface.P, surface.roughness, surfToEye, BRDFTexture, cubeMap, probeWSPos, bbMin, bbMax); - vec3 F = FresnelSchlickRoughness(surface.NdotV, surface.f0, surface.roughness); - specular *= F; - //energy conservation - vec3 kD = vec3(1.0) - F; - kD *= 1.0 - surface.metalness; - //final diffuse color - vec3 diffuse = kD * irradiance * surface.baseColor.rgb; - - OUT_col = vec4(diffuse + specular * surface.ao, blendVal); -} diff --git a/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeV.glsl b/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeV.glsl deleted file mode 100644 index 5d48e6613..000000000 --- a/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/gl/reflectionProbeV.glsl +++ /dev/null @@ -1,32 +0,0 @@ -#include "shadergen:/autogenConditioners.h" -#include "../../torque.hlsl" - -// This is the shader input -struct Vert -{ - float4 position : POSITION; - float2 uv0 : TEXCOORD0; - float3 wsEyeRay : TEXCOORD1; -}; - -// This is the shader output data. -struct Conn -{ - float4 position : POSITION; - float2 uv0 : TEXCOORD0; - float3 wsEyeRay : TEXCOORD1; -}; - -// Render Target Paramaters -float4 rtParams0; - -Conn main(Vert IN, - uniform float4x4 modelView : register(C0)) -{ - Conn OUT; - OUT.position = IN.position; - OUT.uv0 = viewportCoordToRenderTarget( IN.uv0, rtParams0 ); - OUT.wsEyeRay = IN.wsEyeRay; - return OUT; -} - diff --git a/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/reflectionProbeArrayP.hlsl b/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/reflectionProbeArrayP.hlsl index 9ded5bd1b..df53fa3c9 100644 --- a/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/reflectionProbeArrayP.hlsl +++ b/Templates/BaseGame/game/core/rendering/shaders/lighting/advanced/reflectionProbeArrayP.hlsl @@ -16,7 +16,8 @@ uniform float3 eyePosWorld; //cubemap arrays require all the same size. so shared mips# value uniform float cubeMips; -uniform float numProbes; +uniform int numProbes; + TORQUE_UNIFORM_SAMPLERCUBEARRAY(specularCubemapAR, 4); TORQUE_UNIFORM_SAMPLERCUBEARRAY(irradianceCubemapAR, 5); @@ -31,7 +32,6 @@ uniform float4 probeConfigData[MAX_PROBES]; //r,g,b/mode,radius,atten uniform float4 probeContribColors[MAX_PROBES]; #endif -uniform float hasSkylight; uniform float skylightCubemapIdx; float4 main(PFXVertToPix IN) : SV_TARGET @@ -46,11 +46,12 @@ float4 main(PFXVertToPix IN) : SV_TARGET //early out if emissive if (getFlag(surface.matFlag, 0)) { - discard; + return TORQUE_TEX2D(colorBuffer, IN.uv0.xy); } float alpha = 1; +#if SKYLIGHT_ONLY == 0 int i = 0; float blendFactor[MAX_PROBES]; float blendSum = 0; @@ -59,8 +60,9 @@ float4 main(PFXVertToPix IN) : SV_TARGET float probehits = 0; //Set up our struct data float contribution[MAX_PROBES]; - if (alpha > 0) - { + + //if (alpha > 0) + //{ //Process prooooobes for (i = 0; i < numProbes; ++i) { @@ -78,6 +80,8 @@ float4 main(PFXVertToPix IN) : SV_TARGET if (contribution[i]>0.0) probehits++; } + else + continue; contribution[i] = max(contribution[i],0); @@ -90,34 +94,32 @@ float4 main(PFXVertToPix IN) : SV_TARGET // Weight1 = normalized inverted NDF, so we have 1 at center, 0 at boundary // and respect constraint A. - if (probehits>1.0) - { - for (i = 0; i < numProbes; i++) - { - blendFactor[i] = ((contribution[i] / blendSum)) / probehits; - blendFactor[i] *= ((contribution[i]) / invBlendSum); - blendFactor[i] = saturate(blendFactor[i]); - blendFacSum += blendFactor[i]; - } + if (probehits > 1.0) + { + for (i = 0; i < numProbes; i++) + { + blendFactor[i] = ((contribution[i] / blendSum)) / probehits; + blendFactor[i] *= ((contribution[i]) / invBlendSum); + blendFactor[i] = saturate(blendFactor[i]); + blendFacSum += blendFactor[i]; + } - // Normalize blendVal -#if DEBUGVIZ_ATTENUATION == 0 //this can likely be removed when we fix the above normalization behavior - if (blendFacSum == 0.0f) // Possible with custom weight - { - blendFacSum = 1.0f; - } -#endif + // Normalize blendVal + if (blendFacSum == 0.0f) // Possible with custom weight + { + blendFacSum = 1.0f; + } - float invBlendSumWeighted = 1.0f / blendFacSum; - for (i = 0; i < numProbes; ++i) - { - blendFactor[i] *= invBlendSumWeighted; - contribution[i] *= blendFactor[i]; - alpha -= contribution[i]; - } + float invBlendSumWeighted = 1.0f / blendFacSum; + for (i = 0; i < numProbes; ++i) + { + blendFactor[i] *= invBlendSumWeighted; + contribution[i] *= blendFactor[i]; + alpha -= contribution[i]; + } } else - alpha -= blendSum; + alpha -= blendSum; #if DEBUGVIZ_ATTENUATION == 1 float contribAlpha = 1; @@ -139,11 +141,13 @@ float4 main(PFXVertToPix IN) : SV_TARGET } //Skylight coloration for anything not covered by probes above - finalContribColor += float3(0.3, 0.3, 0.3) * contribAlpha; + if(skylightCubemapIdx != -1) + finalContribColor += float3(0.3, 0.3, 0.3) * contribAlpha; return float4(finalContribColor, 1); #endif - } + //} +#endif float3 irradiance = float3(0, 0, 0); float3 specular = float3(0, 0, 0); @@ -155,6 +159,7 @@ float4 main(PFXVertToPix IN) : SV_TARGET float lod = 0; #endif +#if SKYLIGHT_ONLY == 0 alpha = 1; for (i = 0; i < numProbes; ++i) { @@ -169,8 +174,9 @@ float4 main(PFXVertToPix IN) : SV_TARGET alpha -= contrib; } } +#endif - if (hasSkylight && alpha > 0.001) + if(skylightCubemapIdx != -1 && alpha >= 0.001) { irradiance += TORQUE_TEXCUBEARRAYLOD(irradianceCubemapAR, surface.R, skylightCubemapIdx, 0).xyz * alpha; specular += TORQUE_TEXCUBEARRAYLOD(specularCubemapAR, surface.R, skylightCubemapIdx, lod).xyz * alpha; @@ -197,6 +203,5 @@ float4 main(PFXVertToPix IN) : SV_TARGET float3 diffuse = kD * irradiance * surface.baseColor.rgb; float4 finalColor = float4(diffuse + specular * surface.ao, 1.0); -//finalColor.rgb += abs(surface.N); return finalColor; } diff --git a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetBrowser.cs b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetBrowser.cs index fd6f85278..49c1941c3 100644 --- a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetBrowser.cs +++ b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetBrowser.cs @@ -150,7 +150,7 @@ function AssetBrowser::showDialog( %this, %AssetTypeFilter, %selectCallback, %ta AssetBrowser.fieldTargetObject = %targetObj; AssetBrowser.fieldTargetName = %fieldName; - Canvas.add(AssetBrowser); + Canvas.pushDialog(AssetBrowser); AssetBrowser.setVisible(1); AssetBrowserWindow.setVisible(1); AssetBrowserWindow.selectWindow(); diff --git a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImport.cs b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImport.cs index b63f5dd22..299ecd030 100644 --- a/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImport.cs +++ b/Templates/BaseGame/game/tools/assetBrowser/scripts/assetImport.cs @@ -497,6 +497,9 @@ function ImportAssetWindow::onWake(%this) return; $AssetBrowser::importConfigsFile = "tools/assetBrowser/assetImportConfigs.xml"; + $AssetBrowser::currentImportConfig = ""; + new Settings(AssetImportSettings) { file = $AssetBrowser::importConfigsFile; }; + AssetImportSettings.read(); %this.reloadImportOptionConfigs(); } @@ -510,17 +513,15 @@ function ImportAssetWindow::reloadImportOptionConfigs(%this) if(%xmlDoc.loadFile($AssetBrowser::importConfigsFile)) { //StateMachine element - %xmlDoc.pushFirstChildElement("AssetImportConfigs"); + %xmlDoc.pushFirstChildElement("AssetImportSettings"); - //Configs + //Config Groups %configCount = 0; while(%xmlDoc.pushChildElement(%configCount)) { - %configObj = new ScriptObject(){}; - - %configObj.Name = %xmlDoc.attribute("Name"); + %configName = %xmlDoc.attribute("name"); - %xmlDoc.pushFirstChildElement("Mesh"); + /*%xmlDoc.pushFirstChildElement("Mesh"); %configObj.ImportMesh = %xmlDoc.attribute("ImportMesh"); %configObj.DoUpAxisOverride = %xmlDoc.attribute("DoUpAxisOverride"); %configObj.UpAxisOverride = %xmlDoc.attribute("UpAxisOverride"); @@ -583,12 +584,12 @@ function ImportAssetWindow::reloadImportOptionConfigs(%this) %configObj.VolumeAdjust = %xmlDoc.attribute("VolumeAdjust"); %configObj.PitchAdjust = %xmlDoc.attribute("PitchAdjust"); %configObj.Compressed = %xmlDoc.attribute("Compressed"); - %xmlDoc.popElement(); + %xmlDoc.popElement();*/ %xmlDoc.popElement(); %configCount++; - ImportAssetWindow.importConfigsList.add(%configObj); + ImportAssetWindow.importConfigsList.add(%configName); } %xmlDoc.popElement(); @@ -596,8 +597,8 @@ function ImportAssetWindow::reloadImportOptionConfigs(%this) for(%i = 0; %i < ImportAssetWindow.importConfigsList.count(); %i++) { - %configObj = ImportAssetWindow.importConfigsList.getKey(%i); - ImportAssetConfigList.add(%configObj.Name); + %configName = ImportAssetWindow.importConfigsList.getKey(%i); + ImportAssetConfigList.add(%configName); } %importConfigIdx = ImportAssetWindow.activeImportConfigIndex; @@ -607,7 +608,7 @@ function ImportAssetWindow::reloadImportOptionConfigs(%this) ImportAssetConfigList.setSelected(%importConfigIdx); } -function ImportAssetWindow::setImportOptions(%this, %optionsObj) +function ImportAssetWindow::setImportOptions(%this, %configName) { //Todo, editor + load from files for preconfigs diff --git a/Templates/BaseGame/game/tools/gui/profiles.ed.cs b/Templates/BaseGame/game/tools/gui/profiles.ed.cs index bb750611c..16e5f4194 100644 --- a/Templates/BaseGame/game/tools/gui/profiles.ed.cs +++ b/Templates/BaseGame/game/tools/gui/profiles.ed.cs @@ -37,7 +37,7 @@ new GuiControlProfile (ToolsGuiDefaultProfile) mouseOverSelected = false; // fill color - opaque = true; + opaque = false; fillColor = "50 50 50"; fillColorHL = "91 101 116"; fillColorSEL = "91 101 116"; diff --git a/Templates/BaseGame/game/tools/settings.xml b/Templates/BaseGame/game/tools/settings.xml index 050bbb71f..be6fd5412 100644 --- a/Templates/BaseGame/game/tools/settings.xml +++ b/Templates/BaseGame/game/tools/settings.xml @@ -1,94 +1,128 @@ + + Grid_512_Orange + + + data/FPSGameplay/levels + + + 5 + + + 25 + + + - 0 - 1 screenCenter - 6 + 0 WorldEditorInspectorPlugin + 1 40 - 50 AssetWork_Debug.exe + 6 + 50 + + 255 255 255 255 + 100 100 100 255 + 255 255 0 255 + 255 255 0 255 + 0 0 255 255 + 255 0 0 255 + 0 255 0 255 + + + 48 48 48 255 + 255 255 255 255 + 215 215 215 255 + 180 180 180 255 + 50 50 50 255 + + + 100 + 0 + 0 + 0 + 1 + 2 + 1 + + + 51 51 51 100 + 102 102 102 100 + 1 + 255 255 255 100 + 0 + + + tools/worldEditor/images/DefaultHandle + tools/worldEditor/images/SelectHandle + tools/worldEditor/images/LockedHandle + + + http://www.garagegames.com/products/torque-3d/forums + ../../../Documentation/Official Documentation.html + ../../../Documentation/Torque 3D - Script Manual.chm + http://www.garagegames.com/products/torque-3d/documentation/user + - 8 1 0 255 20 - - - ../../../Documentation/Torque 3D - Script Manual.chm - http://www.garagegames.com/products/torque-3d/documentation/user - ../../../Documentation/Official Documentation.html - http://www.garagegames.com/products/torque-3d/forums + 8 - 1 1 1 + 1 1 1 + + + 0.8 + 100 + 0.8 + 15 + 0 + 0 + 1 - 255 255 255 100 - 0 - 51 51 51 100 - 102 102 102 100 - 1 - - - 2 - 0 - 0 - 1 - 1 - 0 - 100 - - - 48 48 48 255 - 215 215 215 255 - 180 180 180 255 - 255 255 255 255 - 50 50 50 255 - - - 0 0 255 255 - 0 255 0 255 - 255 0 0 255 - 255 255 0 255 - 100 100 100 255 - 255 255 255 255 - 255 255 0 255 - - - tools/worldEditor/images/SelectHandle - tools/worldEditor/images/LockedHandle - tools/worldEditor/images/DefaultHandle + 0 + 255 255 255 20 + 0 + 10 10 10 + 0 + 500 - 1024 768 tools/gui + 1024 768 0 0 0 + + http://www.garagegames.com/products/torque-3d/documentation/user + ../../../Documentation/Torque 3D - Script Manual.chm + ../../../Documentation/Official Documentation.html + 1 - 1 - 1 1 8 + 1 + 1 2 1 0 - - ../../../Documentation/Torque 3D - Script Manual.chm - ../../../Documentation/Official Documentation.html - http://www.garagegames.com/products/torque-3d/documentation/user + + 0 1 @@ -97,37 +131,6 @@ Categorized - - 0 - - - - 0 - 1 - 100 - 15 - 0 - 0.8 - 0.8 - - 0 - 500 - 0 - 255 255 255 20 - 10 10 10 - 0 - - - - data/FPSGameplay/levels - - - 25 - - - - - Grid_512_Orange AIPlayer diff --git a/Templates/BaseGame/game/tools/worldEditor/main.cs b/Templates/BaseGame/game/tools/worldEditor/main.cs index fb985b66b..b524f00ae 100644 --- a/Templates/BaseGame/game/tools/worldEditor/main.cs +++ b/Templates/BaseGame/game/tools/worldEditor/main.cs @@ -135,7 +135,12 @@ function initializeWorldEditor() EVisibility.addOption( "Frustum Lock", "$Scene::lockCull", "" ); EVisibility.addOption( "Disable Zone Culling", "$Scene::disableZoneCulling", "" ); EVisibility.addOption( "Disable Terrain Occlusion", "$Scene::disableTerrainOcclusion", "" ); - + + EVisibility.addOption( "Probes: Attenuation", "$Probes::showAttenuation", "" ); + EVisibility.addOption( "Probes: Specular Cubemaps", "$Probes::showSpecularCubemaps", "" ); + EVisibility.addOption( "Probes: Diffuse Cubemaps", "$Probes::showDiffuseCubemaps", "" ); + EVisibility.addOption( "Probes: Contribution", "$Probes::showProbeContrib", "" ); + EVisibility.addOption( "Colorblindness: Protanopia", "$CBV_Protanopia", "toggleColorBlindnessViz" ); EVisibility.addOption( "Colorblindness: Protanomaly", "$CBV_Protanomaly", "toggleColorBlindnessViz" ); EVisibility.addOption( "Colorblindness: Deuteranopia", "$CBV_Deuteranopia", "toggleColorBlindnessViz" ); diff --git a/Templates/Full/game/Full.torsion.opt b/Templates/Full/game/Full.torsion.opt index f41687c47..2e498d182 100644 --- a/Templates/Full/game/Full.torsion.opt +++ b/Templates/Full/game/Full.torsion.opt @@ -8,13 +8,11 @@ art\main.cs core\main.cs -..\..\Empty\game\core\main.cs -..\..\BaseGame\game\core\main.cs core\scripts\client\postFx\MLAA.cs core\scripts\client\postFx\ssao.cs core\scripts\client\postFx\hdr.cs core\scripts\client\postFx\dof.cs core\scripts\client\postFx\caustics.cs -..\..\..\..\..\RnDBuildTest\My Projects\RnDTest\game\modules\TheFactory\components\FakeGISpotlight.cs +tools\worldEditor\main.cs