mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
d3d: Release on shutdown in headless.
Could sync it up, just want to be able to run tests without major leaks.
This commit is contained in:
parent
858df90dff
commit
9f3deddef6
2 changed files with 9 additions and 0 deletions
|
@ -121,5 +121,7 @@ void D3D9_Shutdown() {
|
||||||
device->EndScene();
|
device->EndScene();
|
||||||
device->Release();
|
device->Release();
|
||||||
d3d->Release();
|
d3d->Release();
|
||||||
|
DX9::pD3Ddevice = NULL;
|
||||||
|
DX9::pD3Ddevice = NULL;
|
||||||
hWnd = NULL;
|
hWnd = NULL;
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,6 +25,7 @@
|
||||||
#include "base/logging.h"
|
#include "base/logging.h"
|
||||||
#include "thin3d/d3dx9_loader.h"
|
#include "thin3d/d3dx9_loader.h"
|
||||||
#include "GPU/Directx9/helper/global.h"
|
#include "GPU/Directx9/helper/global.h"
|
||||||
|
#include "GPU/Directx9/helper/fbo.h"
|
||||||
#include "file/vfs.h"
|
#include "file/vfs.h"
|
||||||
#include "file/zip_read.h"
|
#include "file/zip_read.h"
|
||||||
|
|
||||||
|
@ -80,6 +81,12 @@ bool WindowsHeadlessHostDx9::InitGL(std::string *error_message)
|
||||||
|
|
||||||
void WindowsHeadlessHostDx9::ShutdownGL()
|
void WindowsHeadlessHostDx9::ShutdownGL()
|
||||||
{
|
{
|
||||||
|
DX9::DestroyShaders();
|
||||||
|
DX9::fbo_shutdown();
|
||||||
|
DX9::pD3Ddevice->EndScene();
|
||||||
|
DX9::pD3Ddevice->Release();
|
||||||
|
DX9::pD3Ddevice = NULL;
|
||||||
|
hWnd = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool WindowsHeadlessHostDx9::ResizeGL()
|
bool WindowsHeadlessHostDx9::ResizeGL()
|
||||||
|
|
Loading…
Add table
Reference in a new issue