MeVisLabToolboxReference
MeVisLab/Standard/Sources/Inventor/SoShader/Inventor/nodes/SoVertexAttributeNodes.h
Go to the documentation of this file.
00001 // **InsertLicense** code
00002 
00006 
00007 #ifndef  _SO_VERTEX_ATTRIBUTE_NODES_
00008 #define  _SO_VERTEX_ATTRIBUTE_NODES_
00009 
00010 #include "SoShaderSystem.h"
00011 #include <Inventor/nodes/SoSubNode.h>
00012 #include <Inventor/elements/SoGLVertexAttributeElement.h>
00013 #include <Inventor/fields/SoSFString.h>
00014 #include <Inventor/fields/SoSFBool.h>
00015 #include <Inventor/fields/SoMFFloat.h>
00016 #include <Inventor/fields/SoMFVec2f.h>
00017 #include <Inventor/fields/SoMFVec3f.h>
00018 #include <Inventor/fields/SoMFVec4f.h>
00019 #include <Inventor/fields/SoMFUInt32.h>
00020 #include <Inventor/fields/SoMFInt32.h>
00021 
00023 class INVENTOR_SHADER_API SoVertexAttributeBase : public SoNode
00024 {
00025    typedef SoNode inherited;
00026 
00027    SO_NODE_HEADER(SoVertexAttributeBase);
00028 
00029    public:
00030       SoSFString name;
00031 
00033       SoVertexAttributeBase();
00034   
00035    SoINTERNAL public:
00037       static void initClass();
00038 
00039       virtual void GLRender(SoGLRenderAction *action);
00040 
00041    protected:
00042      virtual void updateInfo() {};
00043 
00044      SoVertexAttributeInfo _info;
00045 };
00046 
00047 //--------------------------------------------------------------------------
00049 class INVENTOR_SHADER_API SoVertexAttribute1f : public SoVertexAttributeBase
00050 {
00051   typedef SoVertexAttributeBase inherited;
00052 
00053   SO_NODE_HEADER(SoVertexAttribute1f);
00054 
00055 public:
00056   SoMFFloat values;
00057 
00059   SoVertexAttribute1f();
00060 
00061   SoINTERNAL public:
00063   static void initClass();
00064 
00065 protected:
00066   virtual void updateInfo();
00067 };
00068 
00069 //--------------------------------------------------------------------------
00071 class INVENTOR_SHADER_API SoVertexAttribute2f : public SoVertexAttributeBase
00072 {
00073   typedef SoVertexAttributeBase inherited;
00074 
00075   SO_NODE_HEADER(SoVertexAttribute2f);
00076 
00077 public:
00078   SoMFVec2f values;
00079 
00081   SoVertexAttribute2f();
00082 
00083   SoINTERNAL public:
00085   static void initClass();
00086 
00087 protected:
00088   virtual void updateInfo();
00089 };
00090 
00091 //--------------------------------------------------------------------------
00093 class INVENTOR_SHADER_API SoVertexAttribute3f : public SoVertexAttributeBase
00094 {
00095   typedef SoVertexAttributeBase inherited;
00096 
00097   SO_NODE_HEADER(SoVertexAttribute3f);
00098 
00099 public:
00100   SoMFVec3f values;
00101 
00103   SoVertexAttribute3f();
00104 
00105   SoINTERNAL public:
00107   static void initClass();
00108 
00109 protected:
00110   virtual void updateInfo();
00111 };
00112 
00113 //--------------------------------------------------------------------------
00115 class INVENTOR_SHADER_API SoVertexAttribute4f : public SoVertexAttributeBase
00116 {
00117   typedef SoVertexAttributeBase inherited;
00118 
00119   SO_NODE_HEADER(SoVertexAttribute4f);
00120 
00121 public:
00122   SoMFVec4f values;
00123 
00125   SoVertexAttribute4f();
00126 
00127   SoINTERNAL public:
00129   static void initClass();
00130 
00131 protected:
00132   virtual void updateInfo();
00133 };
00134 
00135 //--------------------------------------------------------------------------
00137 class INVENTOR_SHADER_API SoVertexAttribute1ui : public SoVertexAttributeBase
00138 {
00139   typedef SoVertexAttributeBase inherited;
00140 
00141   SO_NODE_HEADER(SoVertexAttribute1ui);
00142 
00143 public:
00144   SoMFUInt32 values;
00145   SoSFBool   normalized;
00146 
00148   SoVertexAttribute1ui();
00149 
00150   SoINTERNAL public:
00152   static void initClass();
00153 
00154 protected:
00155   virtual void updateInfo();
00156 };
00157 
00158 //--------------------------------------------------------------------------
00160 class INVENTOR_SHADER_API SoVertexAttribute1i : public SoVertexAttributeBase
00161 {
00162   typedef SoVertexAttributeBase inherited;
00163 
00164   SO_NODE_HEADER(SoVertexAttribute1i);
00165 
00166 public:
00167   SoMFInt32 values;
00168   SoSFBool   normalized;
00169 
00171   SoVertexAttribute1i();
00172 
00173   SoINTERNAL public:
00175   static void initClass();
00176 
00177 protected:
00178   virtual void updateInfo();
00179 };
00180 
00181 //--------------------------------------------------------------------------
00187 class INVENTOR_SHADER_API SoVertexAttribute4ub : public SoVertexAttributeBase
00188 {
00189   typedef SoVertexAttributeBase inherited;
00190 
00191   SO_NODE_HEADER(SoVertexAttribute4ub);
00192 
00193 public:
00194   SoMFUInt32 values;
00195   SoSFBool   normalized;
00196 
00198   SoVertexAttribute4ub();
00199 
00200   SoINTERNAL public:
00202   static void initClass();
00203 
00204 protected:
00205   virtual void updateInfo();
00206 };
00207 
00208 #endif