summaryrefslogtreecommitdiff
path: root/servers/xr/xr_interface.h
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2022-01-26 13:30:07 +0100
committerGitHub <noreply@github.com>2022-01-26 13:30:07 +0100
commit1ce6f6b30920d664c01a4dc911e506b116cac827 (patch)
treedc2bfbf070905b41d3bce7b81220fa622d98a6fb /servers/xr/xr_interface.h
parent5eaa93e6b06c6476d2e87c7c681e4abac750181a (diff)
parent98e5cd24dbe1151e129883731b26ec8f521ee57f (diff)
Merge pull request #57240 from BastiaanOlij/xrinterface_render_hooks
Diffstat (limited to 'servers/xr/xr_interface.h')
-rw-r--r--servers/xr/xr_interface.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/servers/xr/xr_interface.h b/servers/xr/xr_interface.h
index aee98f8fee..6e105ffc26 100644
--- a/servers/xr/xr_interface.h
+++ b/servers/xr/xr_interface.h
@@ -123,10 +123,13 @@ public:
// note, external color/depth/vrs texture support will be added here soon.
- virtual Vector<BlitToScreen> commit_views(RID p_render_target, const Rect2 &p_screen_rect) = 0; /* commit rendered views to the XR interface */
-
virtual void process() = 0;
- virtual void notification(int p_what);
+ virtual void pre_render(){};
+ virtual bool pre_draw_viewport(RID p_render_target) { return true; }; /* inform XR interface we are about to start our viewport draw process */
+ virtual Vector<BlitToScreen> post_draw_viewport(RID p_render_target, const Rect2 &p_screen_rect) = 0; /* inform XR interface we finished our viewport draw process */
+ virtual void end_frame(){};
+
+ virtual void notification(int p_what){};
XRInterface();
~XRInterface();