Fix crash when executing `TubeTrailMesh.get_faces()` with GLES3

This commit is contained in:
Haoyu Qiu 2022-08-29 13:05:10 +08:00
parent 58f8f3a40e
commit 7c77cd0f7b
1 changed files with 4 additions and 0 deletions

View File

@ -352,6 +352,10 @@ RS::SurfaceData MeshStorage::mesh_get_surface(RID p_mesh, int p_surface) const {
sd.attribute_data = Utilities::buffer_get_data(GL_ARRAY_BUFFER, s.attribute_buffer, s.attribute_buffer_size);
}
if (s.skin_buffer != 0) {
sd.skin_data = Utilities::buffer_get_data(GL_ARRAY_BUFFER, s.skin_buffer, s.skin_buffer_size);
}
sd.vertex_count = s.vertex_count;
sd.index_count = s.index_count;
sd.primitive = s.primitive;