#pragma once #include #include #include #include namespace glrage { namespace cif { class Texture : public gl::Texture { public: static const uint32_t TRANS_MAP_DIM = 32; static const uint32_t TRANS_TEX_DIM = 1024; static const uint32_t TRANS_MAP_FACTOR = 32; Texture(); ~Texture(); void load(C3D_PTMAP tmap, std::vector& palette); C3D_COLOR& chromaKey(); bool keyOnAlpha(); bool isTranslucent(); std::vector& translucencyMap(); private: C3D_COLOR m_chromaKey = {0, 0, 0, 0}; bool m_keyOnAlpha = false; std::vector m_translucency_map; bool m_is_translucent = false; }; } // namespace cif } // namespace glrage