xsi_triangle.h
Go to the documentation of this file.
00001 //*****************************************************************************
00011 //*****************************************************************************
00012 
00013 #if (_MSC_VER > 1000) || defined(SGI_COMPILER)
00014 #pragma once
00015 #endif
00016 
00017 #ifndef __XSITRIANGLE_H__
00018 #define __XSITRIANGLE_H__
00019 
00020 #include <xsi_siobject.h>
00021 #include <xsi_math.h>
00022 #include <xsi_vertexcolor.h>
00023 #include <xsi_uv.h>
00024 #include <xsi_longarray.h>
00025 
00026 namespace XSI {
00027 
00028 class CTriangleRefArray;
00029 class CTriangleVertexRefArray;
00030 
00031 //*****************************************************************************
00082 //*****************************************************************************
00083 
00084 class SICPPSDKDECL Triangle : public SIObject
00085 {
00086 public:
00088     Triangle();
00089 
00091     ~Triangle();
00092 
00096     Triangle(const CRef& in_ref);
00097 
00101     Triangle(const Triangle& in_obj);
00102 
00107     bool IsA( siClassID in_ClassID) const;
00108 
00112     siClassID GetClassID() const;
00113 
00119     Triangle& operator=(const Triangle& in_obj);
00120 
00126     Triangle& operator=(const CRef& in_ref);
00127 
00132     CTriangleRefArray GetNeighborTriangles() const;
00133 
00137     CTriangleVertexRefArray GetPoints() const;
00138 
00142     LONG GetIndex() const;
00143 
00147     LONG GetPolygonIndex() const;
00148 
00153     MATH::CVector3Array GetPositionArray() const;
00154 
00159     MATH::CVector3Array GetPolygonNodeNormalArray() const;
00160 
00164     CVertexColorArray GetColorArray() const;
00165 
00169     CUVArray GetUVArray() const;
00170 
00174     CLongArray GetIndexArray() const;
00175 
00176     private:
00177     Triangle * operator&() const;
00178     Triangle * operator&();
00179 };
00180 
00181 //*****************************************************************************
00213 //*****************************************************************************
00214 class SICPPSDKDECL CTriangleRefArray : public CRefArray
00215 {
00216     public:
00217     CTriangleRefArray();
00218 
00222     CTriangleRefArray( const CTriangleRefArray& in_array );
00223 
00228     CRef GetItem( LONG in_index ) const;
00229 
00234     CRef GetItem( const CString& in_name ) const;
00235 
00239     LONG GetCount() const;
00240 
00244     bool IsValid() const;
00245 
00249     MATH::CVector3Array GetPositionArray() const;
00250 
00254     MATH::CVector3Array GetPolygonNodeNormalArray() const;
00255 
00259     CVertexColorArray GetColorArray() const;
00260 
00264     CUVArray GetUVArray() const;
00265 
00269     CLongArray GetIndexArray() const;
00270 
00271     private:
00272     void* m_ptr;
00273 };
00274 
00275 
00276 };
00277 
00278 #endif // __XSITRIANGLE_H__