mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
VideoBackends: Simplify initialization and deinitialization of resources
Approximately three or four times now, the issue of pointers being in an inconsistent state been an issue in the video backend renderers with regards to tripping up other developers. Global (ugh) resources are put into a unique_ptr and will always have a well-defined state of being - null or not null
This commit is contained in:
@ -5,6 +5,7 @@
|
||||
// Stub implementation of the Host_* callbacks for tests. These implementations
|
||||
// do nothing except return default values when required.
|
||||
|
||||
#include <memory>
|
||||
#include <string>
|
||||
|
||||
#include "Common/GL/GLInterfaceBase.h"
|
||||
@ -26,4 +27,4 @@ bool Host_RendererIsFullscreen() { return false; }
|
||||
void Host_ConnectWiimote(int, bool) {}
|
||||
void Host_SetWiiMoteConnectionState(int) {}
|
||||
void Host_ShowVideoConfig(void*, const std::string&, const std::string&) {}
|
||||
cInterfaceBase* HostGL_CreateGLInterface() { return nullptr; }
|
||||
std::unique_ptr<cInterfaceBase> HostGL_CreateGLInterface() { return nullptr; }
|
||||
|
Reference in New Issue
Block a user