feat: add model / texture cooking

This commit is contained in:
2026-10-13 00:28:34 +02:00
parent 38230f5092
commit 0273340e3b
6 changed files with 249 additions and 21 deletions
+28
View File
@@ -0,0 +1,28 @@
#pragma once
#include <filesystem>
#include <destrum/Util/ModelDoc.h>
namespace fs = std::filesystem;
class ModelCooker
{
public:
struct Options
{
fs::path inputRoot;
};
explicit ModelCooker(Options opt);
bool CookFileIfNeeded(const fs::path& source, const fs::path& output) const;
static fs::path MakeOutputPath(const fs::path& dstLikeSrc);
private:
Options m_opt;
static bool NeedsRebuild(const fs::path& source, const fs::path& output);
void MakePathsPortable(ModelDoc::ModelAsset& model, const fs::path& source) const;
};