summaryrefslogtreecommitdiffstats
path: root/servers/rendering/renderer_rd/storage_rd
diff options
context:
space:
mode:
authorSpartan322 <Megacake1234@gmail.com>2024-11-19 11:38:29 -0500
committerSpartan322 <Megacake1234@gmail.com>2024-11-19 11:39:37 -0500
commitcfc378b251e4330c6b6be949d4c054f9bae48159 (patch)
tree148a5511d3c1d723b2f2f364c832c2ba6f267fcc /servers/rendering/renderer_rd/storage_rd
parent9767837a7ec40697788765e581131cb2cf172567 (diff)
parentfd4c29a189e53a1e085df5b9b9a05cac9351b3ef (diff)
downloadredot-engine-cfc378b251e4330c6b6be949d4c054f9bae48159.tar.gz
Merge commit godotengine/godot@fd4c29a189e53a1e085df5b9b9a05cac9351b3ef
Diffstat (limited to 'servers/rendering/renderer_rd/storage_rd')
-rw-r--r--servers/rendering/renderer_rd/storage_rd/mesh_storage.cpp6
-rw-r--r--servers/rendering/renderer_rd/storage_rd/mesh_storage.h1
2 files changed, 7 insertions, 0 deletions
diff --git a/servers/rendering/renderer_rd/storage_rd/mesh_storage.cpp b/servers/rendering/renderer_rd/storage_rd/mesh_storage.cpp
index 4ada0803f3..5b01f11abf 100644
--- a/servers/rendering/renderer_rd/storage_rd/mesh_storage.cpp
+++ b/servers/rendering/renderer_rd/storage_rd/mesh_storage.cpp
@@ -1999,6 +1999,12 @@ void MeshStorage::_multimesh_set_buffer(RID p_multimesh, const Vector<float> &p_
}
}
+RID MeshStorage::_multimesh_get_buffer_rd_rid(RID p_multimesh) const {
+ MultiMesh *multimesh = multimesh_owner.get_or_null(p_multimesh);
+ ERR_FAIL_NULL_V(multimesh, RID());
+ return multimesh->buffer;
+}
+
Vector<float> MeshStorage::_multimesh_get_buffer(RID p_multimesh) const {
MultiMesh *multimesh = multimesh_owner.get_or_null(p_multimesh);
ERR_FAIL_NULL_V(multimesh, Vector<float>());
diff --git a/servers/rendering/renderer_rd/storage_rd/mesh_storage.h b/servers/rendering/renderer_rd/storage_rd/mesh_storage.h
index e70b7568e0..584583eb6d 100644
--- a/servers/rendering/renderer_rd/storage_rd/mesh_storage.h
+++ b/servers/rendering/renderer_rd/storage_rd/mesh_storage.h
@@ -653,6 +653,7 @@ public:
virtual Color _multimesh_instance_get_custom_data(RID p_multimesh, int p_index) const override;
virtual void _multimesh_set_buffer(RID p_multimesh, const Vector<float> &p_buffer) override;
+ virtual RID _multimesh_get_buffer_rd_rid(RID p_multimesh) const override;
virtual Vector<float> _multimesh_get_buffer(RID p_multimesh) const override;
virtual void _multimesh_set_visible_instances(RID p_multimesh, int p_visible) override;