Strange model behavior when using InstancedMesh with CameraSync (threebox)

I have a mapbox and CameraSync (threebox/CameraSync.js at 6e6a1ae3878c8557c20eb56ada53af843222f390 · peterqliu/threebox · GitHub) to sync the map with the models.

I need to display a large number of similar objects on the map. I want to use InstancedMesh for optimization, but when using it, objects lose polygons (screenshot below)

There are three objects in the scene:

  1. Without using InstancedMesh
  2. Using InstancedMesh
  3. Using InstancedMesh and an increased scale parameter (with an increase in scale, the model becomes more detailed)

Do you know why these artifacts appear when using InstancedMesh?

I created a demo

Does this issue also occur without using mapbox and CameraSync?

1 Like

Mapbox is only used to get the position of the camera. I think it’s about CameraSync