2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-10 01:07:43 +00:00

MP2 PATH support

This commit is contained in:
Jack Andersen
2020-04-08 19:19:50 -10:00
parent 5b0a4b5f60
commit df229671c4
12 changed files with 181 additions and 115 deletions

View File

@@ -8,6 +8,7 @@
namespace DataSpec {
namespace DNAPATH {
template <atUint32 PathVer>
struct PATH;
}
@@ -43,13 +44,15 @@ struct AROTBuilder {
void writeColNodes(uint8_t*& ptr, const zeus::CAABox& curAABB);
void pathCountNodesAndLookups(size_t& nodeCount, size_t& lookupCount);
void pathWrite(DNAPATH::PATH& path, const zeus::CAABox& curAABB);
template <uint32_t PathVer>
void pathWrite(DNAPATH::PATH<PathVer>& path, const zeus::CAABox& curAABB);
} rootNode;
void build(std::vector<std::vector<uint8_t>>& secs, const zeus::CAABox& fullAabb,
const std::vector<zeus::CAABox>& meshAabbs, const std::vector<DNACMDL::Mesh>& meshes);
std::pair<std::unique_ptr<uint8_t[]>, uint32_t> buildCol(const ColMesh& mesh, BspNodeType& rootOut);
void buildPath(DNAPATH::PATH& path);
template <uint32_t PathVer>
void buildPath(DNAPATH::PATH<PathVer>& path);
};
} // namespace DataSpec