Fixed crash when resources in use by the Renderer are released
Former-commit-id: 98eedb556f0387f0a5c1cafde2fc74645d1d0457
This commit is contained in:
@@ -59,7 +59,7 @@ bool NzRenderWindow::CopyToImage(NzImage* image) const
|
||||
}
|
||||
#endif
|
||||
|
||||
NzContext* currentContext = NzContext::GetCurrent();
|
||||
const NzContext* currentContext = NzContext::GetCurrent();
|
||||
if (m_context != currentContext)
|
||||
{
|
||||
if (!m_context->SetActive(true))
|
||||
@@ -112,7 +112,7 @@ bool NzRenderWindow::CopyToTexture(NzTexture* texture) const
|
||||
}
|
||||
#endif
|
||||
|
||||
NzContext* currentContext = NzContext::GetCurrent();
|
||||
const NzContext* currentContext = NzContext::GetCurrent();
|
||||
if (m_context != currentContext)
|
||||
{
|
||||
if (!m_context->SetActive(true))
|
||||
|
||||
Reference in New Issue
Block a user