Download

Online

Gallery

Blog

  Index  | Recent Threads  | List Attachments  | Search
 Welcome Guest  |  Register  |  Login
Login Name  Password
 

Sweet Home 3D Forum



No member browsing this thread
Thread Status: Active
Total posts in this thread: 3
[ Jump to Last Post ]
Post new Thread
Author
Previous Thread This topic has been viewed 296 times and has 2 replies Next Thread
Keet
Advanced Member
Member's Avatar

Netherlands
Joined: Apr 8, 2022
Post Count: 1005
Status: Offline
Reply to this Post  Reply with Quote 
Merging g lines size limits?

Emmanuel has told us that merging g groups with the same material into merged groups will increase the performance of handling a model because each g group is loaded as a separate object. Less g groups is less objects to load.

Is there a limit to the number of g groups that can be merged into a single group?

Example: I created stadium seating, a single seat has 4 groups after merging; the seat, 2 base parts, and the floor. When I build a stadium that means 10 to 50 thousand seats. I already created rows that are optimized, not only by merging groups but also by replacing the 2 base parts and floor with a single wider base and floor. The seating is intentionally created as a very simple object because of the anticipated number of seats in a project. But still, the numbers can be huge.

Merging many thousands of seats into a single set of 4 groups for a whole stadium will create a huge object to process.
Is it still better to merge or use a few blocks that are merged? For example merge into 1000 seat objects?
My guess is that at some point there could be a problem with array size limits and/or memory usage. But where is that point?
----------------------------------------
Dodecagon.nl
700+ 3D models, manuals, and projects
[Aug 7, 2024, 11:06:52 AM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Puybaret
Expert
Member's Avatar

France
Joined: Nov 7, 2005
Post Count: 9369
Status: Offline
Reply to this Post  Reply with Quote 
Re: Merging g lines size limits?

That point must depend on the RAM available on your computer and graphics card.
From my experience with WebGL which must work similarly to Java 3D / OpenGL, you load vertice, normals and texture coordinates buffers of each group in the graphics card, then request to draw the buffers with a transformation matrix which will place it at the spot.
Therefore, it's better to merge faces into a larger group. It will create a larger buffer in the graphics card and in the main RAM, but it will require less instructions to draw all the groups.
----------------------------------------
Emmanuel Puybaret, Sweet Home 3D developer
[Aug 7, 2024, 2:07:07 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
Keet
Advanced Member
Member's Avatar

Netherlands
Joined: Apr 8, 2022
Post Count: 1005
Status: Offline
Reply to this Post  Reply with Quote 
Re: Merging g lines size limits?

Thank you, that makes it clear.
I can experiment on my own computer and track how much memory is used. As long as it doesn't get too much I can merge anything I want. When it appears to get too much I can limit the amount to merge. This is mainly for the ExportToHTML plugin, getting the most efficient result for users to view in the browser. The most difficult will be determining what the minimum requirements are for each large project.
----------------------------------------
Dodecagon.nl
700+ 3D models, manuals, and projects
[Aug 7, 2024, 2:26:09 PM] Show Printable Version of Post    View Member Profile    Send Private Message [Link] Report threatening or abusive post: please login first  Go to top 
[ Jump to Last Post ]
Show Printable Version of Thread  Post new Thread

  Get Sweet Home 3D at SourceForge.net. Fast, secure and Free Open Source software downloads  
© Copyright 2024 Space Mushrooms - All rights reserved