The Socrates Gameboy Advance Development Engine
The SGADE is a development library for the Nintendo Gameboy
Advance. It's free for all uses and is distributed without guarantees.
For more information visit
the SGADE page.
00001 // ---------------------------------------------------------------------------- 00013 // ---------------------------------------------------------------------------- 00014 00015 #ifndef SO_POLYGON_H 00016 #define SO_POLYGON_H 00017 00018 #ifdef __cplusplus 00019 extern "C" { 00020 #endif 00021 00022 00023 // ---------------------------------------------------------------------------- //! @{ 00032 // ---------------------------------------------------------------------------- 00033 00034 00035 // ---------------------------------------------------------------------------- 00036 // Includes 00037 // ---------------------------------------------------------------------------- 00038 #include "SoVector.h" 00039 00040 // ---------------------------------------------------------------------------- 00041 // Defines 00042 // ---------------------------------------------------------------------------- 00043 00052 #define SO_POLYGON_MAX_NUM_VERTICES 8 00053 00054 // ---------------------------------------------------------------------------- 00055 // Typedefs 00056 // ---------------------------------------------------------------------------- 00057 00058 00065 typedef struct 00066 { 00067 u8 m_NumVertices; 00068 u16* m_VertexIndices; 00069 00070 u8 m_PaletteIndex; 00071 SoVector2* m_TextureCoordinates; 00072 00073 } SoPolygon; 00074 00075 // ---------------------------------------------------------------------------- 00076 // Public methods; 00077 // ---------------------------------------------------------------------------- 00078 00079 SoVector2* SoPolygonGetTextureCoordinates( SoPolygon* a_This ); 00080 u32 SoPolygonGetVertexIndex( SoPolygon* a_This, u32 a_Index ); 00081 u32 SoPolygonGetNumVertices( SoPolygon* a_This ); 00082 u32 SoPolygonGetPaletteIndex( SoPolygon* a_This ); 00083 00084 void SoPolygonSetPaletteIndex( SoPolygon* a_This, u32 a_PaletteIndex ); 00085 00086 // ---------------------------------------------------------------------------- 00087 // EOF 00088 // ---------------------------------------------------------------------------- 00089 00091 00092 #ifdef __cplusplus 00093 } // extern "C" 00094 #endif 00095 00096 #endif