#pragma once #include #include #include #include namespace gc { struct MtxTexture { uint32_t offset = 0; uint32_t size = 0; uint32_t width = 0; uint32_t height = 0; uint32_t bitsPerPixel = 0; uint32_t fourCC = 0; }; struct MtxArchive { std::vector textures; }; bool ParseMtxArchive(const std::vector& bytes, MtxArchive* archive, std::string* error = nullptr); // MTX stores a normal DDS surface with its four-byte magic replaced by an // internal field. This returns the exact embedded surface with "DDS " put // back, suitable for the existing DDS loader or external inspection tools. bool ExtractMtxTextureDds(const std::vector& bytes, const MtxTexture& texture, std::vector* dds, std::string* error = nullptr); } // namespace gc