[osg-users] dynamic_cast equivalent in osgDotNet

Robert Osfield robert.osfield at gmail.com
Wed Oct 3 01:11:21 PDT 2007


On 10/3/07, Michael Wittman <wittman at acm.org> wrote:
> It's possible to add support to osgDotNet for upcasts along non-leftmost
> inheritance branches.  But downcasting in the same situation is a much
> harder problem, and I don't know of a good solution for it at the moment.

Perhaps we could add a GUIActionAdapter:asView() virtual function that
returns a osg::View pointer.

Another possibility would be to have a asViewer() and
asCompositeViewer() methods too, but we'd have to forward declare
osgViewer::Viewer and osgViewer::CompositeViewer to achieve this.  I'm
not sure what the consequences for  the wrappers would be with this
though.

Robert.



More information about the osg-users mailing list