@@ -74,6 +74,10 @@ static vr::EVRCompositorError on_vr_submit_d3d10(vr::IVRCompositor *compositor,
7474
7575 s_vr_swapchain->on_present ();
7676
77+ #if RESHADE_ADDON
78+ reshade::invoke_addon_event<reshade::addon_event::reshade_present>(device_proxy, s_vr_swapchain);
79+ #endif
80+
7781 const auto target_texture = reinterpret_cast <ID3D10Texture2D *>(s_vr_swapchain->get_current_back_buffer ().handle );
7882
7983 // The left and right eye were copied side-by-side to a single texture in 'on_vr_submit', so set bounds accordingly
@@ -130,6 +134,10 @@ static vr::EVRCompositorError on_vr_submit_d3d11(vr::IVRCompositor *compositor,
130134
131135 s_vr_swapchain->on_present ();
132136
137+ #if RESHADE_ADDON
138+ reshade::invoke_addon_event<reshade::addon_event::reshade_present>(device_proxy->_immediate_context , s_vr_swapchain);
139+ #endif
140+
133141 const auto target_texture = reinterpret_cast <ID3D11Texture2D *>(s_vr_swapchain->get_current_back_buffer ().handle );
134142
135143 // The left and right eye were copied side-by-side to a single texture in 'on_vr_submit', so set bounds accordingly
@@ -177,6 +185,10 @@ static vr::EVRCompositorError on_vr_submit_d3d12(vr::IVRCompositor *compositor,
177185
178186 s_vr_swapchain->on_present ();
179187
188+ #if RESHADE_ADDON
189+ reshade::invoke_addon_event<reshade::addon_event::reshade_present>(command_queue_proxy.get (), s_vr_swapchain);
190+ #endif
191+
180192 command_queue_proxy->flush_immediate_command_list ();
181193
182194 lock.unlock ();
@@ -228,6 +240,10 @@ static vr::EVRCompositorError on_vr_submit_opengl(vr::IVRCompositor *compositor,
228240
229241 s_vr_swapchain->on_present ();
230242
243+ #if RESHADE_ADDON
244+ reshade::invoke_addon_event<reshade::addon_event::reshade_present>(g_current_context, s_vr_swapchain);
245+ #endif
246+
231247 const GLuint target_rbo = s_vr_swapchain->get_current_back_buffer ().handle & 0xFFFFFFFF ;
232248
233249 // Target object created in 'on_vr_submit' is a 2D texture
@@ -286,6 +302,10 @@ static vr::EVRCompositorError on_vr_submit_vulkan(vr::IVRCompositor *compositor,
286302
287303 s_vr_swapchain->on_present ();
288304
305+ #if RESHADE_ADDON
306+ reshade::invoke_addon_event<reshade::addon_event::reshade_present>(queue, s_vr_swapchain);
307+ #endif
308+
289309 queue->flush_immediate_command_list ();
290310
291311 vr::VRVulkanTextureData_t target_texture = *texture;
0 commit comments