#1
|
|||
|
|||
Counting all objects in view
I was hoping that there may be a way to efficiently work out the total number of objects (sub-objects within a scene) that are in view.
The current way I would implement it (which I have not done yet) would be to use the viz.pick() command in order to return the object intersected with at every point on the screen. There would also have to be some logic in place to work out if the object returned has already been returned once and if not, add it to the counter of current visible objects in view. Does anybody have any more elegant solutions for how I could do this as my method seems a bit brute force like. |
#2
|
|||
|
|||
You could loop through a list of object names and use window.isCulled to find out which are in the view frustum. The command has a name argument to check the status of sub-children.
|
#3
|
|||
|
|||
This is much better than my method so thanks!
Just for clarification, I popped this post in this section as I am using the Vizard 5 Beta right now. Hope this was right. |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Trouble picking text3d objects | Salvar | Vizard | 4 | 12-01-2010 03:07 PM |
Semi-circle array containing target and distractor objects | ptjt255 | Vizard | 3 | 08-04-2009 03:09 AM |
View | nlfrnassimi | Vizard | 4 | 03-12-2009 05:25 AM |
problem with stereo mode | shivanangel | Vizard | 3 | 10-17-2006 09:58 AM |
Could not find plugin to load objects... | halley | Vizard | 1 | 05-30-2006 11:01 AM |