Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions dist/preview release/what's new.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,4 +95,6 @@
- Fix texture being inverted on the Y axis by default when using TextureAsset or AssetManager ([broederj](https://github.com/broederj))
- Fix `TexturePacker` cross-origin image requests, fix falsy default options ([ludevik](https://github.com/ludevik))

- Fix submesh recreation when it should not ([Popov72](https://github.com/Popov72)

## Breaking changes
4 changes: 2 additions & 2 deletions src/Meshes/mesh.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1113,12 +1113,12 @@ export class Mesh extends AbstractMesh implements IGetSetVerticesData {
needToRecreate = true;
} else {
for (var submesh of this.subMeshes) {
if (submesh.indexStart + submesh.indexCount >= totalIndices) {
if (submesh.indexStart + submesh.indexCount > totalIndices) {
needToRecreate = true;
break;
}

if (submesh.verticesStart + submesh.verticesCount >= totalVertices) {
if (submesh.verticesStart + submesh.verticesCount > totalVertices) {
needToRecreate = true;
break;
}
Expand Down