"L. Spiro Engine"
|
00001 00016 #ifndef __LSG_OPENGLESRENDERTARGET_H__ 00017 #define __LSG_OPENGLESRENDERTARGET_H__ 00018 00019 #include "../LSGGraphicsLib.h" 00020 #include "../RenderTarget/LSGRenderTargetBase.h" 00021 00022 #ifdef LSG_OGLES 00023 00024 namespace lsg { 00025 00032 class COpenGlEsRenderTarget : public CRenderTargetBase { 00033 friend class COpenGlEsRenderTargetManager; 00034 public : 00035 // == Various constructors. 00036 LSE_CALLCTOR COpenGlEsRenderTarget(); 00037 LSE_CALLCTOR ~COpenGlEsRenderTarget(); 00038 00039 00040 // == Functions. 00047 virtual LSBOOL LSE_CALL Activate( LSUINT32 _ui32Slot ); 00048 00056 static GLint LSE_CALL GetOpenGlEsInternalFormatRenderTarget( LSG_RENDER_TARGET_FORMAT _rtfFormat, LSBOOL _bStencil = false ); 00057 00065 static GLenum LSE_CALL GetOpenGlEsFormatRenderTarget( LSG_RENDER_TARGET_FORMAT _rtfFormat, LSBOOL _bStencil = false ); 00066 00074 static GLenum LSE_CALL GetOpenGlEsTypeRenderTarget( LSG_RENDER_TARGET_FORMAT _rtfFormat, LSBOOL _bStencil = false ); 00075 00076 protected : 00077 // == Members. 00081 GLuint m_uiColorId; 00082 00083 00084 // == Functions. 00088 LSVOID LSE_CALL ResetApi(); 00089 00096 LSBOOL LSE_CALL CreateApiRenderTarget(); 00097 00104 virtual LSBOOL LSE_CALL SetAsColorRenderTarget( LSUINT32 _ui32Slot ) const; 00105 00109 virtual LSVOID LSE_CALL EndAsRenderTarget() const; 00110 }; 00111 00112 } // namespace lsg 00113 00114 #endif // #ifdef LSG_OGLES 00115 00116 #endif // __LSG_OPENGLESRENDERTARGET_H__