示例#1
0
static bool writeAnimations( osgDB::OutputStream& os, const osgAnimation::AnimationManagerBase& manager )
{
    const osgAnimation::AnimationList& animations = manager.getAnimationList();
    os.writeSize(animations.size()); os << osgDB::BEGIN_BRACKET << std::endl;
    for ( osgAnimation::AnimationList::const_iterator itr=animations.begin();
          itr!=animations.end(); ++itr )
    {
        os << itr->get();
    }
    os << osgDB::END_BRACKET << std::endl;
    return true;
}
示例#2
0
bool AnimationManagerBase_writeLocalData(const osgAnimation::AnimationManagerBase &manager, Output &fw)
{
    const osgAnimation::AnimationList &animList = manager.getAnimationList();

    fw.indent() << "num_animations " << animList.size() << std::endl;

    for (osgAnimation::AnimationList::const_iterator it = animList.begin(); it != animList.end(); ++it)
    {
        if (!fw.writeObject(**it))
            osg::notify(osg::WARN) << "Warning: can't write an animation object" << std::endl;
    }

    return true;
}
示例#3
0
static bool checkAnimations( const osgAnimation::AnimationManagerBase& manager )
{
    return manager.getAnimationList().size()>0;
}