Performance difference viewer vs API

(Wakyak) #1


I’m noticing slower performance of a model using the viewer API vs the standard viewer. Is this to be expected and if so, is there anything I can do to mitigate the problem?

Cheers /Erik

(Paul Sketch) #2


In the viewer we can optimize the model by merging geometry, materials etc.

If you use the viewer API, as you might need to be able to handle a specific material/geometry, we cannot do that, so it’s off by default

On your side, there’s 2 thing you can do:

  • if you know you don’t need to handle a particular geometry/instance, and/or you’r fine with merged material/geometry, you can enable back the optimisation. (options to add to client init is graph_optimizer: 1, and/or merge_materials: 1)
  • Optimize the mesh on your pipeline side with the fewest geometry/material needed for your application

(Wakyak) #3

Thanks Paul!

Merged all my meshes as a test and it worked wonders. Should be easy to maintain as well.

Cheers /Erik