mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-11 14:44:36 +00:00
Merge pull request #1151 from Azaezel/alpha41/fixCaptureFlag
probe capture fixes
This commit is contained in:
commit
c1eaa73ee6
8 changed files with 104 additions and 30 deletions
|
|
@ -184,6 +184,10 @@ void ReflectionProbe::initPersistFields()
|
|||
"@note Only works for shadow mapped lights.\n\n"
|
||||
"@ingroup Lighting");
|
||||
|
||||
Con::addVariable("$Probes::Capturing", TypeBool, &RenderProbeMgr::smBakeReflectionProbes,
|
||||
"Toggles probe rendering capture state.\n\n"
|
||||
"@ingroup Lighting");
|
||||
|
||||
Con::addVariable("$Light::renderPreviewProbes", TypeBool, &ReflectionProbe::smRenderPreviewProbes,
|
||||
"Toggles rendering of light frustums when the light is selected in the editor.\n\n"
|
||||
"@note Only works for shadow mapped lights.\n\n"
|
||||
|
|
@ -823,7 +827,7 @@ void ReflectionProbe::createEditorResources()
|
|||
|
||||
void ReflectionProbe::prepRenderImage(SceneRenderState *state)
|
||||
{
|
||||
if (!mEnabled || (!RenderProbeMgr::smRenderReflectionProbes && !dStrcmp(Con::getVariable("$Probes::Capturing", "0"),"1")))
|
||||
if (!mEnabled || (!RenderProbeMgr::smRenderReflectionProbes || RenderProbeMgr::smBakeReflectionProbes))
|
||||
return;
|
||||
|
||||
Point3F distVec = getRenderPosition() - state->getCameraPosition();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue