namespace fs = std::filesystem;

class MDL
{
public:
	MDL(fs::path mdlPath);
	void ToObj();

private:
	fs::path m_path;
	std::ifstream m_file;
	std::streamoff m_fileBeg;
	std::streamoff m_vcolorDataPos;

	std::string m_name;
	std::string m_outputPath;

	MDLHeader m_header;
	std::vector<Mesh> m_meshList;
	std::vector<Anim> m_animList;

	inline void FileSeekRelative(std::streamoff offset = 0);
	inline void FileSeekAbsolute(std::streamoff position);
	std::streamoff ReadHeader();
	std::streamoff LoadMeshes();
	std::streamoff LoadAnims();
};