summaryrefslogtreecommitdiff
path: root/servers/rendering/rendering_server_default.cpp
diff options
context:
space:
mode:
authorBastiaan Olij <mux213@gmail.com>2022-01-26 12:25:20 +1100
committerBastiaan Olij <mux213@gmail.com>2022-01-26 13:55:44 +1100
commit98e5cd24dbe1151e129883731b26ec8f521ee57f (patch)
tree2d280f268053d1ea49e3de44ba98b75b62510cd1 /servers/rendering/rendering_server_default.cpp
parentb25c7fef04499a7bee2333184bd7e5879d304eee (diff)
Improve XRInterface hooks into rendering
Diffstat (limited to 'servers/rendering/rendering_server_default.cpp')
-rw-r--r--servers/rendering/rendering_server_default.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/servers/rendering/rendering_server_default.cpp b/servers/rendering/rendering_server_default.cpp
index d7e9d210db..d93aad5d7b 100644
--- a/servers/rendering/rendering_server_default.cpp
+++ b/servers/rendering/rendering_server_default.cpp
@@ -93,6 +93,12 @@ void RenderingServerDefault::_draw(bool p_swap_buffers, double frame_step) {
RSG::rasterizer->end_frame(p_swap_buffers);
+ XRServer *xr_server = XRServer::get_singleton();
+ if (xr_server != nullptr) {
+ // let our XR server know we're done so we can get our frame timing
+ xr_server->end_frame();
+ }
+
RSG::canvas->update_visibility_notifiers();
RSG::scene->update_visibility_notifiers();