mirror of https://github.com/axmolengine/axmol.git
release default fbo
This commit is contained in:
parent
e8d853934b
commit
aa38dfba89
|
@ -397,7 +397,6 @@ FrameBuffer::FrameBuffer()
|
||||||
|
|
||||||
FrameBuffer::~FrameBuffer()
|
FrameBuffer::~FrameBuffer()
|
||||||
{
|
{
|
||||||
if(!isDefaultFBO())
|
|
||||||
{
|
{
|
||||||
CC_SAFE_RELEASE_NULL(_rt);
|
CC_SAFE_RELEASE_NULL(_rt);
|
||||||
CC_SAFE_RELEASE_NULL(_rtDepthStencil);
|
CC_SAFE_RELEASE_NULL(_rtDepthStencil);
|
||||||
|
@ -407,6 +406,8 @@ FrameBuffer::~FrameBuffer()
|
||||||
#if CC_ENABLE_CACHE_TEXTURE_DATA
|
#if CC_ENABLE_CACHE_TEXTURE_DATA
|
||||||
Director::getInstance()->getEventDispatcher()->removeEventListener(_dirtyFBOListener);
|
Director::getInstance()->getEventDispatcher()->removeEventListener(_dirtyFBOListener);
|
||||||
#endif
|
#endif
|
||||||
|
if (isDefaultFBO())
|
||||||
|
_defaultFBO = nullptr;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue