mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-24 14:49:42 -06:00
VideoBackend: Remove simple wrapper functions.
This commit is contained in:
@ -29,28 +29,12 @@ static volatile struct
|
||||
u32 fbHeight;
|
||||
} s_beginFieldArgs;
|
||||
|
||||
void VideoBackendBase::EmuStateChange(EMUSTATE_CHANGE newState)
|
||||
{
|
||||
EmulatorState(newState == EMUSTATE_CHANGE_PLAY);
|
||||
}
|
||||
|
||||
// Enter and exit the video loop
|
||||
void VideoBackendBase::Video_EnterLoop()
|
||||
{
|
||||
RunGpuLoop();
|
||||
}
|
||||
|
||||
void VideoBackendBase::Video_ExitLoop()
|
||||
{
|
||||
ExitGpuLoop();
|
||||
s_FifoShuttingDown.Set();
|
||||
}
|
||||
|
||||
void VideoBackendBase::Video_SetRendering(bool bEnabled)
|
||||
{
|
||||
Fifo_SetRendering(bEnabled);
|
||||
}
|
||||
|
||||
// Run from the CPU thread (from VideoInterface.cpp)
|
||||
void VideoBackendBase::Video_BeginField(u32 xfbAddr, u32 fbWidth, u32 fbStride, u32 fbHeight)
|
||||
{
|
||||
@ -82,23 +66,6 @@ void VideoBackendBase::Video_EndField()
|
||||
}
|
||||
}
|
||||
|
||||
void VideoBackendBase::Video_AddMessage(const std::string& msg, u32 milliseconds)
|
||||
{
|
||||
OSD::AddMessage(msg, milliseconds);
|
||||
}
|
||||
|
||||
void VideoBackendBase::Video_ClearMessages()
|
||||
{
|
||||
OSD::ClearMessages();
|
||||
}
|
||||
|
||||
// Screenshot
|
||||
bool VideoBackendBase::Video_Screenshot(const std::string& filename)
|
||||
{
|
||||
Renderer::SetScreenshot(filename.c_str());
|
||||
return true;
|
||||
}
|
||||
|
||||
u32 VideoBackendBase::Video_AccessEFB(EFBAccessType type, u32 x, u32 y, u32 InputData)
|
||||
{
|
||||
if (!g_ActiveConfig.bEFBAccessEnable)
|
||||
@ -225,34 +192,3 @@ void VideoBackendBase::CheckInvalidState()
|
||||
TextureCacheBase::Invalidate();
|
||||
}
|
||||
}
|
||||
|
||||
void VideoBackendBase::PauseAndLock(bool doLock, bool unpauseOnUnlock)
|
||||
{
|
||||
Fifo_PauseAndLock(doLock, unpauseOnUnlock);
|
||||
}
|
||||
|
||||
void VideoBackendBase::RunLoop(bool enable)
|
||||
{
|
||||
VideoCommon_RunLoop(enable);
|
||||
}
|
||||
|
||||
void VideoBackendBase::Video_GatherPipeBursted()
|
||||
{
|
||||
CommandProcessor::GatherPipeBursted();
|
||||
}
|
||||
|
||||
int VideoBackendBase::Video_Sync(int ticks)
|
||||
{
|
||||
return Fifo_Update(ticks);
|
||||
}
|
||||
|
||||
void VideoBackendBase::RegisterCPMMIO(MMIO::Mapping* mmio, u32 base)
|
||||
{
|
||||
CommandProcessor::RegisterMMIO(mmio, base);
|
||||
}
|
||||
|
||||
void VideoBackendBase::UpdateWantDeterminism(bool want)
|
||||
{
|
||||
Fifo_UpdateWantDeterminism(want);
|
||||
}
|
||||
|
||||
|
@ -62,13 +62,10 @@ class VideoBackendBase
|
||||
public:
|
||||
virtual ~VideoBackendBase() {}
|
||||
|
||||
void EmuStateChange(EMUSTATE_CHANGE);
|
||||
|
||||
virtual unsigned int PeekMessages() = 0;
|
||||
|
||||
virtual bool Initialize(void* window_handle) = 0;
|
||||
virtual void Shutdown() = 0;
|
||||
void RunLoop(bool enable);
|
||||
|
||||
virtual std::string GetName() const = 0;
|
||||
virtual std::string GetDisplayName() const { return GetName(); }
|
||||
@ -76,7 +73,6 @@ public:
|
||||
virtual void ShowConfig(void*) = 0;
|
||||
|
||||
virtual void Video_Prepare() = 0;
|
||||
void Video_EnterLoop();
|
||||
void Video_ExitLoop();
|
||||
virtual void Video_Cleanup() = 0; // called from gl/d3d thread
|
||||
|
||||
@ -87,35 +83,15 @@ public:
|
||||
u32 Video_GetQueryResult(PerfQueryType type);
|
||||
u16 Video_GetBoundingBox(int index);
|
||||
|
||||
void Video_AddMessage(const std::string& msg, unsigned int milliseconds);
|
||||
void Video_ClearMessages();
|
||||
bool Video_Screenshot(const std::string& filename);
|
||||
|
||||
void Video_SetRendering(bool bEnabled);
|
||||
|
||||
void Video_GatherPipeBursted();
|
||||
|
||||
int Video_Sync(int ticks);
|
||||
|
||||
// Registers MMIO handlers for the CommandProcessor registers.
|
||||
void RegisterCPMMIO(MMIO::Mapping* mmio, u32 base);
|
||||
|
||||
static void PopulateList();
|
||||
static void ClearList();
|
||||
static void ActivateBackend(const std::string& name);
|
||||
|
||||
// waits until is paused and fully idle, and acquires a lock on that state.
|
||||
// or, if doLock is false, releases a lock on that state and optionally unpauses.
|
||||
// calls must be balanced and non-recursive (once with doLock true, then once with doLock false).
|
||||
void PauseAndLock(bool doLock, bool unpauseOnUnlock = true);
|
||||
|
||||
// the implementation needs not do synchronization logic, because calls to it are surrounded by PauseAndLock now
|
||||
void DoState(PointerWrap &p);
|
||||
|
||||
void CheckInvalidState();
|
||||
|
||||
void UpdateWantDeterminism(bool want);
|
||||
|
||||
protected:
|
||||
void InitializeShared();
|
||||
|
||||
|
Reference in New Issue
Block a user