#ifndef __H_PROGRAMMANAGER_H__ #define __H_PROGRAMMANAGER_H__ #include #include "Singleton.h" #include "renderer/VertexProgram.h" typedef STL_HASH_MAP pp_map; #define g_ProgramManager CProgramManager::GetSingleton() class CProgramManager : public Singleton { public: CProgramManager(); ~CProgramManager(); CVertexProgram *FindVertexProgram(const char *file); void Bind(CVertexProgram *prog); void WritePPInfo(FILE *file); #ifdef BUILD_CG CGcontext GetContext() { return m_Context; } #endif private: #ifdef BUILD_CG void FindPPVersion(); #endif pp_map m_VertexProgs; #ifdef BUILD_CG CGcontext m_Context; CGprofile m_VPProfile; CGprofile m_FPProfile; #endif }; #endif