• osg控制相机移动


    osg控制相机移动

    viewer->getCameraManipulator()->setHomePosition(_homeEye,_homeCenter,_homeUp);

    osg::Vec3d              _homeEye;
    osg::Vec3d              _homeCenter;
    osg::Vec3d              _homeUp;
    
    /** Manually set the home position, and set the automatic compute of home position. */
    virtual void setHomePosition(const osg::Vec3d& eye, const osg::Vec3d& center, const osg::Vec3d& up, bool autoComputeHomePosition=false)
    {
        setAutoComputeHomePosition(autoComputeHomePosition);
        _homeEye = eye;
        _homeCenter = center;
        _homeUp = up;
    }
    
    /** Get the manually set home position. */
    virtual void getHomePosition(osg::Vec3d& eye, osg::Vec3d& center, osg::Vec3d& up) const
    {
        eye = _homeEye;
        center = _homeCenter;
        up = _homeUp;
    }

    ##############################

    QQ 3087438119
  • 相关阅读:
    HTML简单的用户资料
    PhP CSS常用选择器
    PHPCSS样式表
    PHP第四日随笔
    一些记不住的东西
    错误记录
    关于空想X
    DSA 祖玛
    洛谷 P1194 买礼物
    Git笔记
  • 原文地址:https://www.cnblogs.com/herd/p/15345018.html
Copyright © 2020-2023  润新知