When collecting renderables, especially when batching them for instancing, generate a unique determinist identifier dependent on the content of the collection. This identifier will then be compared to the identifier of the previous frame. If the identifiers are the same, we will use the old instances VBO. If the identifiers differ, we will regenerate the VBO.
When collecting renderables, especially when batching them for instancing, generate a unique determinist identifier dependent on the content of the collection. This identifier will then be compared to the identifier of the previous frame. If the identifiers are the same, we will use the old instances VBO. If the identifiers differ, we will regenerate the VBO.