mirror of
https://github.com/blawar/GLideN64.git
synced 2024-06-25 22:09:35 +00:00
Code cleanup: Move implementation of static get() functions into .cpp files
This commit is contained in:
parent
e00ef89a1b
commit
9dbbeca65c
|
@ -76,6 +76,12 @@ void Combiner_Destroy() {
|
|||
CombinerInfo::get().destroy();
|
||||
}
|
||||
|
||||
CombinerInfo & CombinerInfo::get()
|
||||
{
|
||||
static CombinerInfo info;
|
||||
return info;
|
||||
}
|
||||
|
||||
void CombinerInfo::init()
|
||||
{
|
||||
m_pCurrent = NULL;
|
||||
|
|
|
@ -126,10 +126,7 @@ public:
|
|||
ShaderCombiner * getCurrent() const {return m_pCurrent;}
|
||||
bool isChanged() const {return m_bChanged;}
|
||||
|
||||
static CombinerInfo & get() {
|
||||
static CombinerInfo info;
|
||||
return info;
|
||||
}
|
||||
static CombinerInfo & get();
|
||||
|
||||
void updatePrimColor();
|
||||
void updateEnvColor();
|
||||
|
|
|
@ -227,6 +227,12 @@ DepthBufferList::~DepthBufferList()
|
|||
m_list.clear();
|
||||
}
|
||||
|
||||
DepthBufferList & DepthBufferList::get()
|
||||
{
|
||||
static DepthBufferList depthBufferList;
|
||||
return depthBufferList;
|
||||
}
|
||||
|
||||
void DepthBufferList::init()
|
||||
{
|
||||
m_pCurrent = NULL;
|
||||
|
|
|
@ -43,11 +43,7 @@ public:
|
|||
DepthBuffer *findBuffer(u32 _address);
|
||||
DepthBuffer * getCurrent() const {return m_pCurrent;}
|
||||
|
||||
static DepthBufferList & get()
|
||||
{
|
||||
static DepthBufferList depthBufferList;
|
||||
return depthBufferList;
|
||||
}
|
||||
static DepthBufferList & get();
|
||||
|
||||
const u16 * const getZLUT() const {return m_pzLUT;}
|
||||
|
||||
|
|
|
@ -252,6 +252,12 @@ CachedTexture * FrameBuffer::getTexture()
|
|||
return m_pResolveTexture;
|
||||
}
|
||||
|
||||
FrameBufferList & FrameBufferList::get()
|
||||
{
|
||||
static FrameBufferList frameBufferList;
|
||||
return frameBufferList;
|
||||
}
|
||||
|
||||
void FrameBufferList::init()
|
||||
{
|
||||
m_pCurrent = NULL;
|
||||
|
|
|
@ -60,11 +60,7 @@ public:
|
|||
void correctHeight();
|
||||
void clearBuffersChanged();
|
||||
|
||||
static FrameBufferList & get()
|
||||
{
|
||||
static FrameBufferList frameBufferList;
|
||||
return frameBufferList;
|
||||
}
|
||||
static FrameBufferList & get();
|
||||
|
||||
private:
|
||||
FrameBufferList() : m_pCurrent(NULL) {}
|
||||
|
|
|
@ -78,11 +78,7 @@ public:
|
|||
void SetRenderingCallback(void (*callback)(int));
|
||||
#endif
|
||||
|
||||
static PluginAPI & get()
|
||||
{
|
||||
static PluginAPI api;
|
||||
return api;
|
||||
}
|
||||
static PluginAPI & get();
|
||||
|
||||
private:
|
||||
PluginAPI()
|
||||
|
|
|
@ -427,6 +427,11 @@ inline u32 ReverseDXT(u32 val, u32 lrs, u32 width, u32 size)
|
|||
}
|
||||
/** end RiceVideo cite */
|
||||
|
||||
TextureCache & TextureCache::get() {
|
||||
static TextureCache cache;
|
||||
return cache;
|
||||
}
|
||||
|
||||
void TextureCache::init()
|
||||
{
|
||||
u32 dummyTexture[16] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
|
||||
|
|
|
@ -58,10 +58,7 @@ struct TextureCache
|
|||
void activateDummy(u32 _t);
|
||||
void update(u32 _t);
|
||||
|
||||
static TextureCache & get() {
|
||||
static TextureCache cache;
|
||||
return cache;
|
||||
}
|
||||
static TextureCache & get();
|
||||
|
||||
private:
|
||||
TextureCache() : m_pDummy(NULL), m_hits(0), m_misses(0), m_maxBytes(0), m_cachedBytes(0)
|
||||
|
|
|
@ -17,6 +17,12 @@
|
|||
#include "../Debug.h"
|
||||
#include "../Log.h"
|
||||
|
||||
PluginAPI & PluginAPI::get()
|
||||
{
|
||||
static PluginAPI api;
|
||||
return api;
|
||||
}
|
||||
|
||||
#ifdef RSPTHREAD
|
||||
void RSP_ThreadProc(std::mutex * _pRspThreadMtx, std::mutex * _pPluginThreadMtx, std::condition_variable_any * _pRspThreadCv, std::condition_variable_any * _pPluginThreadCv, API_COMMAND * _pCommand)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue
Block a user