[osg-users] Meta-data in core OSG - project started

Sukender suky0001 at free.fr
Fri Apr 15 08:10:37 PDT 2011


Hi Peter,

Thanks... but what for the addMeta<T>()?
I mean it's okay having a addMeta(string, ValueBase *), but this will force you to write
    o->addMeta( "myMeta", new Value<int>(5) );
instead of simply
    o->addMeta( "myMeta", 5 );
which could be nice. Any idea?

Sukender
PVLE - Lightweight cross-platform game engine - http://pvle.sourceforge.net/

----- "Peter Amstutz" <peter.amstutz at tseboston.com> a écrit :

> Put the dynamic_cast<T> inside the method.
> 
> On 4/15/2011 10:53 AM, Sukender wrote:
> > Hi Peter,
> >
> > Well observed. We'll add methods to iterate and a pointer to
> object.
> >
> > But we just spotted a flaw in our design: we wrote some virtual
> templated methods (which is impossible of course)... Any idea on how
> to return a "T*" in ComponentContainer::findFirstMeta()?
> >
> > Sukender
> -- 
> Peter Amstutz
> Senior Software Engineer
> Technology Solutions Experts
> Natick, MA
> 02131
> 
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org



More information about the osg-users mailing list