00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkGenericVertexAttributeMapping.h 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00027 #ifndef __vtkGenericVertexAttributeMapping_h 00028 #define __vtkGenericVertexAttributeMapping_h 00029 00030 #include "vtkObject.h" 00031 00032 class VTK_RENDERING_EXPORT vtkGenericVertexAttributeMapping : public vtkObject 00033 { 00034 public: 00035 static vtkGenericVertexAttributeMapping* New(); 00036 vtkTypeMacro(vtkGenericVertexAttributeMapping, vtkObject); 00037 void PrintSelf(ostream& os, vtkIndent indent); 00038 00040 00043 void AddMapping(const char* attributeName, const char* arrayName, 00044 int fieldAssociation, int component); 00046 00048 00051 void AddMapping( 00052 int unit, const char* arrayName, int fieldAssociation, 00053 int component); 00055 00057 bool RemoveMapping(const char* attributeName); 00058 00060 void RemoveAllMappings(); 00061 00063 unsigned int GetNumberOfMappings(); 00064 00066 const char* GetAttributeName(unsigned int index); 00067 00069 const char* GetArrayName(unsigned int index); 00070 00072 int GetFieldAssociation(unsigned int index); 00073 00075 int GetComponent(unsigned int index); 00076 00078 int GetTextureUnit(unsigned int index); 00079 00080 //BTX 00081 protected: 00082 vtkGenericVertexAttributeMapping(); 00083 ~vtkGenericVertexAttributeMapping(); 00084 00085 private: 00086 vtkGenericVertexAttributeMapping(const vtkGenericVertexAttributeMapping&); // Not implemented. 00087 void operator=(const vtkGenericVertexAttributeMapping&); // Not implemented. 00088 00089 class vtkInternal; 00090 vtkInternal* Internal; 00091 //ETX 00092 }; 00093 00094 #endif 00095 00096