Uniform
Go to the documentation of this file.
/* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
* Copyright (C) 2003-2005 3Dlabs Inc. Ltd.
* Copyright (C) 2008 Zebra Imaging
* Copyright (C) 2012 David Callu
*
* This application is open source and may be redistributed and/or modified
* freely and without restriction, both in commercial and non commercial
* applications, as long as this copyright notice is maintained.
*
* This application is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
*/
/* file: include/osg/Uniform
* author: Mike Weiblen 2008-01-02
*/
#ifndef OSG_UNIFORM
#define OSG_UNIFORM 1
#include <osg/ref_ptr>
#include <osg/Array>
#include <osg/Callback>
#include <osg/Vec2>
#include <osg/Vec3>
#include <osg/Vec4>
#include <osg/Vec2d>
#include <osg/Vec3d>
#include <osg/Vec4d>
#include <osg/Matrix>
#include <osg/GLExtensions>
#include <string.h> // for memset
#include <string>
#include <vector>
namespace osg {
// forward declare
class NodeVisitor;
// C++ classes to represent the GLSL-specific types.
//
// Warning :
// OSG is Row major
// GLSL is Column Major
//
// If you define an Uniform with type Uniform::FLOAT_MAT4X2 and so use a Matrix4x2 to setup your Uniform,
// like this :
// 1 2
// 3 4
// 5 6
// 7 8
//
// you will get in your shader a Column Major Matrix like this :
// 1 3 5 7
// 2 4 6 8
//
// In simple term, you matrix in OSG will be a transposed matrix in GLSL
//
//
// You can avoid this behaviours starting GLSL version 1.40 with uniform layout :
//
// <GLSL code>
// layout(row_major) uniform matrix4x2 myVariable;
// <GLSL code>
//
//
template <typename T, unsigned int RowN, unsigned int ColN>
class MatrixTemplate
{
public:
enum { col_count = ColN };
enum { row_count = RowN };
enum { value_count = ColN * RowN };
typedef T value_type;
public:
MatrixTemplate() {}
~MatrixTemplate() {}
value_type& operator()(int row, int col) { return _mat[row][col]; }
value_type operator()(int row, int col) const { return _mat[row][col]; }
MatrixTemplate& operator = (const MatrixTemplate& rhs)
{
if( &rhs == this ) return *this;
set(rhs.ptr());
return *this;
}
void set(const MatrixTemplate& rhs) { set(rhs.ptr()); }
void set(value_type const * const ptr)
{
value_type* local_ptr = (value_type*)_mat;
for(int i=0;i<value_count;++i) local_ptr[i]=ptr[i];
}
value_type* ptr() { return (value_type*)_mat; }
const value_type* ptr() const { return (const value_type*)_mat; }
value_type& operator [] (int i) {return ptr()[i];}
value_type operator [] (int i) const {return ptr()[i];}
void reset() { memset(_mat, 0, sizeof( value_type ) * value_count); }
protected:
value_type _mat[row_count][col_count];
};
template <typename T>
class Matrix2Template : public MatrixTemplate<T, 2, 2>
{
public:
typedef MatrixTemplate<T, 2, 2> base_class;
typedef typename base_class::value_type value_type;
public:
Matrix2Template() { makeIdentity(); }
Matrix2Template( const Matrix2Template& mat ) { set(mat.ptr()); }
Matrix2Template( value_type a00, value_type a01,
value_type a10, value_type a11 )
{
set( a00, a01,
a10, a11 );
}
~Matrix2Template() {}
using base_class::set;
void set(value_type a00, value_type a01,
value_type a10, value_type a11 )
{
base_class::_mat[0][0]=a00; base_class::_mat[0][1]=a01;
base_class::_mat[1][0]=a10; base_class::_mat[1][1]=a11;
}
void makeIdentity()
{
set( 1, 0,
0, 1 );
}
};
template <typename T>
class Matrix2x3Template : public MatrixTemplate<T, 2, 3>
{
public:
typedef MatrixTemplate<T, 2, 3> base_class;
typedef typename base_class::value_type value_type;
public:
Matrix2x3Template() { base_class::reset(); }
Matrix2x3Template( const Matrix2x3Template& mat ) { set(mat.ptr()); }
Matrix2x3Template( value_type a00, value_type a01, value_type a02,
value_type a10, value_type a11, value_type a12 )
{
set( a00, a01, a02,
a10, a11, a12 );
}
~Matrix2x3Template() {}
using base_class::set;
void set( value_type a00, value_type a01, value_type a02,
value_type a10, value_type a11, value_type a12 )
{
base_class::_mat[0][0]=a00; base_class::_mat[0][1]=a01; base_class::_mat[0][2]=a02;
base_class::_mat[1][0]=a10; base_class::_mat[1][1]=a11; base_class::_mat[1][2]=a12;
}
};
template <typename T>
class Matrix2x4Template : public MatrixTemplate<T, 2, 4>
{
public:
typedef MatrixTemplate<T, 2, 4> base_class;
typedef typename base_class::value_type value_type;
public:
Matrix2x4Template() { base_class::reset(); }
Matrix2x4Template( const Matrix2x4Template& mat ) { set(mat.ptr()); }
Matrix2x4Template( value_type a00, value_type a01, value_type a02, value_type a03,
value_type a10, value_type a11, value_type a12, value_type a13 )
{
set( a00, a01, a02, a03,
a10, a11, a12, a13 );
}
~Matrix2x4Template() {}
using base_class::set;
void set( value_type a00, value_type a01, value_type a02, value_type a03,
value_type a10, value_type a11, value_type a12, value_type a13 )
{
base_class::_mat[0][0]=a00; base_class::_mat[0][1]=a01; base_class::_mat[0][2]=a02; base_class::_mat[0][3]=a03;
base_class::_mat[1][0]=a10; base_class::_mat[1][1]=a11; base_class::_mat[1][2]=a12; base_class::_mat[1][3]=a13;
}
};
template <typename T>
class Matrix3x2Template : public MatrixTemplate<T, 3, 2>
{
public:
typedef MatrixTemplate<T, 3, 2> base_class;
typedef typename base_class::value_type value_type;
public:
Matrix3x2Template() { base_class::reset(); }
Matrix3x2Template( const Matrix3x2Template& mat ) { set(mat.ptr()); }
Matrix3x2Template( value_type a00, value_type a01,
value_type a10, value_type a11,
value_type a20, value_type a21 )
{
set( a00, a01,
a10, a11,
a20, a21 );
}
~Matrix3x2Template() {}
using base_class::set;
void set( value_type a00, value_type a01,
value_type a10, value_type a11,
value_type a20, value_type a21 )
{
base_class::_mat[0][0]=a00; base_class::_mat[0][1]=a01;
base_class::_mat[1][0]=a10; base_class::_mat[1][1]=a11;
base_class::_mat[2][0]=a20; base_class::_mat[2][1]=a21;
}
};
template <typename T>
class Matrix3Template : public MatrixTemplate<T, 3, 3>
{
public:
typedef MatrixTemplate<T, 3, 3> base_class;
typedef typename base_class::value_type value_type;
public:
Matrix3Template() { base_class::reset(); }
Matrix3Template( const Matrix3Template& mat ) { set(mat.ptr()); }
Matrix3Template( value_type a00, value_type a01, value_type a02,
value_type a10, value_type a11, value_type a12,
value_type a20, value_type a21, value_type a22 )
{
set( a00, a01, a02,
a10, a11, a12,
a20, a21, a22 );
}
~Matrix3Template() {}
using base_class::set;
void set( value_type a00, value_type a01, value_type a02,
value_type a10, value_type a11, value_type a12,
value_type a20, value_type a21, value_type a22 )
{
base_class::_mat[0][0]=a00; base_class::_mat[0][1]=a01; base_class::_mat[0][2]=a02;
base_class::_mat[1][0]=a10; base_class::_mat[1][1]=a11; base_class::_mat[1][2]=a12;
base_class::_mat[2][0]=a20; base_class::_mat[2][1]=a21; base_class::_mat[2][2]=a22;
}
void makeIdentity()
{
set( 1, 0, 0,
0, 1, 0,
0, 0, 1 );
}
};
template <typename T>
class Matrix3x4Template : public MatrixTemplate<T, 3, 4>
{
public:
typedef MatrixTemplate<T, 3, 4> base_class;
typedef typename base_class::value_type value_type;
public:
Matrix3x4Template() { base_class::reset(); }
Matrix3x4Template( const Matrix3x4Template& mat ) { set(mat.ptr()); }
Matrix3x4Template( value_type a00, value_type a01, value_type a02, value_type a03,
value_type a10, value_type a11, value_type a12, value_type a13,
value_type a20, value_type a21, value_type a22, value_type a23 )
{
set( a00, a01, a02, a03,
a10, a11, a12, a13,
a20, a21, a22, a23 );
}
~Matrix3x4Template() {}
using base_class::set;
void set( value_type a00, value_type a01, value_type a02, value_type a03,
value_type a10, value_type a11, value_type a12, value_type a13,
value_type a20, value_type a21, value_type a22, value_type a23 )
{
base_class::_mat[0][0]=a00; base_class::_mat[0][1]=a01; base_class::_mat[0][2]=a02; base_class::_mat[0][3]=a03;
base_class::_mat[1][0]=a10; base_class::_mat[1][1]=a11; base_class::_mat[1][2]=a12; base_class::_mat[1][3]=a13;
base_class::_mat[2][0]=a20; base_class::_mat[2][1]=a21; base_class::_mat[2][2]=a22; base_class::_mat[2][3]=a23;
}
};
template <typename T>
class Matrix4x2Template : public MatrixTemplate<T, 4, 2>
{
public:
typedef MatrixTemplate<T, 4, 2> base_class;
typedef typename base_class::value_type value_type;
public:
Matrix4x2Template() { base_class::reset(); }
Matrix4x2Template( const Matrix4x2Template& mat ) { set(mat.ptr()); }
Matrix4x2Template( value_type a00, value_type a01,
value_type a10, value_type a11,
value_type a20, value_type a21,
value_type a30, value_type a31 )
{
set( a00, a01,
a10, a11,
a20, a21,
a30, a31 );
}
~Matrix4x2Template() {}
using base_class::set;
void set( value_type a00, value_type a01,
value_type a10, value_type a11,
value_type a20, value_type a21,
value_type a30, value_type a31 )
{
base_class::_mat[0][0]=a00; base_class::_mat[0][1]=a01;
base_class::_mat[1][0]=a10; base_class::_mat[1][1]=a11;
base_class::_mat[2][0]=a20; base_class::_mat[2][1]=a21;
base_class::_mat[3][0]=a30; base_class::_mat[3][1]=a31;
}
};
template <typename T>
class Matrix4x3Template : public MatrixTemplate<T, 4, 3>
{
public:
typedef MatrixTemplate<T, 4, 3> base_class;
typedef typename base_class::value_type value_type;
public:
Matrix4x3Template() { base_class::reset(); }
Matrix4x3Template( const Matrix4x3Template& mat ) { set(mat.ptr()); }
Matrix4x3Template( value_type a00, value_type a01, value_type a02,
value_type a10, value_type a11, value_type a12,
value_type a20, value_type a21, value_type a22,
value_type a30, value_type a31, value_type a32 )
{
set( a00, a01, a02,
a10, a11, a12,
a20, a21, a22,
a30, a31, a32 );
}
~Matrix4x3Template() {}
using base_class::set;
void set( value_type a00, value_type a01, value_type a02,
value_type a10, value_type a11, value_type a12,
value_type a20, value_type a21, value_type a22,
value_type a30, value_type a31, value_type a32 )
{
base_class::_mat[0][0]=a00; base_class::_mat[0][1]=a01; base_class::_mat[0][2]=a02;
base_class::_mat[1][0]=a10; base_class::_mat[1][1]=a11; base_class::_mat[1][2]=a12;
base_class::_mat[2][0]=a20; base_class::_mat[2][1]=a21; base_class::_mat[2][2]=a22;
base_class::_mat[3][0]=a30; base_class::_mat[3][1]=a31; base_class::_mat[3][2]=a32;
}
};
typedef Matrix2Template<float> Matrix2;
typedef Matrix2x3Template<float> Matrix2x3;
typedef Matrix2x4Template<float> Matrix2x4;
typedef Matrix3x2Template<float> Matrix3x2;
typedef Matrix3Template<float> Matrix3;
typedef Matrix3x4Template<float> Matrix3x4;
typedef Matrix4x2Template<float> Matrix4x2;
typedef Matrix4x3Template<float> Matrix4x3;
typedef Matrix2Template<double> Matrix2d;
typedef Matrix2x3Template<double> Matrix2x3d;
typedef Matrix2x4Template<double> Matrix2x4d;
typedef Matrix3x2Template<double> Matrix3x2d;
typedef Matrix3Template<double> Matrix3d;
typedef Matrix3x4Template<double> Matrix3x4d;
typedef Matrix4x2Template<double> Matrix4x2d;
typedef Matrix4x3Template<double> Matrix4x3d;
class OSG_EXPORT Uniform : public Object
{
public:
enum Type {
FLOAT = GL_FLOAT,
FLOAT_VEC2 = GL_FLOAT_VEC2,
FLOAT_VEC3 = GL_FLOAT_VEC3,
FLOAT_VEC4 = GL_FLOAT_VEC4,
DOUBLE = GL_DOUBLE,
DOUBLE_VEC2 = GL_DOUBLE_VEC2,
DOUBLE_VEC3 = GL_DOUBLE_VEC3,
DOUBLE_VEC4 = GL_DOUBLE_VEC4,
INT = GL_INT,
INT_VEC2 = GL_INT_VEC2,
INT_VEC3 = GL_INT_VEC3,
INT_VEC4 = GL_INT_VEC4,
UNSIGNED_INT = GL_UNSIGNED_INT,
UNSIGNED_INT_VEC2 = GL_UNSIGNED_INT_VEC2_EXT,
UNSIGNED_INT_VEC3 = GL_UNSIGNED_INT_VEC3_EXT,
UNSIGNED_INT_VEC4 = GL_UNSIGNED_INT_VEC4_EXT,
BOOL = GL_BOOL,
BOOL_VEC2 = GL_BOOL_VEC2,
BOOL_VEC3 = GL_BOOL_VEC3,
BOOL_VEC4 = GL_BOOL_VEC4,
INT64 = GL_INT64_ARB,
UNSIGNED_INT64 = GL_UNSIGNED_INT64_ARB,
FLOAT_MAT2 = GL_FLOAT_MAT2,
FLOAT_MAT3 = GL_FLOAT_MAT3,
FLOAT_MAT4 = GL_FLOAT_MAT4,
FLOAT_MAT2x3 = GL_FLOAT_MAT2x3,
FLOAT_MAT2x4 = GL_FLOAT_MAT2x4,
FLOAT_MAT3x2 = GL_FLOAT_MAT3x2,
FLOAT_MAT3x4 = GL_FLOAT_MAT3x4,
FLOAT_MAT4x2 = GL_FLOAT_MAT4x2,
FLOAT_MAT4x3 = GL_FLOAT_MAT4x3,
DOUBLE_MAT2 = GL_DOUBLE_MAT2,
DOUBLE_MAT3 = GL_DOUBLE_MAT3,
DOUBLE_MAT4 = GL_DOUBLE_MAT4,
DOUBLE_MAT2x3 = GL_DOUBLE_MAT2x3,
DOUBLE_MAT2x4 = GL_DOUBLE_MAT2x4,
DOUBLE_MAT3x2 = GL_DOUBLE_MAT3x2,
DOUBLE_MAT3x4 = GL_DOUBLE_MAT3x4,
DOUBLE_MAT4x2 = GL_DOUBLE_MAT4x2,
DOUBLE_MAT4x3 = GL_DOUBLE_MAT4x3,
SAMPLER_1D = GL_SAMPLER_1D,
SAMPLER_2D = GL_SAMPLER_2D,
SAMPLER_3D = GL_SAMPLER_3D,
SAMPLER_CUBE = GL_SAMPLER_CUBE,
SAMPLER_1D_SHADOW = GL_SAMPLER_1D_SHADOW,
SAMPLER_2D_SHADOW = GL_SAMPLER_2D_SHADOW,
SAMPLER_1D_ARRAY = GL_SAMPLER_1D_ARRAY_EXT,
SAMPLER_2D_ARRAY = GL_SAMPLER_2D_ARRAY_EXT,
SAMPLER_CUBE_MAP_ARRAY = GL_SAMPLER_CUBE_MAP_ARRAY,
SAMPLER_1D_ARRAY_SHADOW = GL_SAMPLER_1D_ARRAY_SHADOW_EXT,
SAMPLER_2D_ARRAY_SHADOW = GL_SAMPLER_2D_ARRAY_SHADOW_EXT,
SAMPLER_2D_MULTISAMPLE = GL_SAMPLER_2D_MULTISAMPLE,
SAMPLER_2D_MULTISAMPLE_ARRAY = GL_SAMPLER_2D_MULTISAMPLE_ARRAY,
SAMPLER_CUBE_SHADOW = GL_SAMPLER_CUBE_SHADOW_EXT,
SAMPLER_CUBE_MAP_ARRAY_SHADOW = GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW,
SAMPLER_BUFFER = GL_SAMPLER_BUFFER_EXT,
SAMPLER_2D_RECT = GL_SAMPLER_2D_RECT,
SAMPLER_2D_RECT_SHADOW = GL_SAMPLER_2D_RECT_SHADOW,
INT_SAMPLER_1D = GL_INT_SAMPLER_1D_EXT,
INT_SAMPLER_2D = GL_INT_SAMPLER_2D_EXT,
INT_SAMPLER_3D = GL_INT_SAMPLER_3D_EXT,
INT_SAMPLER_CUBE = GL_INT_SAMPLER_CUBE_EXT,
INT_SAMPLER_1D_ARRAY = GL_INT_SAMPLER_1D_ARRAY_EXT,
INT_SAMPLER_2D_ARRAY = GL_INT_SAMPLER_2D_ARRAY_EXT,
INT_SAMPLER_CUBE_MAP_ARRAY = GL_INT_SAMPLER_CUBE_MAP_ARRAY,
INT_SAMPLER_2D_MULTISAMPLE = GL_INT_SAMPLER_2D_MULTISAMPLE,
INT_SAMPLER_2D_MULTISAMPLE_ARRAY = GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY,
INT_SAMPLER_BUFFER = GL_INT_SAMPLER_BUFFER_EXT,
INT_SAMPLER_2D_RECT = GL_INT_SAMPLER_2D_RECT_EXT,
UNSIGNED_INT_SAMPLER_1D = GL_UNSIGNED_INT_SAMPLER_1D_EXT,
UNSIGNED_INT_SAMPLER_2D = GL_UNSIGNED_INT_SAMPLER_2D_EXT,
UNSIGNED_INT_SAMPLER_3D = GL_UNSIGNED_INT_SAMPLER_3D_EXT,
UNSIGNED_INT_SAMPLER_CUBE = GL_UNSIGNED_INT_SAMPLER_CUBE_EXT,
UNSIGNED_INT_SAMPLER_1D_ARRAY = GL_UNSIGNED_INT_SAMPLER_1D_ARRAY_EXT,
UNSIGNED_INT_SAMPLER_2D_ARRAY = GL_UNSIGNED_INT_SAMPLER_2D_ARRAY_EXT,
UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY = GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY,
UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE,
UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY,
UNSIGNED_INT_SAMPLER_BUFFER = GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT,
UNSIGNED_INT_SAMPLER_2D_RECT = GL_UNSIGNED_INT_SAMPLER_2D_RECT_EXT,
IMAGE_1D = GL_IMAGE_1D,
IMAGE_2D = GL_IMAGE_2D,
IMAGE_3D = GL_IMAGE_3D,
IMAGE_2D_RECT = GL_IMAGE_2D_RECT,
IMAGE_CUBE = GL_IMAGE_CUBE,
IMAGE_BUFFER = GL_IMAGE_BUFFER,
IMAGE_1D_ARRAY = GL_IMAGE_1D_ARRAY,
IMAGE_2D_ARRAY = GL_IMAGE_2D_ARRAY,
IMAGE_CUBE_MAP_ARRAY = GL_IMAGE_CUBE_MAP_ARRAY,
IMAGE_2D_MULTISAMPLE = GL_IMAGE_2D_MULTISAMPLE,
IMAGE_2D_MULTISAMPLE_ARRAY = GL_IMAGE_2D_MULTISAMPLE_ARRAY,
INT_IMAGE_1D = GL_INT_IMAGE_1D,
INT_IMAGE_2D = GL_INT_IMAGE_2D,
INT_IMAGE_3D = GL_INT_IMAGE_3D,
INT_IMAGE_2D_RECT = GL_INT_IMAGE_2D_RECT,
INT_IMAGE_CUBE = GL_INT_IMAGE_CUBE,
INT_IMAGE_BUFFER = GL_INT_IMAGE_BUFFER,
INT_IMAGE_1D_ARRAY = GL_INT_IMAGE_1D_ARRAY,
INT_IMAGE_2D_ARRAY = GL_INT_IMAGE_2D_ARRAY,
INT_IMAGE_CUBE_MAP_ARRAY = GL_INT_IMAGE_CUBE_MAP_ARRAY,
INT_IMAGE_2D_MULTISAMPLE = GL_INT_IMAGE_2D_MULTISAMPLE,
INT_IMAGE_2D_MULTISAMPLE_ARRAY = GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY,
UNSIGNED_INT_IMAGE_1D = GL_UNSIGNED_INT_IMAGE_1D,
UNSIGNED_INT_IMAGE_2D = GL_UNSIGNED_INT_IMAGE_2D,
UNSIGNED_INT_IMAGE_3D = GL_UNSIGNED_INT_IMAGE_3D,
UNSIGNED_INT_IMAGE_2D_RECT = GL_UNSIGNED_INT_IMAGE_2D_RECT,
UNSIGNED_INT_IMAGE_CUBE = GL_UNSIGNED_INT_IMAGE_CUBE,
UNSIGNED_INT_IMAGE_BUFFER = GL_UNSIGNED_INT_IMAGE_BUFFER,
UNSIGNED_INT_IMAGE_1D_ARRAY = GL_UNSIGNED_INT_IMAGE_1D_ARRAY,
UNSIGNED_INT_IMAGE_2D_ARRAY = GL_UNSIGNED_INT_IMAGE_2D_ARRAY,
UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY = GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY,
UNSIGNED_INT_IMAGE_2D_MULTISAMPLE = GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE,
UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY = GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY,
UNDEFINED = 0x0
};
public:
Uniform();
Uniform( Type type, const std::string& name, int numElements=1 );
Uniform(const Uniform& rhs, const CopyOp& copyop=CopyOp::SHALLOW_COPY);
META_Object(osg, Uniform);
virtual Uniform* asUniform() { return this; }
virtual const Uniform* asUniform() const { return this; }
bool setType( Type t );
Type getType() const { return _type; }
virtual void setName( const std::string& name );
void setNumElements( unsigned int numElements );
unsigned int getNumElements() const { return _numElements; }
unsigned int getInternalArrayNumElements() const;
static const char* getTypename( Type t );
static int getTypeNumComponents( Type t );
static Uniform::Type getTypeId( const std::string& tname );
static Type getGlApiType( Type t );
static GLenum getInternalArrayType( Type t );
static unsigned int getNameID(const std::string& name);
explicit Uniform( const char* name, float f );
explicit Uniform( const char* name, double d );
explicit Uniform( const char* name, int i );
explicit Uniform( const char* name, unsigned int ui );
explicit Uniform( const char* name, bool b );
explicit Uniform( const char* name, unsigned long long ull);
explicit Uniform( const char* name, long long ll );
Uniform( const char* name, const osg::Vec2& v2 );
Uniform( const char* name, const osg::Vec3& v3 );
Uniform( const char* name, const osg::Vec4& v4 );
Uniform( const char* name, const osg::Vec2d& v2 );
Uniform( const char* name, const osg::Vec3d& v3 );
Uniform( const char* name, const osg::Vec4d& v4 );
Uniform( const char* name, const osg::Matrix2& m2 );
Uniform( const char* name, const osg::Matrix3& m3 );
Uniform( const char* name, const osg::Matrixf& m4 );
Uniform( const char* name, const osg::Matrix2x3& m2x3 );
Uniform( const char* name, const osg::Matrix2x4& m2x4 );
Uniform( const char* name, const osg::Matrix3x2& m3x2 );
Uniform( const char* name, const osg::Matrix3x4& m3x4 );
Uniform( const char* name, const osg::Matrix4x2& m4x2 );
Uniform( const char* name, const osg::Matrix4x3& m4x3 );
Uniform( const char* name, const osg::Matrix2d& m2 );
Uniform( const char* name, const osg::Matrix3d& m3 );
Uniform( const char* name, const osg::Matrixd& m4 );
Uniform( const char* name, const osg::Matrix2x3d& m2x3 );
Uniform( const char* name, const osg::Matrix2x4d& m2x4 );
Uniform( const char* name, const osg::Matrix3x2d& m3x2 );
Uniform( const char* name, const osg::Matrix3x4d& m3x4 );
Uniform( const char* name, const osg::Matrix4x2d& m4x2 );
Uniform( const char* name, const osg::Matrix4x3d& m4x3 );
Uniform( const char* name, int i0, int i1 );
Uniform( const char* name, int i0, int i1, int i2 );
Uniform( const char* name, int i0, int i1, int i2, int i3 );
Uniform( const char* name, unsigned int ui0, unsigned int ui1 );
Uniform( const char* name, unsigned int ui0, unsigned int ui1, unsigned int ui2 );
Uniform( const char* name, unsigned int ui0, unsigned int ui1, unsigned int ui2, unsigned int ui3 );
Uniform( const char* name, bool b0, bool b1 );
Uniform( const char* name, bool b0, bool b1, bool b2 );
Uniform( const char* name, bool b0, bool b1, bool b2, bool b3 );
virtual int compare(const Uniform& rhs) const;
virtual int compareData(const Uniform& rhs) const;
bool operator < (const Uniform& rhs) const { return compare(rhs)<0; }
bool operator == (const Uniform& rhs) const { return compare(rhs)==0; }
bool operator != (const Uniform& rhs) const { return compare(rhs)!=0; }
void copyData( const Uniform& rhs );
typedef std::vector<StateSet*> ParentList;
inline const ParentList& getParents() const { return _parents; }
inline ParentList getParents() { return _parents; }
inline StateSet* getParent(unsigned int i) { return _parents[i]; }
inline const StateSet* getParent(unsigned int i) const { return _parents[i]; }
inline unsigned int getNumParents() const { return static_cast<unsigned int>(_parents.size()); }
bool set( float f );
bool set( double d );
bool set( int i );
bool set( unsigned int ui );
bool set( bool b );
bool set( unsigned long long ull );
bool set( long long ll );
bool set( const osg::Vec2& v2 );
bool set( const osg::Vec3& v3 );
bool set( const osg::Vec4& v4 );
bool set( const osg::Vec2d& v2 );
bool set( const osg::Vec3d& v3 );
bool set( const osg::Vec4d& v4 );
bool set( const osg::Matrix2& m2 );
bool set( const osg::Matrix3& m3 );
bool set( const osg::Matrixf& m4 );
bool set( const osg::Matrix2x3& m2x3 );
bool set( const osg::Matrix2x4& m2x4 );
bool set( const osg::Matrix3x2& m3x2 );
bool set( const osg::Matrix3x4& m3x4 );
bool set( const osg::Matrix4x2& m4x2 );
bool set( const osg::Matrix4x3& m4x3 );
bool set( const osg::Matrix2d& m2 );
bool set( const osg::Matrix3d& m3 );
bool set( const osg::Matrixd& m4 );
bool set( const osg::Matrix2x3d& m2x3 );
bool set( const osg::Matrix2x4d& m2x4 );
bool set( const osg::Matrix3x2d& m3x2 );
bool set( const osg::Matrix3x4d& m3x4 );
bool set( const osg::Matrix4x2d& m4x2 );
bool set( const osg::Matrix4x3d& m4x3 );
bool set( int i0, int i1 );
bool set( int i0, int i1, int i2 );
bool set( int i0, int i1, int i2, int i3 );
bool set( unsigned int ui0, unsigned int ui1 );
bool set( unsigned int ui0, unsigned int ui1, unsigned int ui2 );
bool set( unsigned int ui0, unsigned int ui1, unsigned int ui2, unsigned int ui3 );
bool set( bool b0, bool b1 );
bool set( bool b0, bool b1, bool b2 );
bool set( bool b0, bool b1, bool b2, bool b3 );
bool get( float& f ) const;
bool get( double& d ) const;
bool get( int& i ) const;
bool get( unsigned int& ui ) const;
bool get( bool& b ) const;
bool get( unsigned long long & ull ) const;
bool get( long long& ll ) const;
bool get( osg::Vec2& v2 ) const;
bool get( osg::Vec3& v3 ) const;
bool get( osg::Vec4& v4 ) const;
bool get( osg::Vec2d& v2 ) const;
bool get( osg::Vec3d& v3 ) const;
bool get( osg::Vec4d& v4 ) const;
bool get( osg::Matrix2& m2 ) const;
bool get( osg::Matrix3& m3 ) const;
bool get( osg::Matrixf& m4 ) const;
bool get( osg::Matrix2x3& m2x3 ) const;
bool get( osg::Matrix2x4& m2x4 ) const;
bool get( osg::Matrix3x2& m3x2 ) const;
bool get( osg::Matrix3x4& m3x4 ) const;
bool get( osg::Matrix4x2& m4x2 ) const;
bool get( osg::Matrix4x3& m4x3 ) const;
bool get( osg::Matrix2d& m2 ) const;
bool get( osg::Matrix3d& m3 ) const;
bool get( osg::Matrixd& m4 ) const;
bool get( osg::Matrix2x3d& m2x3 ) const;
bool get( osg::Matrix2x4d& m2x4 ) const;
bool get( osg::Matrix3x2d& m3x2 ) const;
bool get( osg::Matrix3x4d& m3x4 ) const;
bool get( osg::Matrix4x2d& m4x2 ) const;
bool get( osg::Matrix4x3d& m4x3 ) const;
bool get( int& i0, int& i1 ) const;
bool get( int& i0, int& i1, int& i2 ) const;
bool get( int& i0, int& i1, int& i2, int& i3 ) const;
bool get( unsigned int& ui0, unsigned int& ui1 ) const;
bool get( unsigned int& ui0, unsigned int& ui1, unsigned int& ui2 ) const;
bool get( unsigned int& ui0, unsigned int& ui1, unsigned int& ui2, unsigned int& ui3 ) const;
bool get( bool& b0, bool& b1 ) const;
bool get( bool& b0, bool& b1, bool& b2 ) const;
bool get( bool& b0, bool& b1, bool& b2, bool& b3 ) const;
bool setElement( unsigned int index, float f );
bool setElement( unsigned int index, double d );
bool setElement( unsigned int index, int i );
bool setElement( unsigned int index, unsigned int ui );
bool setElement( unsigned int index, bool b );
bool setElement( unsigned int index, unsigned long long ull );
bool setElement( unsigned int index, long long ll );
bool setElement( unsigned int index, const osg::Vec2& v2 );
bool setElement( unsigned int index, const osg::Vec3& v3 );
bool setElement( unsigned int index, const osg::Vec4& v4 );
bool setElement( unsigned int index, const osg::Vec2d& v2 );
bool setElement( unsigned int index, const osg::Vec3d& v3 );
bool setElement( unsigned int index, const osg::Vec4d& v4 );
bool setElement( unsigned int index, const osg::Matrix2& m2 );
bool setElement( unsigned int index, const osg::Matrix3& m3 );
bool setElement( unsigned int index, const osg::Matrixf& m4 );
bool setElement( unsigned int index, const osg::Matrix2x3& m2x3 );
bool setElement( unsigned int index, const osg::Matrix2x4& m2x4 );
bool setElement( unsigned int index, const osg::Matrix3x2& m3x2 );
bool setElement( unsigned int index, const osg::Matrix3x4& m3x4 );
bool setElement( unsigned int index, const osg::Matrix4x2& m4x2 );
bool setElement( unsigned int index, const osg::Matrix4x3& m4x3 );
bool setElement( unsigned int index, const osg::Matrix2d& m2 );
bool setElement( unsigned int index, const osg::Matrix3d& m3 );
bool setElement( unsigned int index, const osg::Matrixd& m4 );
bool setElement( unsigned int index, const osg::Matrix2x3d& m2x3 );
bool setElement( unsigned int index, const osg::Matrix2x4d& m2x4 );
bool setElement( unsigned int index, const osg::Matrix3x2d& m3x2 );
bool setElement( unsigned int index, const osg::Matrix3x4d& m3x4 );
bool setElement( unsigned int index, const osg::Matrix4x2d& m4x2 );
bool setElement( unsigned int index, const osg::Matrix4x3d& m4x3 );
bool setElement( unsigned int index, int i0, int i1 );
bool setElement( unsigned int index, int i0, int i1, int i2 );
bool setElement( unsigned int index, int i0, int i1, int i2, int i3 );
bool setElement( unsigned int index, unsigned int ui0, unsigned int ui1 );
bool setElement( unsigned int index, unsigned int ui0, unsigned int ui1, unsigned int ui2 );
bool setElement( unsigned int index, unsigned int ui0, unsigned int ui1, unsigned int ui2, unsigned int ui3 );
bool setElement( unsigned int index, bool b0, bool b1 );
bool setElement( unsigned int index, bool b0, bool b1, bool b2 );
bool setElement( unsigned int index, bool b0, bool b1, bool b2, bool b3 );
bool getElement( unsigned int index, float& f ) const;
bool getElement( unsigned int index, double& d ) const;
bool getElement( unsigned int index, int& i ) const;
bool getElement( unsigned int index, unsigned int& ui ) const;
bool getElement( unsigned int index, bool& b ) const;
bool getElement( unsigned int index, unsigned long long & ull ) const;
bool getElement( unsigned int index, long long& ll ) const;
bool getElement( unsigned int index, osg::Vec2& v2 ) const;
bool getElement( unsigned int index, osg::Vec3& v3 ) const;
bool getElement( unsigned int index, osg::Vec4& v4 ) const;
bool getElement( unsigned int index, osg::Vec2d& v2 ) const;
bool getElement( unsigned int index, osg::Vec3d& v3 ) const;
bool getElement( unsigned int index, osg::Vec4d& v4 ) const;
bool getElement( unsigned int index, osg::Matrix2& m2 ) const;
bool getElement( unsigned int index, osg::Matrix3& m3 ) const;
bool getElement( unsigned int index, osg::Matrixf& m4 ) const;
bool getElement( unsigned int index, osg::Matrix2x3& m2x3 ) const;
bool getElement( unsigned int index, osg::Matrix2x4& m2x4 ) const;
bool getElement( unsigned int index, osg::Matrix3x2& m3x2 ) const;
bool getElement( unsigned int index, osg::Matrix3x4& m3x4 ) const;
bool getElement( unsigned int index, osg::Matrix4x2& m4x2 ) const;
bool getElement( unsigned int index, osg::Matrix4x3& m4x3 ) const;
bool getElement( unsigned int index, osg::Matrix2d& m2 ) const;
bool getElement( unsigned int index, osg::Matrix3d& m3 ) const;
bool getElement( unsigned int index, osg::Matrixd& m4 ) const;
bool getElement( unsigned int index, osg::Matrix2x3d& m2x3 ) const;
bool getElement( unsigned int index, osg::Matrix2x4d& m2x4 ) const;
bool getElement( unsigned int index, osg::Matrix3x2d& m3x2 ) const;
bool getElement( unsigned int index, osg::Matrix3x4d& m3x4 ) const;
bool getElement( unsigned int index, osg::Matrix4x2d& m4x2 ) const;
bool getElement( unsigned int index, osg::Matrix4x3d& m4x3 ) const;
bool getElement( unsigned int index, int& i0, int& i1 ) const;
bool getElement( unsigned int index, int& i0, int& i1, int& i2 ) const;
bool getElement( unsigned int index, int& i0, int& i1, int& i2, int& i3 ) const;
bool getElement( unsigned int index, unsigned int& ui0, unsigned int& ui1 ) const;
bool getElement( unsigned int index, unsigned int& ui0, unsigned int& ui1, unsigned int& ui2 ) const;
bool getElement( unsigned int index, unsigned int& ui0, unsigned int& ui1, unsigned int& ui2, unsigned int& ui3 ) const;
bool getElement( unsigned int index, bool& b0, bool& b1 ) const;
bool getElement( unsigned int index, bool& b0, bool& b1, bool& b2 ) const;
bool getElement( unsigned int index, bool& b0, bool& b1, bool& b2, bool& b3 ) const;
typedef UniformCallback Callback;
void setUpdateCallback(UniformCallback* uc);
UniformCallback* getUpdateCallback() { return _updateCallback.get(); }
const UniformCallback* getUpdateCallback() const { return _updateCallback.get(); }
void setEventCallback(UniformCallback* ec);
UniformCallback* getEventCallback() { return _eventCallback.get(); }
const UniformCallback* getEventCallback() const { return _eventCallback.get(); }
inline void dirty() { ++_modifiedCount; }
bool setArray( FloatArray* array );
bool setArray( DoubleArray* array );
bool setArray( IntArray* array );
bool setArray( UIntArray* array );
bool setArray( UInt64Array* array );
bool setArray( Int64Array* array );
FloatArray* getFloatArray() { return _floatArray.get(); }
const FloatArray* getFloatArray() const { return _floatArray.get(); }
DoubleArray* getDoubleArray() { return _doubleArray.get(); }
const DoubleArray* getDoubleArray() const { return _doubleArray.get(); }
IntArray* getIntArray() { return _intArray.get(); }
const IntArray* getIntArray() const { return _intArray.get(); }
UIntArray* getUIntArray() { return _uintArray.get(); }
const UIntArray* getUIntArray() const { return _uintArray.get(); }
UInt64Array* getUInt64Array() { return _uint64Array.get(); }
const UInt64Array* getUInt64Array() const { return _uint64Array.get(); }
Int64Array* getInt64Array() { return _int64Array.get(); }
const Int64Array* getInt64Array() const { return _int64Array.get(); }
inline void setModifiedCount(unsigned int mc) { _modifiedCount = mc; }
inline unsigned int getModifiedCount() const { return _modifiedCount; }
unsigned int getNameID() const;
void apply(const GLExtensions* ext, GLint location) const;
protected:
virtual ~Uniform();
Uniform& operator=(const Uniform&) { return *this; }
bool isCompatibleType( Type t ) const;
// for backward compatibility only
// see getElement(index, osg::Matrixd &)
// see setElement(index, osg::Matrixd &)
bool isCompatibleType( Type t1, Type t2 ) const;
bool isScalar() const { return _numElements==1; }
void allocateDataArray();
void addParent(osg::StateSet* object);
void removeParent(osg::StateSet* object);
ParentList _parents;
friend class osg::StateSet;
Type _type;
unsigned int _numElements;
unsigned int _nameID;
// The internal data for osg::Uniforms are stored as an array of
// getInternalArrayType() of length getInternalArrayNumElements().
ref_ptr<FloatArray> _floatArray;
ref_ptr<DoubleArray> _doubleArray;
ref_ptr<IntArray> _intArray;
ref_ptr<UIntArray> _uintArray;
ref_ptr<Int64Array> _int64Array;
ref_ptr<UInt64Array> _uint64Array;
ref_ptr<UniformCallback> _updateCallback;
ref_ptr<UniformCallback> _eventCallback;
unsigned int _modifiedCount;
};
}
#endif
Array
Callback
GL_DOUBLE_MAT2x3
#define GL_DOUBLE_MAT2x3
Definition GLDefines:339
GL_IMAGE_2D_RECT
#define GL_IMAGE_2D_RECT
Definition GLDefines:362
GL_INT_VEC3
#define GL_INT_VEC3
Definition GLDefines:104
GL_FLOAT_MAT3x4
#define GL_FLOAT_MAT3x4
Definition GLDefines:160
GL_DOUBLE_MAT4x2
#define GL_DOUBLE_MAT4x2
Definition GLDefines:343
GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY
#define GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY
Definition GLDefines:380
GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY
#define GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY
Definition GLDefines:391
GL_UNSIGNED_INT_IMAGE_1D_ARRAY
#define GL_UNSIGNED_INT_IMAGE_1D_ARRAY
Definition GLDefines:387
GL_BOOL_VEC3
#define GL_BOOL_VEC3
Definition GLDefines:108
GL_SAMPLER_2D_ARRAY_SHADOW_EXT
#define GL_SAMPLER_2D_ARRAY_SHADOW_EXT
Definition GLDefines:41
GL_UNSIGNED_INT_IMAGE_CUBE
#define GL_UNSIGNED_INT_IMAGE_CUBE
Definition GLDefines:385
GL_INT_SAMPLER_CUBE_MAP_ARRAY
#define GL_INT_SAMPLER_CUBE_MAP_ARRAY
Definition GLDefines:436
GL_INT_IMAGE_2D_ARRAY
#define GL_INT_IMAGE_2D_ARRAY
Definition GLDefines:377
GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY
#define GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY
Definition GLDefines:389
GL_SAMPLER_2D
#define GL_SAMPLER_2D
Definition GLDefines:134
GL_INT_IMAGE_2D_MULTISAMPLE
#define GL_INT_IMAGE_2D_MULTISAMPLE
Definition GLDefines:379
GL_BOOL_VEC4
#define GL_BOOL_VEC4
Definition GLDefines:109
GL_INT_SAMPLER_2D_MULTISAMPLE
#define GL_INT_SAMPLER_2D_MULTISAMPLE
Definition GLDefines:350
GL_DOUBLE_VEC3
#define GL_DOUBLE_VEC3
Definition GLDefines:334
GL_SAMPLER_CUBE_MAP_ARRAY
#define GL_SAMPLER_CUBE_MAP_ARRAY
Definition GLDefines:434
GL_DOUBLE_MAT2x4
#define GL_DOUBLE_MAT2x4
Definition GLDefines:340
GL_UNSIGNED_INT_IMAGE_BUFFER
#define GL_UNSIGNED_INT_IMAGE_BUFFER
Definition GLDefines:386
GL_UNSIGNED_INT_SAMPLER_3D_EXT
#define GL_UNSIGNED_INT_SAMPLER_3D_EXT
Definition GLDefines:276
GL_IMAGE_CUBE
#define GL_IMAGE_CUBE
Definition GLDefines:363
GL_IMAGE_1D_ARRAY
#define GL_IMAGE_1D_ARRAY
Definition GLDefines:365
GL_SAMPLER_1D
#define GL_SAMPLER_1D
Definition GLDefines:139
GL_INT_VEC2
#define GL_INT_VEC2
Definition GLDefines:103
GL_UNSIGNED_INT_VEC4_EXT
#define GL_UNSIGNED_INT_VEC4_EXT
Definition GLDefines:265
GL_IMAGE_2D_ARRAY
#define GL_IMAGE_2D_ARRAY
Definition GLDefines:366
GL_FLOAT_MAT2x3
#define GL_FLOAT_MAT2x3
Definition GLDefines:157
GL_IMAGE_2D_MULTISAMPLE
#define GL_IMAGE_2D_MULTISAMPLE
Definition GLDefines:368
GL_DOUBLE_VEC4
#define GL_DOUBLE_VEC4
Definition GLDefines:335
GL_UNSIGNED_INT_IMAGE_1D
#define GL_UNSIGNED_INT_IMAGE_1D
Definition GLDefines:381
GL_UNSIGNED_INT_SAMPLER_2D_RECT_EXT
#define GL_UNSIGNED_INT_SAMPLER_2D_RECT_EXT
Definition GLDefines:278
GL_FLOAT_VEC3
#define GL_FLOAT_VEC3
Definition GLDefines:101
GL_IMAGE_BUFFER
#define GL_IMAGE_BUFFER
Definition GLDefines:364
GL_UNSIGNED_INT_SAMPLER_2D_EXT
#define GL_UNSIGNED_INT_SAMPLER_2D_EXT
Definition GLDefines:275
GL_DOUBLE_MAT3x2
#define GL_DOUBLE_MAT3x2
Definition GLDefines:341
GL_INT_SAMPLER_CUBE_EXT
#define GL_INT_SAMPLER_CUBE_EXT
Definition GLDefines:269
GL_IMAGE_3D
#define GL_IMAGE_3D
Definition GLDefines:361
GL_BOOL_VEC2
#define GL_BOOL_VEC2
Definition GLDefines:107
GL_DOUBLE_VEC2
#define GL_DOUBLE_VEC2
Definition GLDefines:333
GL_BOOL
#define GL_BOOL
Definition GLDefines:106
GL_SAMPLER_1D_SHADOW
#define GL_SAMPLER_1D_SHADOW
Definition GLDefines:146
GL_UNSIGNED_INT_IMAGE_2D_RECT
#define GL_UNSIGNED_INT_IMAGE_2D_RECT
Definition GLDefines:384
GL_UNSIGNED_INT_SAMPLER_2D_ARRAY_EXT
#define GL_UNSIGNED_INT_SAMPLER_2D_ARRAY_EXT
Definition GLDefines:280
GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE
#define GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE
Definition GLDefines:351
GL_SAMPLER_BUFFER_EXT
#define GL_SAMPLER_BUFFER_EXT
Definition GLDefines:259
GL_DOUBLE_MAT3
#define GL_DOUBLE_MAT3
Definition GLDefines:337
GL_SAMPLER_2D_MULTISAMPLE_ARRAY
#define GL_SAMPLER_2D_MULTISAMPLE_ARRAY
Definition GLDefines:352
GL_SAMPLER_2D_RECT_SHADOW
#define GL_SAMPLER_2D_RECT_SHADOW
Definition GLDefines:396
GL_FLOAT_MAT3
#define GL_FLOAT_MAT3
Definition GLDefines:111
GL_SAMPLER_2D_RECT
#define GL_SAMPLER_2D_RECT
Definition GLDefines:395
GL_INT_IMAGE_CUBE_MAP_ARRAY
#define GL_INT_IMAGE_CUBE_MAP_ARRAY
Definition GLDefines:378
GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY
#define GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY
Definition GLDefines:353
GL_FLOAT_VEC4
#define GL_FLOAT_VEC4
Definition GLDefines:102
GL_INT_IMAGE_CUBE
#define GL_INT_IMAGE_CUBE
Definition GLDefines:374
GL_INT_IMAGE_1D_ARRAY
#define GL_INT_IMAGE_1D_ARRAY
Definition GLDefines:376
GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT
#define GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT
Definition GLDefines:281
GL_FLOAT_MAT4x2
#define GL_FLOAT_MAT4x2
Definition GLDefines:161
GL_UNSIGNED_INT_VEC3_EXT
#define GL_UNSIGNED_INT_VEC3_EXT
Definition GLDefines:264
GL_INT_SAMPLER_1D_ARRAY_EXT
#define GL_INT_SAMPLER_1D_ARRAY_EXT
Definition GLDefines:271
GL_INT_SAMPLER_3D_EXT
#define GL_INT_SAMPLER_3D_EXT
Definition GLDefines:268
GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE
#define GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE
Definition GLDefines:390
GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY
#define GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY
Definition GLDefines:354
GL_INT_IMAGE_3D
#define GL_INT_IMAGE_3D
Definition GLDefines:372
GL_INT_SAMPLER_2D_RECT_EXT
#define GL_INT_SAMPLER_2D_RECT_EXT
Definition GLDefines:270
GL_DOUBLE_MAT4x3
#define GL_DOUBLE_MAT4x3
Definition GLDefines:344
GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY
#define GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY
Definition GLDefines:437
GL_IMAGE_2D
#define GL_IMAGE_2D
Definition GLDefines:360
GL_INT64_ARB
#define GL_INT64_ARB
Definition GLDefines:561
GL_UNSIGNED_INT_IMAGE_2D
#define GL_UNSIGNED_INT_IMAGE_2D
Definition GLDefines:382
GL_INT_IMAGE_BUFFER
#define GL_INT_IMAGE_BUFFER
Definition GLDefines:375
GL_INT_SAMPLER_1D_EXT
#define GL_INT_SAMPLER_1D_EXT
Definition GLDefines:266
GL_SAMPLER_2D_MULTISAMPLE
#define GL_SAMPLER_2D_MULTISAMPLE
Definition GLDefines:349
GL_INT_IMAGE_2D_RECT
#define GL_INT_IMAGE_2D_RECT
Definition GLDefines:373
GL_FLOAT_MAT3x2
#define GL_FLOAT_MAT3x2
Definition GLDefines:159
GL_INT_SAMPLER_BUFFER_EXT
#define GL_INT_SAMPLER_BUFFER_EXT
Definition GLDefines:273
GL_FLOAT_MAT2
#define GL_FLOAT_MAT2
Definition GLDefines:110
GL_UNSIGNED_INT_SAMPLER_CUBE_EXT
#define GL_UNSIGNED_INT_SAMPLER_CUBE_EXT
Definition GLDefines:277
GL_UNSIGNED_INT_VEC2_EXT
#define GL_UNSIGNED_INT_VEC2_EXT
Definition GLDefines:263
GL_FLOAT_MAT2x4
#define GL_FLOAT_MAT2x4
Definition GLDefines:158
GL_INT_IMAGE_1D
#define GL_INT_IMAGE_1D
Definition GLDefines:370
GL_UNSIGNED_INT_IMAGE_2D_ARRAY
#define GL_UNSIGNED_INT_IMAGE_2D_ARRAY
Definition GLDefines:388
GL_SAMPLER_2D_ARRAY_EXT
#define GL_SAMPLER_2D_ARRAY_EXT
Definition GLDefines:39
GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW
#define GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW
Definition GLDefines:435
GL_UNSIGNED_INT_IMAGE_3D
#define GL_UNSIGNED_INT_IMAGE_3D
Definition GLDefines:383
GL_DOUBLE_MAT3x4
#define GL_DOUBLE_MAT3x4
Definition GLDefines:342
GL_SAMPLER_1D_ARRAY_SHADOW_EXT
#define GL_SAMPLER_1D_ARRAY_SHADOW_EXT
Definition GLDefines:40
GL_SAMPLER_3D
#define GL_SAMPLER_3D
Definition GLDefines:142
GL_INT_SAMPLER_2D_ARRAY_EXT
#define GL_INT_SAMPLER_2D_ARRAY_EXT
Definition GLDefines:272
GL_DOUBLE_MAT4
#define GL_DOUBLE_MAT4
Definition GLDefines:338
GL_SAMPLER_2D_SHADOW
#define GL_SAMPLER_2D_SHADOW
Definition GLDefines:147
GL_FLOAT_VEC2
#define GL_FLOAT_VEC2
Definition GLDefines:100
GL_INT_IMAGE_2D
#define GL_INT_IMAGE_2D
Definition GLDefines:371
GL_INT_VEC4
#define GL_INT_VEC4
Definition GLDefines:105
GL_UNSIGNED_INT_SAMPLER_1D_ARRAY_EXT
#define GL_UNSIGNED_INT_SAMPLER_1D_ARRAY_EXT
Definition GLDefines:279
GL_UNSIGNED_INT64_ARB
#define GL_UNSIGNED_INT64_ARB
Definition GLDefines:562
GL_DOUBLE_MAT2
#define GL_DOUBLE_MAT2
Definition GLDefines:336
GL_INT_SAMPLER_2D_EXT
#define GL_INT_SAMPLER_2D_EXT
Definition GLDefines:267
GL_SAMPLER_CUBE
#define GL_SAMPLER_CUBE
Definition GLDefines:135
GL_SAMPLER_1D_ARRAY_EXT
#define GL_SAMPLER_1D_ARRAY_EXT
Definition GLDefines:38
GL_FLOAT_MAT4
#define GL_FLOAT_MAT4
Definition GLDefines:112
GL_UNSIGNED_INT_SAMPLER_1D_EXT
#define GL_UNSIGNED_INT_SAMPLER_1D_EXT
Definition GLDefines:274
GL_IMAGE_2D_MULTISAMPLE_ARRAY
#define GL_IMAGE_2D_MULTISAMPLE_ARRAY
Definition GLDefines:369
GL_SAMPLER_CUBE_SHADOW_EXT
#define GL_SAMPLER_CUBE_SHADOW_EXT
Definition GLDefines:262
GL_FLOAT_MAT4x3
#define GL_FLOAT_MAT4x3
Definition GLDefines:162
GL_IMAGE_1D
#define GL_IMAGE_1D
Definition GLDefines:359
GL_IMAGE_CUBE_MAP_ARRAY
#define GL_IMAGE_CUBE_MAP_ARRAY
Definition GLDefines:367
GLExtensions
Matrix
Vec2
Vec2d
Vec3
Vec3d
Vec4
Vec4d
osg::CopyOp
Definition CopyOp:41
osg::CopyOp::SHALLOW_COPY
@ SHALLOW_COPY
Definition CopyOp:47
osg::GLExtensions
Definition GLExtensions:169
osg::Matrix2Template
Definition Uniform:119
osg::Matrix2Template::~Matrix2Template
~Matrix2Template()
Definition Uniform:134
osg::Matrix2Template::Matrix2Template
Matrix2Template()
Definition Uniform:126
osg::Matrix2Template::base_class
MatrixTemplate< T, 2, 2 > base_class
Definition Uniform:121
osg::Matrix2Template::makeIdentity
void makeIdentity()
Definition Uniform:145
osg::Matrix2Template::value_type
base_class::value_type value_type
Definition Uniform:122
osg::Matrix2Template::set
void set(value_type a00, value_type a01, value_type a10, value_type a11)
Definition Uniform:138
osg::Matrix2Template::Matrix2Template
Matrix2Template(value_type a00, value_type a01, value_type a10, value_type a11)
Definition Uniform:128
osg::Matrix2Template::Matrix2Template
Matrix2Template(const Matrix2Template &mat)
Definition Uniform:127
osg::Matrix2x3Template
Definition Uniform:154
osg::Matrix2x3Template::Matrix2x3Template
Matrix2x3Template(value_type a00, value_type a01, value_type a02, value_type a10, value_type a11, value_type a12)
Definition Uniform:163
osg::Matrix2x3Template::Matrix2x3Template
Matrix2x3Template(const Matrix2x3Template &mat)
Definition Uniform:162
osg::Matrix2x3Template::~Matrix2x3Template
~Matrix2x3Template()
Definition Uniform:169
osg::Matrix2x3Template::value_type
base_class::value_type value_type
Definition Uniform:157
osg::Matrix2x3Template::Matrix2x3Template
Matrix2x3Template()
Definition Uniform:161
osg::Matrix2x3Template::base_class
MatrixTemplate< T, 2, 3 > base_class
Definition Uniform:156
osg::Matrix2x3Template::set
void set(value_type a00, value_type a01, value_type a02, value_type a10, value_type a11, value_type a12)
Definition Uniform:173
osg::Matrix2x4Template
Definition Uniform:183
osg::Matrix2x4Template::value_type
base_class::value_type value_type
Definition Uniform:186
osg::Matrix2x4Template::Matrix2x4Template
Matrix2x4Template(const Matrix2x4Template &mat)
Definition Uniform:191
osg::Matrix2x4Template::Matrix2x4Template
Matrix2x4Template(value_type a00, value_type a01, value_type a02, value_type a03, value_type a10, value_type a11, value_type a12, value_type a13)
Definition Uniform:192
osg::Matrix2x4Template::~Matrix2x4Template
~Matrix2x4Template()
Definition Uniform:198
osg::Matrix2x4Template::set
void set(value_type a00, value_type a01, value_type a02, value_type a03, value_type a10, value_type a11, value_type a12, value_type a13)
Definition Uniform:202
osg::Matrix2x4Template::base_class
MatrixTemplate< T, 2, 4 > base_class
Definition Uniform:185
osg::Matrix2x4Template::Matrix2x4Template
Matrix2x4Template()
Definition Uniform:190
osg::Matrix3Template
Definition Uniform:244
osg::Matrix3Template::value_type
base_class::value_type value_type
Definition Uniform:247
osg::Matrix3Template::Matrix3Template
Matrix3Template()
Definition Uniform:250
osg::Matrix3Template::makeIdentity
void makeIdentity()
Definition Uniform:273
osg::Matrix3Template::set
void set(value_type a00, value_type a01, value_type a02, value_type a10, value_type a11, value_type a12, value_type a20, value_type a21, value_type a22)
Definition Uniform:264
osg::Matrix3Template::~Matrix3Template
~Matrix3Template()
Definition Uniform:260
osg::Matrix3Template::base_class
MatrixTemplate< T, 3, 3 > base_class
Definition Uniform:246
osg::Matrix3Template::Matrix3Template
Matrix3Template(const Matrix3Template &mat)
Definition Uniform:251
osg::Matrix3Template::Matrix3Template
Matrix3Template(value_type a00, value_type a01, value_type a02, value_type a10, value_type a11, value_type a12, value_type a20, value_type a21, value_type a22)
Definition Uniform:252
osg::Matrix3x2Template
Definition Uniform:212
osg::Matrix3x2Template::Matrix3x2Template
Matrix3x2Template(value_type a00, value_type a01, value_type a10, value_type a11, value_type a20, value_type a21)
Definition Uniform:220
osg::Matrix3x2Template::Matrix3x2Template
Matrix3x2Template(const Matrix3x2Template &mat)
Definition Uniform:219
osg::Matrix3x2Template::set
void set(value_type a00, value_type a01, value_type a10, value_type a11, value_type a20, value_type a21)
Definition Uniform:232
osg::Matrix3x2Template::base_class
MatrixTemplate< T, 3, 2 > base_class
Definition Uniform:214
osg::Matrix3x2Template::~Matrix3x2Template
~Matrix3x2Template()
Definition Uniform:228
osg::Matrix3x2Template::Matrix3x2Template
Matrix3x2Template()
Definition Uniform:218
osg::Matrix3x2Template::value_type
base_class::value_type value_type
Definition Uniform:215
osg::Matrix3x4Template
Definition Uniform:283
osg::Matrix3x4Template::Matrix3x4Template
Matrix3x4Template(const Matrix3x4Template &mat)
Definition Uniform:290
osg::Matrix3x4Template::base_class
MatrixTemplate< T, 3, 4 > base_class
Definition Uniform:285
osg::Matrix3x4Template::set
void set(value_type a00, value_type a01, value_type a02, value_type a03, value_type a10, value_type a11, value_type a12, value_type a13, value_type a20, value_type a21, value_type a22, value_type a23)
Definition Uniform:303
osg::Matrix3x4Template::~Matrix3x4Template
~Matrix3x4Template()
Definition Uniform:299
osg::Matrix3x4Template::value_type
base_class::value_type value_type
Definition Uniform:286
osg::Matrix3x4Template::Matrix3x4Template
Matrix3x4Template(value_type a00, value_type a01, value_type a02, value_type a03, value_type a10, value_type a11, value_type a12, value_type a13, value_type a20, value_type a21, value_type a22, value_type a23)
Definition Uniform:291
osg::Matrix3x4Template::Matrix3x4Template
Matrix3x4Template()
Definition Uniform:289
osg::Matrix4x2Template
Definition Uniform:315
osg::Matrix4x2Template::Matrix4x2Template
Matrix4x2Template(const Matrix4x2Template &mat)
Definition Uniform:322
osg::Matrix4x2Template::set
void set(value_type a00, value_type a01, value_type a10, value_type a11, value_type a20, value_type a21, value_type a30, value_type a31)
Definition Uniform:337
osg::Matrix4x2Template::base_class
MatrixTemplate< T, 4, 2 > base_class
Definition Uniform:317
osg::Matrix4x2Template::Matrix4x2Template
Matrix4x2Template()
Definition Uniform:321
osg::Matrix4x2Template::Matrix4x2Template
Matrix4x2Template(value_type a00, value_type a01, value_type a10, value_type a11, value_type a20, value_type a21, value_type a30, value_type a31)
Definition Uniform:323
osg::Matrix4x2Template::~Matrix4x2Template
~Matrix4x2Template()
Definition Uniform:333
osg::Matrix4x2Template::value_type
base_class::value_type value_type
Definition Uniform:318
osg::Matrix4x3Template
Definition Uniform:351
osg::Matrix4x3Template::base_class
MatrixTemplate< T, 4, 3 > base_class
Definition Uniform:353
osg::Matrix4x3Template::value_type
base_class::value_type value_type
Definition Uniform:354
osg::Matrix4x3Template::set
void set(value_type a00, value_type a01, value_type a02, value_type a10, value_type a11, value_type a12, value_type a20, value_type a21, value_type a22, value_type a30, value_type a31, value_type a32)
Definition Uniform:373
osg::Matrix4x3Template::Matrix4x3Template
Matrix4x3Template(const Matrix4x3Template &mat)
Definition Uniform:358
osg::Matrix4x3Template::~Matrix4x3Template
~Matrix4x3Template()
Definition Uniform:369
osg::Matrix4x3Template::Matrix4x3Template
Matrix4x3Template(value_type a00, value_type a01, value_type a02, value_type a10, value_type a11, value_type a12, value_type a20, value_type a21, value_type a22, value_type a30, value_type a31, value_type a32)
Definition Uniform:359
osg::Matrix4x3Template::Matrix4x3Template
Matrix4x3Template()
Definition Uniform:357
osg::MatrixTemplate::ptr
value_type * ptr()
Definition Uniform:105
osg::MatrixTemplate::ptr
const value_type * ptr() const
Definition Uniform:106
osg::MatrixTemplate::operator[]
value_type & operator[](int i)
Definition Uniform:108
osg::MatrixTemplate< T, 2, 2 >::value_count
@ value_count
Definition Uniform:78
osg::MatrixTemplate::~MatrixTemplate
~MatrixTemplate()
Definition Uniform:85
osg::MatrixTemplate::value_type
T value_type
Definition Uniform:80
osg::MatrixTemplate::MatrixTemplate
MatrixTemplate()
Definition Uniform:84
osg::MatrixTemplate::operator()
value_type operator()(int row, int col) const
Definition Uniform:88
osg::MatrixTemplate::operator=
MatrixTemplate & operator=(const MatrixTemplate &rhs)
Definition Uniform:90
osg::MatrixTemplate< T, 2, 2 >::row_count
@ row_count
Definition Uniform:77
osg::MatrixTemplate< T, 2, 2 >::col_count
@ col_count
Definition Uniform:76
osg::MatrixTemplate::reset
void reset()
Definition Uniform:111
osg::MatrixTemplate::set
void set(const MatrixTemplate &rhs)
Definition Uniform:97
osg::MatrixTemplate< T, 2, 2 >::_mat
value_type _mat[row_count][col_count]
Definition Uniform:114
osg::MatrixTemplate::operator()
value_type & operator()(int row, int col)
Definition Uniform:87
osg::MatrixTemplate::set
void set(value_type const *const ptr)
Definition Uniform:99
osg::Matrixd
Definition Matrixd:27
osg::Matrixf
Definition Matrixf:27
osg::Object::Object
Object()
Definition Object:69
osg::StateSet
Definition StateSet:46
osg::UniformCallback
Definition Callback:271
osg::Uniform::Uniform
Uniform(const char *name, int i)
osg::Uniform::setElement
bool setElement(unsigned int index, unsigned int ui0, unsigned int ui1, unsigned int ui2, unsigned int ui3)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Vec2d &v2)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix4x2d &m4x2)
osg::Uniform::setArray
bool setArray(DoubleArray *array)
osg::Uniform::getEventCallback
const UniformCallback * getEventCallback() const
Definition Uniform:870
osg::Uniform::_type
Type _type
Definition Uniform:936
osg::Uniform::Uniform
Uniform(const char *name, unsigned long long ull)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Vec4d &v4)
osg::Uniform::set
bool set(unsigned int ui0, unsigned int ui1, unsigned int ui2)
osg::Uniform::getEventCallback
UniformCallback * getEventCallback()
Definition Uniform:867
osg::Uniform::set
bool set(const osg::Vec3d &v3)
osg::Uniform::getIntArray
IntArray * getIntArray()
Definition Uniform:893
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix4x2 &m4x2) const
osg::Uniform::setNumElements
void setNumElements(unsigned int numElements)
osg::Uniform::Uniform
Uniform(const char *name, bool b)
osg::Uniform::setName
virtual void setName(const std::string &name)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrixf &m4)
osg::Uniform::set
bool set(const osg::Vec3 &v3)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix2x4d &m2x4) const
osg::Uniform::ParentList
std::vector< StateSet * > ParentList
Definition Uniform:657
osg::Uniform::_updateCallback
ref_ptr< UniformCallback > _updateCallback
Definition Uniform:950
osg::Uniform::set
bool set(const osg::Matrix4x2d &m4x2)
osg::Uniform::setModifiedCount
void setModifiedCount(unsigned int mc)
Definition Uniform:908
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Vec3d &v3) const
osg::Uniform::isCompatibleType
bool isCompatibleType(Type t1, Type t2) const
osg::Uniform::get
bool get(unsigned int &ui0, unsigned int &ui1) const
osg::Uniform::_uintArray
ref_ptr< UIntArray > _uintArray
Definition Uniform:946
osg::Uniform::Uniform
Uniform(const char *name, const osg::Vec3 &v3)
osg::Uniform::_int64Array
ref_ptr< Int64Array > _int64Array
Definition Uniform:947
osg::Uniform::set
bool set(bool b0, bool b1, bool b2, bool b3)
osg::Uniform::getDoubleArray
const DoubleArray * getDoubleArray() const
Definition Uniform:890
osg::Uniform::getNameID
static unsigned int getNameID(const std::string &name)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Vec2d &v2) const
osg::Uniform::set
bool set(const osg::Matrix4x3 &m4x3)
osg::Uniform::get
bool get(osg::Matrix4x3d &m4x3) const
osg::Uniform::dirty
void dirty()
Definition Uniform:875
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix2x3d &m2x3) const
osg::Uniform::set
bool set(const osg::Vec2 &v2)
osg::Uniform::set
bool set(const osg::Matrix2d &m2)
osg::Uniform::setEventCallback
void setEventCallback(UniformCallback *ec)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix2x3d &m2x3)
osg::Uniform::setElement
bool setElement(unsigned int index, int i0, int i1, int i2, int i3)
osg::Uniform::get
bool get(osg::Matrix2x4d &m2x4) const
osg::Uniform::get
bool get(osg::Matrix4x2d &m4x2) const
osg::Uniform::getTypeNumComponents
static int getTypeNumComponents(Type t)
osg::Uniform::getUIntArray
UIntArray * getUIntArray()
Definition Uniform:897
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrixd &m4) const
osg::Uniform::get
bool get(osg::Matrix3 &m3) const
osg::Uniform::set
bool set(unsigned long long ull)
osg::Uniform::asUniform
virtual Uniform * asUniform()
Definition Uniform:559
osg::Uniform::get
bool get(osg::Matrix4x2 &m4x2) const
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix3d &m3) const
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix2x4d &m2x4)
osg::Uniform::get
bool get(osg::Matrix3d &m3) const
osg::Uniform::set
bool set(int i0, int i1, int i2)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix2x3 &m2x3)
osg::Uniform::allocateDataArray
void allocateDataArray()
osg::Uniform::getType
Type getType() const
Definition Uniform:570
osg::Uniform::_intArray
ref_ptr< IntArray > _intArray
Definition Uniform:945
osg::Uniform::Uniform
Uniform(const char *name, unsigned int ui0, unsigned int ui1)
osg::Uniform::set
bool set(const osg::Matrix4x3d &m4x3)
osg::Uniform::META_Object
META_Object(osg, Uniform)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix3x2d &m3x2) const
osg::Uniform::get
bool get(osg::Matrixd &m4) const
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix3x4d &m3x4)
osg::Uniform::setElement
bool setElement(unsigned int index, int i)
osg::Uniform::set
bool set(const osg::Matrixd &m4)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Vec4 &v4) const
osg::Uniform::get
bool get(osg::Vec3 &v3) const
osg::Uniform::get
bool get(int &i0, int &i1, int &i2) const
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix4x3d &m4x3)
osg::Uniform::getUpdateCallback
UniformCallback * getUpdateCallback()
Definition Uniform:858
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix3x2d &m3x2)
osg::Uniform::getElement
bool getElement(unsigned int index, unsigned int &ui0, unsigned int &ui1, unsigned int &ui2) const
osg::Uniform::setElement
bool setElement(unsigned int index, unsigned long long ull)
osg::Uniform::get
bool get(osg::Matrix3x4 &m3x4) const
osg::Uniform::get
bool get(osg::Matrix4x3 &m4x3) const
osg::Uniform::set
bool set(const osg::Matrix3 &m3)
osg::Uniform::get
bool get(osg::Matrix2 &m2) const
osg::Uniform::get
bool get(osg::Vec2 &v2) const
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix2 &m2)
osg::Uniform::setElement
bool setElement(unsigned int index, unsigned int ui0, unsigned int ui1)
osg::Uniform::get
bool get(bool &b0, bool &b1, bool &b2, bool &b3) const
osg::Uniform::Type
Type
Definition Uniform:416
osg::Uniform::UNSIGNED_INT_IMAGE_2D_MULTISAMPLE
@ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE
Definition Uniform:541
osg::Uniform::UNSIGNED_INT_IMAGE_BUFFER
@ UNSIGNED_INT_IMAGE_BUFFER
Definition Uniform:537
osg::Uniform::FLOAT_MAT3x2
@ FLOAT_MAT3x2
Definition Uniform:450
osg::Uniform::FLOAT_MAT4x2
@ FLOAT_MAT4x2
Definition Uniform:452
osg::Uniform::SAMPLER_3D
@ SAMPLER_3D
Definition Uniform:467
osg::Uniform::SAMPLER_2D_RECT_SHADOW
@ SAMPLER_2D_RECT_SHADOW
Definition Uniform:482
osg::Uniform::UNSIGNED_INT_VEC3
@ UNSIGNED_INT_VEC3
Definition Uniform:434
osg::Uniform::UNSIGNED_INT_IMAGE_1D_ARRAY
@ UNSIGNED_INT_IMAGE_1D_ARRAY
Definition Uniform:538
osg::Uniform::DOUBLE_MAT4
@ DOUBLE_MAT4
Definition Uniform:457
osg::Uniform::INT_IMAGE_2D_ARRAY
@ INT_IMAGE_2D_ARRAY
Definition Uniform:527
osg::Uniform::SAMPLER_1D_ARRAY
@ SAMPLER_1D_ARRAY
Definition Uniform:471
osg::Uniform::INT_SAMPLER_CUBE
@ INT_SAMPLER_CUBE
Definition Uniform:487
osg::Uniform::INT_VEC2
@ INT_VEC2
Definition Uniform:428
osg::Uniform::INT_IMAGE_2D_MULTISAMPLE
@ INT_IMAGE_2D_MULTISAMPLE
Definition Uniform:529
osg::Uniform::SAMPLER_2D_RECT
@ SAMPLER_2D_RECT
Definition Uniform:481
osg::Uniform::DOUBLE_MAT2x3
@ DOUBLE_MAT2x3
Definition Uniform:458
osg::Uniform::UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY
@ UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY
Definition Uniform:502
osg::Uniform::IMAGE_CUBE
@ IMAGE_CUBE
Definition Uniform:512
osg::Uniform::IMAGE_2D_RECT
@ IMAGE_2D_RECT
Definition Uniform:511
osg::Uniform::INT_IMAGE_2D
@ INT_IMAGE_2D
Definition Uniform:521
osg::Uniform::DOUBLE_MAT3x4
@ DOUBLE_MAT3x4
Definition Uniform:461
osg::Uniform::INT_SAMPLER_2D_ARRAY
@ INT_SAMPLER_2D_ARRAY
Definition Uniform:489
osg::Uniform::IMAGE_1D
@ IMAGE_1D
Definition Uniform:508
osg::Uniform::UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY
@ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY
Definition Uniform:542
osg::Uniform::DOUBLE_VEC3
@ DOUBLE_VEC3
Definition Uniform:424
osg::Uniform::INT_VEC4
@ INT_VEC4
Definition Uniform:430
osg::Uniform::SAMPLER_2D
@ SAMPLER_2D
Definition Uniform:466
osg::Uniform::SAMPLER_2D_MULTISAMPLE_ARRAY
@ SAMPLER_2D_MULTISAMPLE_ARRAY
Definition Uniform:477
osg::Uniform::UNSIGNED_INT_SAMPLER_BUFFER
@ UNSIGNED_INT_SAMPLER_BUFFER
Definition Uniform:505
osg::Uniform::INT_SAMPLER_2D_MULTISAMPLE_ARRAY
@ INT_SAMPLER_2D_MULTISAMPLE_ARRAY
Definition Uniform:492
osg::Uniform::IMAGE_2D_MULTISAMPLE
@ IMAGE_2D_MULTISAMPLE
Definition Uniform:517
osg::Uniform::INT_IMAGE_2D_RECT
@ INT_IMAGE_2D_RECT
Definition Uniform:523
osg::Uniform::FLOAT_MAT4
@ FLOAT_MAT4
Definition Uniform:447
osg::Uniform::UNDEFINED
@ UNDEFINED
Definition Uniform:544
osg::Uniform::UNSIGNED_INT_SAMPLER_CUBE
@ UNSIGNED_INT_SAMPLER_CUBE
Definition Uniform:499
osg::Uniform::UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE
@ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE
Definition Uniform:503
osg::Uniform::INT_SAMPLER_2D_RECT
@ INT_SAMPLER_2D_RECT
Definition Uniform:494
osg::Uniform::UNSIGNED_INT_IMAGE_2D
@ UNSIGNED_INT_IMAGE_2D
Definition Uniform:533
osg::Uniform::UNSIGNED_INT_SAMPLER_2D_ARRAY
@ UNSIGNED_INT_SAMPLER_2D_ARRAY
Definition Uniform:501
osg::Uniform::FLOAT_MAT3
@ FLOAT_MAT3
Definition Uniform:446
osg::Uniform::INT_IMAGE_3D
@ INT_IMAGE_3D
Definition Uniform:522
osg::Uniform::SAMPLER_1D_ARRAY_SHADOW
@ SAMPLER_1D_ARRAY_SHADOW
Definition Uniform:474
osg::Uniform::INT64
@ INT64
Definition Uniform:442
osg::Uniform::DOUBLE_MAT2
@ DOUBLE_MAT2
Definition Uniform:455
osg::Uniform::UNSIGNED_INT64
@ UNSIGNED_INT64
Definition Uniform:443
osg::Uniform::UNSIGNED_INT_SAMPLER_1D_ARRAY
@ UNSIGNED_INT_SAMPLER_1D_ARRAY
Definition Uniform:500
osg::Uniform::IMAGE_2D_MULTISAMPLE_ARRAY
@ IMAGE_2D_MULTISAMPLE_ARRAY
Definition Uniform:518
osg::Uniform::SAMPLER_1D
@ SAMPLER_1D
Definition Uniform:465
osg::Uniform::FLOAT_VEC2
@ FLOAT_VEC2
Definition Uniform:418
osg::Uniform::INT_IMAGE_CUBE
@ INT_IMAGE_CUBE
Definition Uniform:524
osg::Uniform::UNSIGNED_INT
@ UNSIGNED_INT
Definition Uniform:432
osg::Uniform::UNSIGNED_INT_VEC2
@ UNSIGNED_INT_VEC2
Definition Uniform:433
osg::Uniform::SAMPLER_BUFFER
@ SAMPLER_BUFFER
Definition Uniform:480
osg::Uniform::INT_IMAGE_CUBE_MAP_ARRAY
@ INT_IMAGE_CUBE_MAP_ARRAY
Definition Uniform:528
osg::Uniform::IMAGE_2D
@ IMAGE_2D
Definition Uniform:509
osg::Uniform::INT_SAMPLER_2D_MULTISAMPLE
@ INT_SAMPLER_2D_MULTISAMPLE
Definition Uniform:491
osg::Uniform::FLOAT_MAT3x4
@ FLOAT_MAT3x4
Definition Uniform:451
osg::Uniform::INT_SAMPLER_3D
@ INT_SAMPLER_3D
Definition Uniform:486
osg::Uniform::UNSIGNED_INT_IMAGE_CUBE
@ UNSIGNED_INT_IMAGE_CUBE
Definition Uniform:536
osg::Uniform::IMAGE_2D_ARRAY
@ IMAGE_2D_ARRAY
Definition Uniform:515
osg::Uniform::UNSIGNED_INT_IMAGE_3D
@ UNSIGNED_INT_IMAGE_3D
Definition Uniform:534
osg::Uniform::DOUBLE_MAT4x2
@ DOUBLE_MAT4x2
Definition Uniform:462
osg::Uniform::FLOAT_MAT2
@ FLOAT_MAT2
Definition Uniform:445
osg::Uniform::SAMPLER_2D_ARRAY_SHADOW
@ SAMPLER_2D_ARRAY_SHADOW
Definition Uniform:475
osg::Uniform::UNSIGNED_INT_IMAGE_1D
@ UNSIGNED_INT_IMAGE_1D
Definition Uniform:532
osg::Uniform::IMAGE_1D_ARRAY
@ IMAGE_1D_ARRAY
Definition Uniform:514
osg::Uniform::INT_SAMPLER_1D
@ INT_SAMPLER_1D
Definition Uniform:484
osg::Uniform::SAMPLER_2D_MULTISAMPLE
@ SAMPLER_2D_MULTISAMPLE
Definition Uniform:476
osg::Uniform::SAMPLER_1D_SHADOW
@ SAMPLER_1D_SHADOW
Definition Uniform:469
osg::Uniform::BOOL_VEC4
@ BOOL_VEC4
Definition Uniform:440
osg::Uniform::INT_VEC3
@ INT_VEC3
Definition Uniform:429
osg::Uniform::INT_SAMPLER_BUFFER
@ INT_SAMPLER_BUFFER
Definition Uniform:493
osg::Uniform::FLOAT_VEC3
@ FLOAT_VEC3
Definition Uniform:419
osg::Uniform::FLOAT
@ FLOAT
Definition Uniform:417
osg::Uniform::FLOAT_MAT4x3
@ FLOAT_MAT4x3
Definition Uniform:453
osg::Uniform::UNSIGNED_INT_SAMPLER_3D
@ UNSIGNED_INT_SAMPLER_3D
Definition Uniform:498
osg::Uniform::DOUBLE_MAT2x4
@ DOUBLE_MAT2x4
Definition Uniform:459
osg::Uniform::UNSIGNED_INT_SAMPLER_2D
@ UNSIGNED_INT_SAMPLER_2D
Definition Uniform:497
osg::Uniform::IMAGE_3D
@ IMAGE_3D
Definition Uniform:510
osg::Uniform::DOUBLE_VEC2
@ DOUBLE_VEC2
Definition Uniform:423
osg::Uniform::INT_IMAGE_2D_MULTISAMPLE_ARRAY
@ INT_IMAGE_2D_MULTISAMPLE_ARRAY
Definition Uniform:530
osg::Uniform::FLOAT_MAT2x4
@ FLOAT_MAT2x4
Definition Uniform:449
osg::Uniform::INT_SAMPLER_CUBE_MAP_ARRAY
@ INT_SAMPLER_CUBE_MAP_ARRAY
Definition Uniform:490
osg::Uniform::BOOL_VEC3
@ BOOL_VEC3
Definition Uniform:439
osg::Uniform::INT_IMAGE_BUFFER
@ INT_IMAGE_BUFFER
Definition Uniform:525
osg::Uniform::SAMPLER_CUBE
@ SAMPLER_CUBE
Definition Uniform:468
osg::Uniform::SAMPLER_2D_ARRAY
@ SAMPLER_2D_ARRAY
Definition Uniform:472
osg::Uniform::SAMPLER_CUBE_SHADOW
@ SAMPLER_CUBE_SHADOW
Definition Uniform:478
osg::Uniform::SAMPLER_CUBE_MAP_ARRAY_SHADOW
@ SAMPLER_CUBE_MAP_ARRAY_SHADOW
Definition Uniform:479
osg::Uniform::INT
@ INT
Definition Uniform:427
osg::Uniform::DOUBLE_VEC4
@ DOUBLE_VEC4
Definition Uniform:425
osg::Uniform::IMAGE_CUBE_MAP_ARRAY
@ IMAGE_CUBE_MAP_ARRAY
Definition Uniform:516
osg::Uniform::SAMPLER_CUBE_MAP_ARRAY
@ SAMPLER_CUBE_MAP_ARRAY
Definition Uniform:473
osg::Uniform::INT_IMAGE_1D
@ INT_IMAGE_1D
Definition Uniform:520
osg::Uniform::IMAGE_BUFFER
@ IMAGE_BUFFER
Definition Uniform:513
osg::Uniform::DOUBLE_MAT4x3
@ DOUBLE_MAT4x3
Definition Uniform:463
osg::Uniform::BOOL
@ BOOL
Definition Uniform:437
osg::Uniform::UNSIGNED_INT_SAMPLER_1D
@ UNSIGNED_INT_SAMPLER_1D
Definition Uniform:496
osg::Uniform::INT_SAMPLER_2D
@ INT_SAMPLER_2D
Definition Uniform:485
osg::Uniform::FLOAT_MAT2x3
@ FLOAT_MAT2x3
Definition Uniform:448
osg::Uniform::DOUBLE
@ DOUBLE
Definition Uniform:422
osg::Uniform::UNSIGNED_INT_SAMPLER_2D_RECT
@ UNSIGNED_INT_SAMPLER_2D_RECT
Definition Uniform:506
osg::Uniform::INT_SAMPLER_1D_ARRAY
@ INT_SAMPLER_1D_ARRAY
Definition Uniform:488
osg::Uniform::UNSIGNED_INT_IMAGE_2D_RECT
@ UNSIGNED_INT_IMAGE_2D_RECT
Definition Uniform:535
osg::Uniform::UNSIGNED_INT_IMAGE_2D_ARRAY
@ UNSIGNED_INT_IMAGE_2D_ARRAY
Definition Uniform:539
osg::Uniform::SAMPLER_2D_SHADOW
@ SAMPLER_2D_SHADOW
Definition Uniform:470
osg::Uniform::BOOL_VEC2
@ BOOL_VEC2
Definition Uniform:438
osg::Uniform::INT_IMAGE_1D_ARRAY
@ INT_IMAGE_1D_ARRAY
Definition Uniform:526
osg::Uniform::DOUBLE_MAT3
@ DOUBLE_MAT3
Definition Uniform:456
osg::Uniform::UNSIGNED_INT_VEC4
@ UNSIGNED_INT_VEC4
Definition Uniform:435
osg::Uniform::UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY
@ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY
Definition Uniform:504
osg::Uniform::DOUBLE_MAT3x2
@ DOUBLE_MAT3x2
Definition Uniform:460
osg::Uniform::FLOAT_VEC4
@ FLOAT_VEC4
Definition Uniform:420
osg::Uniform::UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY
@ UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY
Definition Uniform:540
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix3x4d &m3x4)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix2d &m2)
osg::Uniform::get
bool get(int &i0, int &i1) const
osg::Uniform::getNumParents
unsigned int getNumParents() const
Definition Uniform:678
osg::Uniform::_doubleArray
ref_ptr< DoubleArray > _doubleArray
Definition Uniform:944
osg::Uniform::get
bool get(bool &b0, bool &b1, bool &b2) const
osg::Uniform::set
bool set(unsigned int ui)
osg::Uniform::Uniform
Uniform(const char *name, unsigned int ui0, unsigned int ui1, unsigned int ui2)
osg::Uniform::Uniform
Uniform(const char *name, bool b0, bool b1, bool b2, bool b3)
osg::Uniform::get
bool get(osg::Matrix2x3 &m2x3) const
osg::Uniform::set
bool set(bool b0, bool b1)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix4x3 &m4x3)
osg::Uniform::getUInt64Array
UInt64Array * getUInt64Array()
Definition Uniform:901
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix2x4 &m2x4)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix2x4 &m2x4) const
osg::Uniform::getInt64Array
const Int64Array * getInt64Array() const
Definition Uniform:906
osg::Uniform::set
bool set(const osg::Matrix2x4 &m2x4)
osg::Uniform::getElement
bool getElement(unsigned int index, long long &ll) const
osg::Uniform::get
bool get(long long &ll) const
osg::Uniform::getElement
bool getElement(unsigned int index, int &i0, int &i1) const
osg::Uniform::set
bool set(bool b)
osg::Uniform::Uniform
Uniform(const char *name, float f)
osg::Uniform::set
bool set(const osg::Vec2d &v2)
osg::Uniform::getElement
bool getElement(unsigned int index, unsigned int &ui0, unsigned int &ui1, unsigned int &ui2, unsigned int &ui3) const
osg::Uniform::Callback
UniformCallback Callback
Definition Uniform:851
osg::Uniform::getUInt64Array
const UInt64Array * getUInt64Array() const
Definition Uniform:902
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix3d &m3)
osg::Uniform::set
bool set(int i0, int i1, int i2, int i3)
osg::Uniform::Uniform
Uniform(const char *name, unsigned int ui)
osg::Uniform::StateSet
friend class osg::StateSet
Definition Uniform:934
osg::Uniform::setElement
bool setElement(unsigned int index, bool b0, bool b1, bool b2)
osg::Uniform::get
bool get(osg::Vec2d &v2) const
osg::Uniform::get
bool get(float &f) const
osg::Uniform::getParents
const ParentList & getParents() const
Definition Uniform:660
osg::Uniform::get
bool get(unsigned long long &ull) const
osg::Uniform::_eventCallback
ref_ptr< UniformCallback > _eventCallback
Definition Uniform:951
osg::Uniform::operator=
Uniform & operator=(const Uniform &)
Definition Uniform:920
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix2x4 &m2x4)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix3x4d &m3x4) const
osg::Uniform::set
bool set(unsigned int ui0, unsigned int ui1, unsigned int ui2, unsigned int ui3)
osg::Uniform::set
bool set(unsigned int ui0, unsigned int ui1)
osg::Uniform::Uniform
Uniform(const char *name, int i0, int i1, int i2)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix4x2 &m4x2)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix3d &m3)
osg::Uniform::getGlApiType
static Type getGlApiType(Type t)
osg::Uniform::setElement
bool setElement(unsigned int index, bool b0, bool b1, bool b2, bool b3)
osg::Uniform::getUpdateCallback
const UniformCallback * getUpdateCallback() const
Definition Uniform:861
osg::Uniform::set
bool set(float f)
osg::Uniform::asUniform
virtual const Uniform * asUniform() const
Definition Uniform:563
osg::Uniform::set
bool set(const osg::Vec4d &v4)
osg::Uniform::getElement
bool getElement(unsigned int index, unsigned long long &ull) const
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix3x4 &m3x4)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix3x2 &m3x2)
osg::Uniform::getParent
StateSet * getParent(unsigned int i)
Definition Uniform:666
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix2x3 &m2x3) const
osg::Uniform::setElement
bool setElement(unsigned int index, unsigned int ui)
osg::Uniform::apply
void apply(const GLExtensions *ext, GLint location) const
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix2d &m2)
osg::Uniform::Uniform
Uniform(const char *name, int i0, int i1)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Vec4 &v4)
osg::Uniform::addParent
void addParent(osg::StateSet *object)
osg::Uniform::setUpdateCallback
void setUpdateCallback(UniformCallback *uc)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix4x3d &m4x3)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix4x2d &m4x2)
osg::Uniform::set
bool set(const osg::Matrix3x2 &m3x2)
osg::Uniform::getElement
bool getElement(unsigned int index, int &i0, int &i1, int &i2) const
osg::Uniform::getElement
bool getElement(unsigned int index, int &i) const
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Vec3d &v3)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Vec4d &v4)
osg::Uniform::setElement
bool setElement(unsigned int index, int i0, int i1)
osg::Uniform::setElement
bool setElement(unsigned int index, float f)
osg::Uniform::getElement
bool getElement(unsigned int index, unsigned int &ui) const
osg::Uniform::get
bool get(osg::Matrix2x3d &m2x3) const
osg::Uniform::set
bool set(const osg::Matrixf &m4)
osg::Uniform::getElement
bool getElement(unsigned int index, double &d) const
osg::Uniform::get
bool get(bool &b0, bool &b1) const
osg::Uniform::setArray
bool setArray(UIntArray *array)
osg::Uniform::getIntArray
const IntArray * getIntArray() const
Definition Uniform:894
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix2d &m2) const
osg::Uniform::set
bool set(const osg::Matrix2x3d &m2x3)
osg::Uniform::get
bool get(osg::Vec4d &v4) const
osg::Uniform::get
bool get(osg::Matrixf &m4) const
osg::Uniform::Uniform
Uniform(const char *name, unsigned int ui0, unsigned int ui1, unsigned int ui2, unsigned int ui3)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix4x2 &m4x2)
osg::Uniform::_parents
ParentList _parents
Definition Uniform:933
osg::Uniform::getInt64Array
Int64Array * getInt64Array()
Definition Uniform:905
osg::Uniform::setElement
bool setElement(unsigned int index, unsigned int ui0, unsigned int ui1, unsigned int ui2)
osg::Uniform::get
bool get(osg::Matrix3x4d &m3x4) const
osg::Uniform::getNameID
unsigned int getNameID() const
osg::Uniform::get
bool get(unsigned int &ui0, unsigned int &ui1, unsigned int &ui2) const
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrixf &m4)
osg::Uniform::set
bool set(const osg::Matrix2 &m2)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix3 &m3)
osg::Uniform::Uniform
Uniform(const char *name, bool b0, bool b1)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Vec2d &v2)
osg::Uniform::setArray
bool setArray(IntArray *array)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Vec3d &v3)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix3x4 &m3x4) const
osg::Uniform::getModifiedCount
unsigned int getModifiedCount() const
Definition Uniform:909
osg::Uniform::Uniform
Uniform(Type type, const std::string &name, int numElements=1)
osg::Uniform::get
bool get(unsigned int &ui) const
osg::Uniform::setArray
bool setArray(Int64Array *array)
osg::Uniform::getTypename
static const char * getTypename(Type t)
osg::Uniform::getElement
bool getElement(unsigned int index, bool &b) const
osg::Uniform::_floatArray
ref_ptr< FloatArray > _floatArray
Definition Uniform:943
osg::Uniform::removeParent
void removeParent(osg::StateSet *object)
osg::Uniform::getElement
bool getElement(unsigned int index, bool &b0, bool &b1, bool &b2, bool &b3) const
osg::Uniform::getInternalArrayType
static GLenum getInternalArrayType(Type t)
osg::Uniform::setArray
bool setArray(UInt64Array *array)
osg::Uniform::set
bool set(const osg::Matrix3x2d &m3x2)
osg::Uniform::Uniform
Uniform(const char *name, double d)
osg::Uniform::getFloatArray
FloatArray * getFloatArray()
Definition Uniform:885
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix3 &m3)
osg::Uniform::getTypeId
static Uniform::Type getTypeId(const std::string &tname)
osg::Uniform::_numElements
unsigned int _numElements
Definition Uniform:937
osg::Uniform::getElement
bool getElement(unsigned int index, int &i0, int &i1, int &i2, int &i3) const
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix3x4 &m3x4)
osg::Uniform::set
bool set(const osg::Matrix3x4 &m3x4)
osg::Uniform::getParent
const StateSet * getParent(unsigned int i) const
Definition Uniform:672
osg::Uniform::getDoubleArray
DoubleArray * getDoubleArray()
Definition Uniform:889
osg::Uniform::get
bool get(int &i) const
osg::Uniform::getParents
ParentList getParents()
Definition Uniform:664
osg::Uniform::set
bool set(const osg::Matrix2x4d &m2x4)
osg::Uniform::isScalar
bool isScalar() const
Definition Uniform:927
osg::Uniform::get
bool get(int &i0, int &i1, int &i2, int &i3) const
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix4x3d &m4x3) const
osg::Uniform::compareData
virtual int compareData(const Uniform &rhs) const
osg::Uniform::set
bool set(const osg::Matrix2x3 &m2x3)
osg::Uniform::_modifiedCount
unsigned int _modifiedCount
Definition Uniform:953
osg::Uniform::set
bool set(const osg::Matrix4x2 &m4x2)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrixd &m4)
osg::Uniform::getInternalArrayNumElements
unsigned int getInternalArrayNumElements() const
osg::Uniform::Uniform
Uniform(const char *name, const osg::Vec4 &v4)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix2x4d &m2x4)
osg::Uniform::set
bool set(long long ll)
osg::Uniform::setElement
bool setElement(unsigned int index, bool b0, bool b1)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Vec4d &v4) const
osg::Uniform::setType
bool setType(Type t)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix2 &m2) const
osg::Uniform::copyData
void copyData(const Uniform &rhs)
osg::Uniform::Uniform
Uniform(const char *name, int i0, int i1, int i2, int i3)
osg::Uniform::getElement
bool getElement(unsigned int index, bool &b0, bool &b1, bool &b2) const
osg::Uniform::Uniform
Uniform()
osg::Uniform::set
bool set(int i0, int i1)
osg::Uniform::get
bool get(osg::Matrix3x2d &m3x2) const
osg::Uniform::get
bool get(osg::Matrix2d &m2) const
osg::Uniform::get
bool get(osg::Vec3d &v3) const
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix4x2d &m4x2) const
osg::Uniform::Uniform
Uniform(const Uniform &rhs, const CopyOp &copyop=CopyOp::SHALLOW_COPY)
osg::Uniform::getFloatArray
const FloatArray * getFloatArray() const
Definition Uniform:886
osg::Uniform::set
bool set(const osg::Matrix3x4d &m3x4)
osg::Uniform::_uint64Array
ref_ptr< UInt64Array > _uint64Array
Definition Uniform:948
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Vec3 &v3) const
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix2 &m2)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix3 &m3) const
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix2x3d &m2x3)
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Vec2 &v2) const
osg::Uniform::getNumElements
unsigned int getNumElements() const
Definition Uniform:579
osg::Uniform::Uniform
Uniform(const char *name, long long ll)
osg::Uniform::setElement
bool setElement(unsigned int index, double d)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix3x2 &m3x2)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Vec2 &v2)
osg::Uniform::~Uniform
virtual ~Uniform()
osg::Uniform::compare
virtual int compare(const Uniform &rhs) const
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix3x2 &m3x2) const
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrixf &m4) const
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrixd &m4)
osg::Uniform::_nameID
unsigned int _nameID
Definition Uniform:938
osg::Uniform::get
bool get(osg::Matrix3x2 &m3x2) const
osg::Uniform::isCompatibleType
bool isCompatibleType(Type t) const
osg::Uniform::set
bool set(double d)
osg::Uniform::getElement
bool getElement(unsigned int index, unsigned int &ui0, unsigned int &ui1) const
osg::Uniform::set
bool set(const osg::Vec4 &v4)
osg::Uniform::getElement
bool getElement(unsigned int index, bool &b0, bool &b1) const
osg::Uniform::get
bool get(double &d) const
osg::Uniform::Uniform
Uniform(const char *name, const osg::Vec2 &v2)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix4x3 &m4x3)
osg::Uniform::get
bool get(osg::Matrix2x4 &m2x4) const
osg::Uniform::setElement
bool setElement(unsigned int index, long long ll)
osg::Uniform::getElement
bool getElement(unsigned int index, float &f) const
osg::Uniform::Uniform
Uniform(const char *name, bool b0, bool b1, bool b2)
osg::Uniform::Uniform
Uniform(const char *name, const osg::Matrix2x3 &m2x3)
osg::Uniform::set
bool set(bool b0, bool b1, bool b2)
osg::Uniform::get
bool get(osg::Vec4 &v4) const
osg::Uniform::setElement
bool setElement(unsigned int index, int i0, int i1, int i2)
osg::Uniform::set
bool set(const osg::Matrix3d &m3)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Vec3 &v3)
osg::Uniform::get
bool get(unsigned int &ui0, unsigned int &ui1, unsigned int &ui2, unsigned int &ui3) const
osg::Uniform::getElement
bool getElement(unsigned int index, osg::Matrix4x3 &m4x3) const
osg::Uniform::setElement
bool setElement(unsigned int index, bool b)
osg::Uniform::setArray
bool setArray(FloatArray *array)
osg::Uniform::get
bool get(bool &b) const
osg::Uniform::getUIntArray
const UIntArray * getUIntArray() const
Definition Uniform:898
osg::Uniform::set
bool set(int i)
osg::Uniform::setElement
bool setElement(unsigned int index, const osg::Matrix3x2d &m3x2)
osg::Vec2d
Definition Vec2d:29
osg::Vec3d
Definition Vec3d:30
osg::Vec4d
Definition Vec4d:29
osg::ref_ptr
Definition ref_ptr:32
osg
Definition AlphaFunc:19
osg::UIntArray
TemplateIndexArray< GLuint, Array::UIntArrayType, 1, GL_UNSIGNED_INT > UIntArray
Definition Array:419
osg::Matrix3x2
Matrix3x2Template< float > Matrix3x2
Definition Uniform:389
osg::Matrix2
Matrix2Template< float > Matrix2
Definition Uniform:385
osg::Matrix2x4d
Matrix2x4Template< double > Matrix2x4d
Definition Uniform:399
osg::Vec2
Vec2f Vec2
Definition Vec2:21
osg::Matrix2d
Matrix2Template< double > Matrix2d
Definition Uniform:397
osg::Matrix3d
Matrix3Template< double > Matrix3d
Definition Uniform:402
osg::Vec3
Vec3f Vec3
Definition Vec3:21
osg::FloatArray
TemplateArray< GLfloat, Array::FloatArrayType, 1, GL_FLOAT > FloatArray
Definition Array:421
osg::Matrix2x4
Matrix2x4Template< float > Matrix2x4
Definition Uniform:387
osg::Matrix4x3d
Matrix4x3Template< double > Matrix4x3d
Definition Uniform:406
osg::Matrix2x3
Matrix2x3Template< float > Matrix2x3
Definition Uniform:386
osg::DoubleArray
TemplateArray< GLdouble, Array::DoubleArrayType, 1, GL_DOUBLE > DoubleArray
Definition Array:422
osg::Matrix3x2d
Matrix3x2Template< double > Matrix3x2d
Definition Uniform:401
osg::Matrix4x3
Matrix4x3Template< float > Matrix4x3
Definition Uniform:394
osg::Matrix3x4
Matrix3x4Template< float > Matrix3x4
Definition Uniform:391
osg::Matrix2x3d
Matrix2x3Template< double > Matrix2x3d
Definition Uniform:398
osg::Matrix4x2d
Matrix4x2Template< double > Matrix4x2d
Definition Uniform:405
osg::Vec4
Vec4f Vec4
Definition Vec4:21
osg::Matrix3
Matrix3Template< float > Matrix3
Definition Uniform:390
osg::UInt64Array
TemplateIndexArray< GLuint64, Array::UInt64ArrayType, 1, GL_UNSIGNED_INT64_ARB > UInt64Array
Definition Array:461
osg::Matrix3x4d
Matrix3x4Template< double > Matrix3x4d
Definition Uniform:403
osg::Matrix4x2
Matrix4x2Template< float > Matrix4x2
Definition Uniform:393
osg::Int64Array
TemplateIndexArray< GLint64, Array::Int64ArrayType, 1, GL_INT64_ARB > Int64Array
Definition Array:462
osg::IntArray
TemplateIndexArray< GLint, Array::IntArrayType, 1, GL_INT > IntArray
Definition Array:415
OSG_EXPORT
#define OSG_EXPORT
Definition osg/Export:39
ref_ptr