mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-12-09 01:07:43 +00:00
Huge compile performance refactor
This commit is contained in:
@@ -1,21 +1,19 @@
|
||||
#ifndef _DNACOMMON_CMDL_HPP_
|
||||
#define _DNACOMMON_CMDL_HPP_
|
||||
|
||||
#include <athena/FileWriter.hpp>
|
||||
#include <hecl/Frontend.hpp>
|
||||
#include <hecl/Backend/GX.hpp>
|
||||
#include "athena/FileWriter.hpp"
|
||||
#include "hecl/Frontend.hpp"
|
||||
#include "hecl/Backend/GX.hpp"
|
||||
#include "PAK.hpp"
|
||||
#include "hecl/Blender/BlenderConnection.hpp"
|
||||
#include "GX.hpp"
|
||||
#include "TXTR.hpp"
|
||||
#include "zeus/CAABox.hpp"
|
||||
|
||||
namespace DataSpec
|
||||
{
|
||||
namespace DNACMDL
|
||||
namespace DataSpec::DNACMDL
|
||||
{
|
||||
|
||||
using Mesh = hecl::BlenderConnection::DataStream::Mesh;
|
||||
using Mesh = hecl::blender::Mesh;
|
||||
using Material = hecl::blender::Material;
|
||||
|
||||
struct Header : BigDNA
|
||||
{
|
||||
@@ -117,27 +115,27 @@ void GetVertexAttributes(const MaterialSet& matSet,
|
||||
std::vector<VertexAttributes>& attributesOut);
|
||||
|
||||
template <class PAKRouter, class MaterialSet>
|
||||
void ReadMaterialSetToBlender_1_2(hecl::BlenderConnection::PyOutStream& os,
|
||||
void ReadMaterialSetToBlender_1_2(hecl::blender::PyOutStream& os,
|
||||
const MaterialSet& matSet,
|
||||
const PAKRouter& pakRouter,
|
||||
const typename PAKRouter::EntryType& entry,
|
||||
unsigned setIdx);
|
||||
|
||||
template <class PAKRouter, class MaterialSet>
|
||||
void ReadMaterialSetToBlender_3(hecl::BlenderConnection::PyOutStream& os,
|
||||
void ReadMaterialSetToBlender_3(hecl::blender::PyOutStream& os,
|
||||
const MaterialSet& matSet,
|
||||
const PAKRouter& pakRouter,
|
||||
const typename PAKRouter::EntryType& entry,
|
||||
unsigned setIdx);
|
||||
|
||||
void InitGeomBlenderContext(hecl::BlenderConnection::PyOutStream& os,
|
||||
void InitGeomBlenderContext(hecl::blender::PyOutStream& os,
|
||||
const hecl::ProjectPath& masterShaderPath,
|
||||
bool solidShading);
|
||||
void FinishBlenderMesh(hecl::BlenderConnection::PyOutStream& os,
|
||||
void FinishBlenderMesh(hecl::blender::PyOutStream& os,
|
||||
unsigned matSetCount, int meshIdx);
|
||||
|
||||
template <class PAKRouter, class MaterialSet, class RigPair, class SurfaceHeader>
|
||||
atUint32 ReadGeomSectionsToBlender(hecl::BlenderConnection::PyOutStream& os,
|
||||
atUint32 ReadGeomSectionsToBlender(hecl::blender::PyOutStream& os,
|
||||
athena::io::IStreamReader& reader,
|
||||
PAKRouter& pakRouter,
|
||||
const typename PAKRouter::EntryType& entry,
|
||||
@@ -152,7 +150,7 @@ atUint32 ReadGeomSectionsToBlender(hecl::BlenderConnection::PyOutStream& os,
|
||||
atUint32 surfaceCount=0);
|
||||
|
||||
template <class PAKRouter, class MaterialSet, class RigPair, class SurfaceHeader, atUint32 Version>
|
||||
bool ReadCMDLToBlender(hecl::BlenderConnection& conn,
|
||||
bool ReadCMDLToBlender(hecl::blender::Connection& conn,
|
||||
athena::io::IStreamReader& reader,
|
||||
PAKRouter& pakRouter,
|
||||
const typename PAKRouter::EntryType& entry,
|
||||
@@ -170,7 +168,7 @@ bool WriteCMDL(const hecl::ProjectPath& outPath, const hecl::ProjectPath& inPath
|
||||
|
||||
template <class MaterialSet, class SurfaceHeader, atUint32 Version>
|
||||
bool WriteHMDLCMDL(const hecl::ProjectPath& outPath, const hecl::ProjectPath& inPath,
|
||||
const Mesh& mesh, hecl::PoolSkinIndex& poolSkinIndex);
|
||||
const Mesh& mesh, hecl::blender::PoolSkinIndex& poolSkinIndex);
|
||||
|
||||
template <class MaterialSet, class SurfaceHeader, class MeshHeader>
|
||||
bool WriteMREASecs(std::vector<std::vector<uint8_t>>& secsOut, const hecl::ProjectPath& inPath,
|
||||
@@ -181,6 +179,5 @@ bool WriteHMDLMREASecs(std::vector<std::vector<uint8_t>>& secsOut, const hecl::P
|
||||
const std::vector<Mesh>& meshes, zeus::CAABox& fullAABB, std::vector<zeus::CAABox>& meshAABBs);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
#endif // _DNACOMMON_CMDL_HPP_
|
||||
|
||||
Reference in New Issue
Block a user