What is the recommended GLB size to be imported

Hello everyone, I am relatively new to 3d and babylon. I have a question for those of you who are more experienced with Babylon and 3D in the browser in general. I am experimenting with some 3D art in the browser with babylon, while using some imported GLBs I make with Blender. What would you guys recommend as the size limit for any imported GLB? For example if I am creating some 3d art to be displayed in the browser, how big should the imported glb file ever be(this would be total to be rendered in the browser, if there are multiple glbs)? 500kb, 1mb, 10mb, 100mb? What is a realistic limit for the size/number of glb’s to be a reasonable amount that is usable in most machines?

THANKS!

well , it not really anything about file size. Although for a website having too big files to load is not really a good choice as long load times can make users leave the site.

For any real time 3D engine it is really all about

instance count - amount of individual objects in the scene

poly count - amount of polygons in the scene

draw calls - amount of times the cpu has to interact with the GPU

im not sure what the average is , I simply aim for as low as possible and as high as possible. Testing with several real world devices with different strengths myself.

Thankfully I have never had to build anything that causes crashes on devices but you can read about it in the forums. Loading too many big textures on IOS for example will cause a crash due to memory.

Also , different post process effects have different rendering costs.

Im not sure anyone has worked out the averages for instance count , poly count and draw calls recently … would be interesting to know :wink:

3 Likes

I don’t think it’s even possible to calculate only one average, as @shaderbytes said, hardware also plays a big role on it - iOS in particular is a bit of a pain :sweat_smile: If possible, adapting the experience to the client’s capabilities leads to a better outcome - you could do this in a number of ways, including user agent strings and our built-in scene optimizer: The Scene Optimizer | Babylon.js Documentation (babylonjs.com).

And test test test - there’s nothing better than real hardware :slight_smile:

1 Like

Here are some recommendations - https://registry.khronos.org/3DCommerce/AssetCreation/specs/1.0/AssetCreationGuidelines.pdf

Best Practice for File Size
The file size is usually composed of geometry and textures. In the runtime asset scenario, usually the
textures tend to hold more percentage of the total file size. It’s desirable to have the asset file size as
small as possible, which helps in reducing download time and creating smoother guest experience.
Ultimately it’s a balancing act between maintaining small file size versus optimal visual quality.

With the advancement of hardware capability, more powerful platforms and faster transmission speed,
the definition of ideal file size changes over time. Across the industry, our observation is that the
standard range for runtime assets vary from 3 MB to 15 MB.

It is also recommended to use compressed textures to keep the texture size to optimum, for instance,
using JPG or compressed PNG. In the near future, the new GPU textures such as KTX2 will be part of the toolings to handle the texture part of asset consideration.

3 Likes