mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-12 15:14:35 +00:00
crashfix. free will eventually lead to destroyself so don't doubleup or it trys to kill the dead. zombu bad.
This commit is contained in:
parent
d484a1a46e
commit
b4e28343da
1 changed files with 3 additions and 6 deletions
|
|
@ -71,19 +71,16 @@ ProbeRenderInst::ProbeRenderInst() : SystemInterface(),
|
||||||
|
|
||||||
ProbeRenderInst::~ProbeRenderInst()
|
ProbeRenderInst::~ProbeRenderInst()
|
||||||
{
|
{
|
||||||
if (mCubemap && !mCubemap->isNull())
|
if (mCubemap && mCubemap->isValid())
|
||||||
{
|
{
|
||||||
mCubemap->getPointer()->destroySelf();
|
|
||||||
mCubemap->free();
|
mCubemap->free();
|
||||||
}
|
}
|
||||||
if (mIrradianceCubemap && !mIrradianceCubemap->isNull())
|
if (mIrradianceCubemap && mIrradianceCubemap->isValid())
|
||||||
{
|
{
|
||||||
mIrradianceCubemap->getPointer()->destroySelf();
|
|
||||||
mIrradianceCubemap->free();
|
mIrradianceCubemap->free();
|
||||||
}
|
}
|
||||||
if (mBRDFTexture && !mBRDFTexture->isNull())
|
if (mBRDFTexture && mBRDFTexture->isValid())
|
||||||
{
|
{
|
||||||
mBRDFTexture->getPointer()->destroySelf();
|
|
||||||
mBRDFTexture->free();
|
mBRDFTexture->free();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue