WorldViz User Forum

WorldViz User Forum (https://forum.worldviz.com/index.php)
-   Vizard (https://forum.worldviz.com/forumdisplay.php?f=17)
-   -   Loading objects faster (https://forum.worldviz.com/showthread.php?t=3317)

kovitch 01-11-2011 08:39 AM

Loading objects faster
 
Hello,

I'm using the following code to load some objects:

Code:

for i in range(0,tables_number):
        tables.append(viz.add('src/obj/table.flt'))

However, it takes too long to load 50 tables (about 30 seconds).

Is there any trick to accomplish this task faster?

Regards.

Jeff 01-11-2011 11:12 AM

You could add the table once and then make copies or clones of it. Check out the section on Duplicating, Copying, and Cloning on the following page:

http://www.worldviz.com/vizhelp/Addi...your_world.htm

Veleno 01-11-2011 03:46 PM

Ideally, you should bring the object into 3ds Max, and re-export as an .IVE (OpenSceneGraph), Vizard's native format.

farshizzo 01-11-2011 04:40 PM

If your script does not require a unique instance for each table, then you can clone all the tables.
Code:

for i in range(tables_number):
        tables.append(viz.add('src/obj/table.flt',cache=viz.CACHE_CLONE))



All times are GMT -7. The time now is 04:11 PM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC