Added set and get methods for Matrixd and Matrixf.
This commit is contained in:
@@ -14,6 +14,8 @@
|
||||
#include <osg/Quat>
|
||||
#include <osg/Vec4>
|
||||
#include <osg/Vec3>
|
||||
#include <osg/Matrixf>
|
||||
#include <osg/Matrixd>
|
||||
|
||||
#include <math.h>
|
||||
|
||||
@@ -24,6 +26,27 @@
|
||||
using namespace osg;
|
||||
|
||||
|
||||
void Quat::set(const Matrixf& matrix)
|
||||
{
|
||||
matrix.get(*this);
|
||||
}
|
||||
|
||||
void Quat::set(const Matrixd& matrix)
|
||||
{
|
||||
matrix.get(*this);
|
||||
}
|
||||
|
||||
void Quat::get(Matrixf& matrix) const
|
||||
{
|
||||
matrix.set(*this);
|
||||
}
|
||||
|
||||
void Quat::get(Matrixd& matrix) const
|
||||
{
|
||||
matrix.set(*this);
|
||||
}
|
||||
|
||||
|
||||
/// Set the elements of the Quat to represent a rotation of angle
|
||||
/// (radians) around the axis (x,y,z)
|
||||
void Quat::makeRotate( float angle,
|
||||
|
||||
Reference in New Issue
Block a user