00001 //*************************************************************************************** 00002 // 00003 // File supervisor: Crosswalk team 00004 // 00005 // Copyright 2008 Autodesk, Inc. All rights reserved. 00006 // Use of this software is subject to the terms of the Autodesk license agreement 00007 // provided at the time of installation or download, or which otherwise accompanies 00008 // this software in either electronic or hard copy form. 00009 // 00010 //*************************************************************************************** 00011 00012 #ifndef _XSIPOLYGONLIST_H 00013 #define _XSIPOLYGONLIST_H 00014 00015 #include "XSISubComponentList.h" 00016 #include "Material.h" 00017 #include "Scene.h" 00018 #include "Model.h" 00019 #include "XSIIndexList.h" 00020 00031 class XSIEXPORT CSLXSIPolygonList 00032 : public CSLXSISubComponentList 00033 { 00034 public: 00038 typedef CSLArrayProxy<SI_Int, SI_Int, 1> CSLIntArray; 00039 00046 CSLXSIPolygonList(CSLScene *in_pScene, CSLModel *in_pModel, CdotXSITemplate *in_pTemplate); 00047 00050 virtual ~CSLXSIPolygonList(); 00051 00055 virtual ETemplateType Type() { return XSI_POLYGON_LIST; } 00056 00060 CSLBaseMaterial* GetMaterial() { return m_pMaterial; } 00061 00065 CSIBCString GetMaterialName(); 00066 00071 SI_Void SetMaterial(CSLBaseMaterial *in_pNewMaterial); 00072 00077 SI_Void SetMaterialName(const CSIBCString& in_szNewMaterialName); 00078 00082 SI_Int GetPolygonCount(); 00083 00087 CSLIntArray* GetPolygonNodeCountArray(); 00088 00092 CSLIntArray* GetVertexIndices(); 00093 00097 SI_Error Synchronize(); 00098 00102 virtual SI_Error SetCount(SI_Int); 00103 00104 //********************************************************************************** 00105 // Index position helper (always only one index position list) 00106 //********************************************************************************** 00107 00111 CSLXSIIndexList* ConnectIndexList( CSLXSIIndexList* in_pNewXSIIndexList ); 00112 00116 virtual CSLXSIIndexList* AddIndexList(); 00117 00121 CSLXSIIndexList* GetIndexList(); 00122 00126 SI_Error RemoveIndexList(); 00127 00128 private: 00129 CSLIntArray m_PolygonNodeCountArray; 00130 00131 CSLIntArray m_VertexIndices; 00132 00133 CSLBaseMaterial* m_pMaterial; 00134 00135 CSIBCString m_szMaterialName; 00136 00137 CSLXSIIndexList * m_IndexList; 00138 00139 void *m_pReserved; // reserved for future extension 00140 }; 00141 00142 #endif