mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-16 00:54:54 +00:00
uninitialized variables-lighting
This commit is contained in:
parent
9fef1b3cd1
commit
f52c3d5ed2
6 changed files with 15 additions and 7 deletions
|
|
@ -70,7 +70,7 @@ protected:
|
||||||
GFXStateBlockRef mLitState[NUM_LIT_STATES][2];
|
GFXStateBlockRef mLitState[NUM_LIT_STATES][2];
|
||||||
|
|
||||||
public:
|
public:
|
||||||
LightMatInstance(Material &mat) : Parent(mat), mLightMapParamsSC(NULL), mInternalPass(false) {}
|
LightMatInstance(Material &mat) : Parent(mat), mLightMapParamsSC(NULL), mInternalPass(false), mSpecialLight(NULL) {}
|
||||||
|
|
||||||
virtual bool init( const FeatureSet &features, const GFXVertexFormat *vertexFormat );
|
virtual bool init( const FeatureSet &features, const GFXVertexFormat *vertexFormat );
|
||||||
virtual bool setupPass( SceneRenderState *state, const SceneData &sgData );
|
virtual bool setupPass( SceneRenderState *state, const SceneData &sgData );
|
||||||
|
|
|
||||||
|
|
@ -63,6 +63,9 @@ AdvancedLightManager::AdvancedLightManager()
|
||||||
{
|
{
|
||||||
mLightBinManager = NULL;
|
mLightBinManager = NULL;
|
||||||
mLastShader = NULL;
|
mLastShader = NULL;
|
||||||
|
mLastConstants = NULL;
|
||||||
|
mSpherePrimitiveCount = 0;
|
||||||
|
mConePrimitiveCount = 0;
|
||||||
mAvailableSLInterfaces = NULL;
|
mAvailableSLInterfaces = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -55,7 +55,7 @@ BlobShadow::BlobShadow(SceneObject* parentObject, LightInfo* light, TSShapeInsta
|
||||||
mRadius = 0.0f;
|
mRadius = 0.0f;
|
||||||
mLastRenderTime = 0;
|
mLastRenderTime = 0;
|
||||||
mDepthBias = -0.0002f;
|
mDepthBias = -0.0002f;
|
||||||
|
mInvShadowDistance = 1.0f;
|
||||||
generateGenericShadowBitmap(smGenericShadowDim);
|
generateGenericShadowBitmap(smGenericShadowDim);
|
||||||
setupStateBlocks();
|
setupStateBlocks();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -440,7 +440,8 @@ SceneLighting::SceneLighting(AvailableSLInterfaces* lightingInterfaces)
|
||||||
mStartTime = 0;
|
mStartTime = 0;
|
||||||
mFileName[0] = '\0';
|
mFileName[0] = '\0';
|
||||||
mSceneManager = NULL;
|
mSceneManager = NULL;
|
||||||
|
sgTimeTemp = 0;
|
||||||
|
sgTimeTemp2 = 0;
|
||||||
// Registering vars more than once doesn't hurt anything.
|
// Registering vars more than once doesn't hurt anything.
|
||||||
Con::addVariable("$sceneLighting::terminateLighting", TypeBool, &gTerminateLighting);
|
Con::addVariable("$sceneLighting::terminateLighting", TypeBool, &gTerminateLighting);
|
||||||
Con::addVariable("$sceneLighting::lightingProgress", TypeF32, &gLightingProgress);
|
Con::addVariable("$sceneLighting::lightingProgress", TypeF32, &gLightingProgress);
|
||||||
|
|
@ -1084,4 +1085,4 @@ bool SceneLighting::ObjectProxy::setPersistInfo(PersistInfo::PersistChunk * chun
|
||||||
{
|
{
|
||||||
mChunkCRC = chunk->mChunkCRC;
|
mChunkCRC = chunk->mChunkCRC;
|
||||||
return(true);
|
return(true);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -64,8 +64,12 @@ F32 PSSMLightShadowMap::smSmallestVisiblePixelSize = 25.0f;
|
||||||
|
|
||||||
PSSMLightShadowMap::PSSMLightShadowMap( LightInfo *light )
|
PSSMLightShadowMap::PSSMLightShadowMap( LightInfo *light )
|
||||||
: LightShadowMap( light ),
|
: LightShadowMap( light ),
|
||||||
mNumSplits( 1 )
|
mNumSplits( 1 ),
|
||||||
{
|
mLogWeight(0.91f)
|
||||||
|
{
|
||||||
|
for (U32 i = 0; i <= MAX_SPLITS; i++) //% depth distance
|
||||||
|
mSplitDist[i] = mPow(F32(i/MAX_SPLITS),2.0f);
|
||||||
|
|
||||||
mIsViewDependent = true;
|
mIsViewDependent = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -52,7 +52,7 @@ class ShadowMapPass
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
ShadowMapPass() {} // Only called by ConsoleSystem
|
ShadowMapPass() : mTimer(NULL), mLightManager(NULL), mShadowManager(NULL), mActiveLights(0), mPrevCamFov(90.0f) {} // Only called by ConsoleSystem
|
||||||
ShadowMapPass(LightManager* LightManager, ShadowMapManager* ShadowManager);
|
ShadowMapPass(LightManager* LightManager, ShadowMapManager* ShadowManager);
|
||||||
virtual ~ShadowMapPass();
|
virtual ~ShadowMapPass();
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue