summaryrefslogtreecommitdiff
path: root/servers/rendering/rendering_device.h
diff options
context:
space:
mode:
authorreduz <reduzio@gmail.com>2021-08-16 14:51:29 -0300
committerreduz <reduzio@gmail.com>2021-08-17 13:52:06 -0300
commit6027cd0a1dc0726b039a96c8d1b811158464540b (patch)
treeeecea01b7a54ba385a06b83b599263a0cc6db5bf /servers/rendering/rendering_device.h
parent72cb4529375de4e3c7511cb7be4ffe8e0103d8ca (diff)
Fixes to mobile renderer
* Make sure shaders are named, to aid in debug in case of failure * SceneRenderRD was being wrongly initialized (virtual functions being called when derivative class not initialized). * Fixed some bugs resulting on the above being corrected.
Diffstat (limited to 'servers/rendering/rendering_device.h')
-rw-r--r--servers/rendering/rendering_device.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/servers/rendering/rendering_device.h b/servers/rendering/rendering_device.h
index bb028cb84c..e2d207dab2 100644
--- a/servers/rendering/rendering_device.h
+++ b/servers/rendering/rendering_device.h
@@ -668,9 +668,9 @@ public:
};
virtual String shader_get_binary_cache_key() const = 0;
- virtual Vector<uint8_t> shader_compile_binary_from_spirv(const Vector<ShaderStageSPIRVData> &p_spirv) = 0;
+ virtual Vector<uint8_t> shader_compile_binary_from_spirv(const Vector<ShaderStageSPIRVData> &p_spirv, const String &p_shader_name = "") = 0;
- virtual RID shader_create_from_spirv(const Vector<ShaderStageSPIRVData> &p_spirv);
+ virtual RID shader_create_from_spirv(const Vector<ShaderStageSPIRVData> &p_spirv, const String &p_shader_name = "");
virtual RID shader_create_from_bytecode(const Vector<uint8_t> &p_shader_binary) = 0;
virtual uint32_t shader_get_vertex_input_attribute_mask(RID p_shader) = 0;
@@ -1200,8 +1200,8 @@ protected:
RID _vertex_array_create(uint32_t p_vertex_count, VertexFormatID p_vertex_format, const TypedArray<RID> &p_src_buffers);
Ref<RDShaderSPIRV> _shader_compile_spirv_from_source(const Ref<RDShaderSource> &p_source, bool p_allow_cache = true);
- Vector<uint8_t> _shader_compile_binary_from_spirv(const Ref<RDShaderSPIRV> &p_bytecode);
- RID _shader_create_from_spirv(const Ref<RDShaderSPIRV> &p_spirv);
+ Vector<uint8_t> _shader_compile_binary_from_spirv(const Ref<RDShaderSPIRV> &p_bytecode, const String &p_shader_name = "");
+ RID _shader_create_from_spirv(const Ref<RDShaderSPIRV> &p_spirv, const String &p_shader_name = "");
RID _uniform_set_create(const Array &p_uniforms, RID p_shader, uint32_t p_shader_set);