Merge pull request #34655 from MadEqua/fix-multimesh-gles3

Reset GLES3 MultiMesh buffer id when reallocating.
This commit is contained in:
Rémi Verschelde 2019-12-30 16:10:52 +01:00 committed by GitHub
commit 2691a8ec71
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -4454,6 +4454,7 @@ void RasterizerStorageGLES3::multimesh_allocate(RID p_multimesh, int p_instances
if (multimesh->buffer) { if (multimesh->buffer) {
glDeleteBuffers(1, &multimesh->buffer); glDeleteBuffers(1, &multimesh->buffer);
multimesh->data.resize(0); multimesh->data.resize(0);
multimesh->buffer = 0;
} }
multimesh->size = p_instances; multimesh->size = p_instances;