mirror of
https://github.com/libretro/RetroArch
synced 2025-04-01 04:20:27 +00:00
(D3D9) Some cleanups
This commit is contained in:
parent
e4b959a841
commit
d07c3242cf
@ -576,7 +576,9 @@ void D3DVideo::deinit(void)
|
|||||||
{
|
{
|
||||||
deinit_font();
|
deinit_font();
|
||||||
deinit_chain();
|
deinit_chain();
|
||||||
|
#ifdef HAVE_CG
|
||||||
deinit_cg();
|
deinit_cg();
|
||||||
|
#endif
|
||||||
|
|
||||||
needs_restore = false;
|
needs_restore = false;
|
||||||
}
|
}
|
||||||
@ -789,13 +791,13 @@ bool D3DVideo::init_cg(void)
|
|||||||
|
|
||||||
void D3DVideo::deinit_cg(void)
|
void D3DVideo::deinit_cg(void)
|
||||||
{
|
{
|
||||||
if (cgCtx)
|
if (!cgCtx)
|
||||||
{
|
return;
|
||||||
cgD3D9UnloadAllPrograms();
|
|
||||||
cgD3D9SetDevice(NULL);
|
cgD3D9UnloadAllPrograms();
|
||||||
cgDestroyContext(cgCtx);
|
cgD3D9SetDevice(NULL);
|
||||||
cgCtx = NULL;
|
cgDestroyContext(cgCtx);
|
||||||
}
|
cgCtx = NULL;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user