summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/VertexManagerBase.cpp
diff options
context:
space:
mode:
authorJordan Woyak <jordan.woyak@gmail.com>2025-05-03 02:48:44 -0500
committerJordan Woyak <jordan.woyak@gmail.com>2025-11-02 17:30:43 -0600
commitf289b06e0db8bba6a3491d6e3cf0c2dd1b7a29fa (patch)
tree4e95a04a656f571e4dc0a7024348d22c5a1c662e /Source/Core/VideoCommon/VertexManagerBase.cpp
parent9c28f19e56307ac4de750ffa6ffb8c4e15e55def (diff)
Common: Make HookableEvent use non-static data.
Co-authored-by: Dentomologist <dentomologist@gmail.com>
Diffstat (limited to 'Source/Core/VideoCommon/VertexManagerBase.cpp')
-rw-r--r--Source/Core/VideoCommon/VertexManagerBase.cpp10
1 files changed, 6 insertions, 4 deletions
diff --git a/Source/Core/VideoCommon/VertexManagerBase.cpp b/Source/Core/VideoCommon/VertexManagerBase.cpp
index 1797cb559f..1af9ad8eb4 100644
--- a/Source/Core/VideoCommon/VertexManagerBase.cpp
+++ b/Source/Core/VideoCommon/VertexManagerBase.cpp
@@ -118,9 +118,11 @@ VertexManagerBase::~VertexManagerBase() = default;
bool VertexManagerBase::Initialize()
{
- m_frame_end_event =
- AfterFrameEvent::Register([this](Core::System&) { OnEndFrame(); }, "VertexManagerBase");
- m_after_present_event = AfterPresentEvent::Register(
+ auto& video_events = GetVideoEvents();
+
+ m_frame_end_event = video_events.after_frame_event.Register(
+ [this](Core::System&) { OnEndFrame(); }, "VertexManagerBase");
+ m_after_present_event = video_events.after_present_event.Register(
[this](const PresentInfo& pi) { m_ticks_elapsed = pi.emulated_timestamp; },
"VertexManagerBase");
m_index_generator.Init();
@@ -442,7 +444,7 @@ void VertexManagerBase::Flush()
if (m_draw_counter == 0)
{
// This is more or less the start of the Frame
- BeforeFrameEvent::Trigger();
+ GetVideoEvents().before_frame_event.Trigger();
}
if (xfmem.numTexGen.numTexGens != bpmem.genMode.numtexgens ||