mirror of
https://github.com/RetroDECK/Duckstation.git
synced 2024-11-25 23:25:41 +00:00
GPU: Add virtual call when buffers are swapped
This commit is contained in:
parent
0c3cf1f5f8
commit
80d1056ddf
|
@ -1291,6 +1291,7 @@ void GPU::WriteGP1(u32 value)
|
||||||
SynchronizeCRTC();
|
SynchronizeCRTC();
|
||||||
m_crtc_state.regs.display_address_start = new_value;
|
m_crtc_state.regs.display_address_start = new_value;
|
||||||
UpdateCRTCDisplayParameters();
|
UpdateCRTCDisplayParameters();
|
||||||
|
OnBufferSwapped();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
@ -2833,6 +2834,10 @@ void GPU::DrawRendererStats()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void GPU::OnBufferSwapped()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
void GPU::GetStatsString(SmallStringBase& str)
|
void GPU::GetStatsString(SmallStringBase& str)
|
||||||
{
|
{
|
||||||
if (IsHardwareRenderer())
|
if (IsHardwareRenderer())
|
||||||
|
|
|
@ -318,6 +318,7 @@ protected:
|
||||||
virtual void UpdateCLUT(GPUTexturePaletteReg reg, bool clut_is_8bit) = 0;
|
virtual void UpdateCLUT(GPUTexturePaletteReg reg, bool clut_is_8bit) = 0;
|
||||||
virtual void UpdateDisplay() = 0;
|
virtual void UpdateDisplay() = 0;
|
||||||
virtual void DrawRendererStats();
|
virtual void DrawRendererStats();
|
||||||
|
virtual void OnBufferSwapped();
|
||||||
|
|
||||||
ALWAYS_INLINE_RELEASE void AddDrawTriangleTicks(s32 x1, s32 y1, s32 x2, s32 y2, s32 x3, s32 y3, bool shaded,
|
ALWAYS_INLINE_RELEASE void AddDrawTriangleTicks(s32 x1, s32 y1, s32 x2, s32 y2, s32 x3, s32 y3, bool shaded,
|
||||||
bool textured, bool semitransparent)
|
bool textured, bool semitransparent)
|
||||||
|
|
|
@ -3412,6 +3412,11 @@ void GPU_HW::UpdateDownsamplingLevels()
|
||||||
g_gpu_device->RecycleTexture(std::move(m_downsample_texture));
|
g_gpu_device->RecycleTexture(std::move(m_downsample_texture));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void GPU_HW::OnBufferSwapped()
|
||||||
|
{
|
||||||
|
GL_INS("OnBufferSwapped()");
|
||||||
|
}
|
||||||
|
|
||||||
void GPU_HW::DownsampleFramebuffer()
|
void GPU_HW::DownsampleFramebuffer()
|
||||||
{
|
{
|
||||||
GPUTexture* source = m_display_texture;
|
GPUTexture* source = m_display_texture;
|
||||||
|
|
|
@ -200,6 +200,7 @@ private:
|
||||||
void UpdateCLUT(GPUTexturePaletteReg reg, bool clut_is_8bit) override;
|
void UpdateCLUT(GPUTexturePaletteReg reg, bool clut_is_8bit) override;
|
||||||
void FlushRender() override;
|
void FlushRender() override;
|
||||||
void DrawRendererStats() override;
|
void DrawRendererStats() override;
|
||||||
|
void OnBufferSwapped() override;
|
||||||
|
|
||||||
bool BlitVRAMReplacementTexture(const TextureReplacementTexture* tex, u32 dst_x, u32 dst_y, u32 width, u32 height);
|
bool BlitVRAMReplacementTexture(const TextureReplacementTexture* tex, u32 dst_x, u32 dst_y, u32 width, u32 height);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue