diff options
Diffstat (limited to 'servers')
-rw-r--r-- | servers/rendering/rendering_device.cpp | 4 | ||||
-rw-r--r-- | servers/rendering/rendering_device.h | 5 |
2 files changed, 8 insertions, 1 deletions
diff --git a/servers/rendering/rendering_device.cpp b/servers/rendering/rendering_device.cpp index a3799b0e4d..75ef38354a 100644 --- a/servers/rendering/rendering_device.cpp +++ b/servers/rendering/rendering_device.cpp @@ -60,5 +60,7 @@ Vector<uint8_t> RenderingDevice::shader_compile_from_source(ShaderStage p_stage, } RenderingDevice::RenderingDevice() { - singleton = this; + if (singleton == nullptr) { // there may be more rendering devices later + singleton = this; + } } diff --git a/servers/rendering/rendering_device.h b/servers/rendering/rendering_device.h index 97fe417def..6c58b8fd57 100644 --- a/servers/rendering/rendering_device.h +++ b/servers/rendering/rendering_device.h @@ -1024,6 +1024,11 @@ public: virtual uint32_t get_frame_delay() const = 0; + virtual void submit() = 0; + virtual void sync() = 0; + + virtual RenderingDevice *create_local_device() = 0; + static RenderingDevice *get_singleton(); RenderingDevice(); }; |