setTransform() complexity

Calls to setTransform() in TransformGroup currently cause recursive updates of all localToVworld and bounds data below in the node in the scene graph.

I am working on a skeletal animation package that updates up to 600 TransformGroups each frame. Many redundant localToVworld and bounds updates (O(n^2)) occur due to the extremely hierarchical nature of a skeleton.

I would like to defer localToVworld and bounds updating until after I have done all setTransform() operations. It would be nice if there was a flag or alternate setTransform call that would not perform localToVworld and bounds updates. A Node method that recursively updates the localToVworld and bounds data of all child nodes would also be helpful.

Any ideas?

Hi,

[quoting my own e-mail to share it with community]

I see a simplest way in adding something
like “defer transform updates” flag to TransformGroup (false by default, so
we are still compatible with old apps) and
add updateTransform() method that will enforce transform recalculation.

I will take a look on how to add this. Xith3D already has code to disable (not defer) updates of bounds, so adding this kind of functionality will go similar way.

Yuri

That would be great! When might this feature make it into the CVS?