1
$\begingroup$

have a basic scene in blender, one plane and one building in the center.

When I export that without materials, it weighs ~100kb, but with the materials, it’s 40mb. I’ve inspected my exported model with https://gltf.report/ and it looks like some textures are very heavy because I’m importing procedural textures from blenderkit.

Questions:

  1. If I bake the textures, should I do it for the whole building ( 1 UV map ) or each object individually?
  2. I’m planning to build the whole city, so eventually, 1 material will be applied to 100 places, how is it beneficial to bake that material and create 100 UVs rather than referencing that material 100 times?
  3. I have ~50 instances of a window object on the building, is it wise to export that object apart from the rest of the building and then attach it in a three.js scene (game engine) rather than exporting everything at once? Is blender “smart enough” to realize that it’s the same object that repeats and does optimization on its own?

blender scene

$\endgroup$
0

1 Answer 1

0
$\begingroup$
  1. Baking should depend on your target pixel density. Sometimes it is worth baking one object or material into multiple materials when UDIMs are not supported. It goes alone with the manual texture compression. Problematic is baking arbitrary shaders. A popular approach is to construct the building out of smaller baked assets.

  2. If the material is reused a lot it should be a tiled material that you apply across the scene. You can have a mixed approach with some part of the building like statues baked and brick walls tiled. Problematic is baking shaders into tiled textures as they wont be seamless if you just bake them on a plane.

  3. glTF does support instancing. Your windows should be using the same mesh and materials. Look for the settings like not using Apply Modifiers and inspect the .gltf to ensure meshes are reused. Problematic is the further in engine handling because if you just import multiple glTF files into the scene the engine wont automatically recognize that some parts of the building are reused across the glTF files. If buildings share a lot of things they should be imported as a single set of models. And the engine itself should recognize the glTF's instancing.

$\endgroup$
1
  • $\begingroup$ That's part of why instances assets are often maed and assembled into bigger things in the game engine itself rather than the modeling software. $\endgroup$
    – Lauloque
    Commented Apr 17 at 13:52

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .