Torch
Loading...
Searching...
No Matches
OoTLimbFactory.h
1#pragma once
2
3#include "factories/BaseFactory.h"
4#include "OoTSkeletonTypes.h"
5
6namespace OoT {
7
9 ExportResult Export(std::ostream& write, std::shared_ptr<IParsedData> data, std::string& entryName,
10 YAML::Node& node, std::string* replacement) override;
11};
12
14public:
15 std::optional<std::shared_ptr<IParsedData>> parse(std::vector<uint8_t>& buffer, YAML::Node& data) override;
16 std::unordered_map<ExportType, std::shared_ptr<BaseExporter>> GetExporters() override {
17 return {
18 REGISTER(Binary, OoTLimbBinaryExporter)
19 };
20 }
21
22private:
23 static size_t GetLimbDataSize(OoTLimbType type);
24 void ParseLimbHeader(LUS::BinaryReader& reader, OoTLimbData& limb);
25 void ParseCurveLimb(LUS::BinaryReader& reader, OoTLimbData& limb, const std::string& symbol);
26 void ParseLegacyLimb(LUS::BinaryReader& reader, OoTLimbData& limb, const std::string& symbol);
27 void ParseStandardLimb(LUS::BinaryReader& reader, OoTLimbData& limb, const std::string& symbol);
28 void ParseLODLimb(LUS::BinaryReader& reader, OoTLimbData& limb, const std::string& symbol);
29 void ParseSkinLimb(LUS::BinaryReader& reader, std::vector<uint8_t>& buffer,
30 OoTLimbData& limb, const std::string& symbol);
31 void ParseAnimatedSkinData(std::vector<uint8_t>& buffer, uint32_t skinSegmentAddr,
32 OoTLimbData& limb, const std::string& symbol);
33 void ParseSkinVertices(std::vector<uint8_t>& buffer, uint32_t addr, uint16_t count,
34 std::vector<OoTSkinVertex>& out);
35 void ParseSkinTransformations(std::vector<uint8_t>& buffer, uint32_t addr, uint16_t count,
36 std::vector<OoTSkinTransformation>& out);
37};
38
39} // namespace OoT
Definition BaseFactory.h:96
Definition BaseFactory.h:102
Definition OoTLimbFactory.h:8
Definition OoTSkeletonTypes.h:59
Definition OoTLimbFactory.h:13