1、 osg矩阵变换节点
1.1 介绍
矩阵变换节点(osg::MatrixTransform)同样继承自 osg::Transform,其主要作用是负责场景中的矩阵变换、矩阵的运算及坐标系的变换。后面要讲的动画更新也是用 MatrixTransform 来设置移动和旋转。通过使用矩阵变换节点(osg::MatrixTransform)可以对场景中的模型进行旋转、平移等操作。
osg::MatrixTransform 的常用主要成员函数如下:
void setMatrix(const Matrix &mat) //设置矩阵
const Matrix & getMatrix() const //得到矩阵