update vcm::parse semantics

This commit is contained in:
MihailRis 2026-01-15 22:57:04 +03:00
parent c34cb57fb8
commit 6760d16052
4 changed files with 55 additions and 51 deletions

View file

@ -2,9 +2,11 @@
#include <memory>
#include <string>
#include <optional>
#include <unordered_map>
#include "graphics/commons/Model.hpp"
#include "objects/rigging.hpp"
namespace rigging {
class SkeletonConfig;
@ -13,14 +15,13 @@ namespace rigging {
namespace vcm {
struct VcmModel {
std::unordered_map<std::string, model::Model> parts;
std::unique_ptr<rigging::SkeletonConfig> skeleton;
std::optional<rigging::SkeletonConfig> skeleton;
model::Model& squash();
model::Model squashed() const;
};
VcmModel parseFull(
std::string_view file, std::string_view src, bool usexml
);
std::unique_ptr<model::Model> parse(
VcmModel parse(
std::string_view file, std::string_view src, bool usexml
);
}