Seems like at least I have started an interesting discussion here!

Really, I only used PICKABLE and VISIBLE as  an example-probably not the best 
because pickability and visibility are logically somewhat entwined.

It would be better to see the mask as  a set of (32) independent logical flags. 
The problem with the simple test which is (paraphrased)

getTraversalMask() &  node.getNodeMask() !=0 

Is that the node is traversed if ANY of the matching bits in the traversalmask 
and the nodemask are both 'ON'. 

Essentially it allows use of only one bit at one time to manage traversal.

As suggested, perhaps instead of a comparison with 0, we could have a new 
member variable "traversalMaskResult" which is used for the comparison. 
Backward compatibility would be a bit tricky as we want a == with the 
traversalMaskResult. Need to do some bit-twiddling thinking!



Andrew

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=27662#27662





_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to