-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b2e1452
commit 97d2ee5
Showing
23 changed files
with
2,453 additions
and
137 deletions.
There are no files selected for viewing
Submodule fragmented
updated
9 files
+3 −0 | .gitmodules | |
+1 −0 | 3rd_party/spike | |
+3 −0 | README.md | |
+39 −0 | chicken/CMakeLists.txt | |
+95 −0 | chicken/mh2_extract.cpp | |
+70 −0 | chicken/mh3_extract.cpp | |
+6 −5 | psarc/extract_psarc.cpp | |
+20 −0 | trapt/CMakeLists.txt | |
+263 −0 | trapt/sai_to_gltf.cpp |
Submodule spike
updated
6 files
+5 −5 | README.md | |
+35 −7 | include/spike/app_context.hpp | |
+2 −2 | include/spike/gpu/BlockDecoder.h | |
+3 −3 | include/spike/gpu/BlockDecoder.inl | |
+2 −2 | include/spike/io/fileinfo.hpp | |
+487 −98 | src/app/texel.cpp |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
/* InsomniaLib | ||
Copyright(C) 2021-2024 Lukas Cone | ||
This program is free software : you can redistribute it and / or modify | ||
it under the terms of the GNU General Public License as published by | ||
the Free Software Foundation, either version 3 of the License, or | ||
(at your option) any later version. | ||
This program is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.See the | ||
GNU General Public License for more details. | ||
You should have received a copy of the GNU General Public License | ||
along with this program.If not, see <https://www.gnu.org/licenses/>. | ||
*/ | ||
|
||
#pragma once | ||
#include "insomnia/internal/base.hpp" | ||
#include "spike/type/matrix44.hpp" | ||
|
||
struct FoliageBranchLod { | ||
uint32 indexOffset; | ||
uint16 numIndices; | ||
uint16 unk; | ||
}; | ||
|
||
struct SpriteLodRange { | ||
uint32 indexBegin; | ||
uint32 indexEnd; | ||
uint32 unk0; | ||
float unk1; | ||
}; | ||
|
||
struct SpriteRange { | ||
uint16 indexBegin; | ||
uint16 indexEnd; | ||
uint16 positionsOffset; | ||
uint16 numSprites; | ||
}; | ||
|
||
struct Foliage : CoreClass { | ||
static constexpr uint32 ID = 0xc200; | ||
uint32 unk0; | ||
uint16 unk4; | ||
uint16 unk6; | ||
uint32 textureIndex; | ||
uint32 unk5; | ||
uint32 indexOffset; | ||
uint32 null0; | ||
uint32 branchVertexOffset; | ||
uint32 unk1; | ||
FoliageBranchLod branchLods[4]; | ||
uint32 spriteVertexOffset; | ||
uint32 usedSpriteLods; | ||
SpriteLodRange spriteLodRanges[6]; | ||
float unk2[4]; | ||
es::PointerX86<float> spritePositions; | ||
uint32 usedSpriteRanges; | ||
SpriteRange spriteRanges[8]; | ||
float unk3[8]; | ||
}; | ||
|
||
struct FoliageInstance : CoreClass { | ||
static constexpr uint32 ID = 0x9700; | ||
|
||
es::Matrix44 tm; | ||
float unk0[33]; | ||
es::PointerX86<Foliage> foliage; | ||
uint32 unk1[2]; | ||
uint32 unk[4]; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
/* InsomniaLib | ||
Copyright(C) 2021-2024 Lukas Cone | ||
This program is free software : you can redistribute it and / or modify | ||
it under the terms of the GNU General Public License as published by | ||
the Free Software Foundation, either version 3 of the License, or | ||
(at your option) any later version. | ||
This program is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.See the | ||
GNU General Public License for more details. | ||
You should have received a copy of the GNU General Public License | ||
along with this program.If not, see <https://www.gnu.org/licenses/>. | ||
*/ | ||
|
||
#pragma once | ||
#include "insomnia/internal/base.hpp" | ||
#include <span> | ||
|
||
struct PlantPrimitive : CoreClass { | ||
static constexpr uint32 ID = 0xC700; | ||
|
||
uint32 vertexBufferOffset; | ||
uint32 indexOffset; | ||
uint32 numIndices; | ||
uint32 unk0; | ||
float unk1[4]; | ||
uint16 materialIndex; | ||
uint32 unk2[3]; | ||
}; | ||
|
||
|
||
struct PlantClusterInstance { | ||
es::Matrix44 tm; | ||
uint32 unk0[2]; | ||
uint32 unk1; | ||
uint32 unk2; | ||
}; | ||
|
||
struct PlantClusters : CoreClass { | ||
static constexpr uint32 ID = 0xC650; | ||
|
||
uint32 unk0; | ||
uint32 unkOffset; | ||
uint32 numInstances; | ||
uint32 instancesOffset; | ||
uint32 unk4; | ||
uint32 unk5; | ||
uint32 null0[2]; | ||
float unk6[3]; | ||
uint32 unk7; | ||
uint32 null1[20]; | ||
uint32 unk8[12]; | ||
|
||
std::span<PlantClusterInstance> Instances() { | ||
return {reinterpret_cast<PlantClusterInstance *>(reinterpret_cast<char *>(this) + | ||
instancesOffset), | ||
numInstances}; | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.