D3D12: Cleanup startup/shutdown process

Sorts out references that cause some modules to be kept around after
backend shutdown.

Should also solve the issue with errors being thrown due to the config
being loaded after device creation, leading to the incorrect device being
used in a multi-adapter system.
This commit is contained in:
Stenzek
2016-03-07 00:36:37 +10:00
parent 4269abdc3e
commit 9bff187547
4 changed files with 145 additions and 212 deletions

View File

@ -224,8 +224,6 @@ Renderer::Renderer(void*& window_handle)
return;
}
D3D::Create((HWND)window_handle);
s_backbuffer_width = D3D::GetBackBufferWidth();
s_backbuffer_height = D3D::GetBackBufferHeight();
@ -283,7 +281,6 @@ Renderer::~Renderer()
D3D::EndFrame();
D3D::WaitForOutstandingRenderingToComplete();
TeardownDeviceObjects();
D3D::Close();
}
void Renderer::RenderText(const std::string& text, int left, int top, u32 color)