[graphics] TIE extractor (#1026)

* temp

* temp

* wip

* more progress on the instance asm

* first half of tie extraction, up to dma lists

* more tie extraction

* first part figured out maybe

* bp1 loop seems to work, bp2 loop does not

* bp1 and bp2 appear working. sadly ip is needed

* ip1 outline, not working ip2

* just kidding, ip2 seems to work

* extraction seems to work

* basic rendering working

* tie fixes

* performance optimization of tie renderer

* hook up tie to engine

* fix more bugs

* cleanup and perf improvements

* fix tests

* ref tests

* mm256i for gcc

* CLANG

* windows

* more compile fixes

* fix fast time of day

* small fixes

* fix after merge

* clang
This commit is contained in:
water111
2021-12-26 12:33:51 -05:00
committed by GitHub
parent ff61d32095
commit a8342aef31
71 changed files with 13430 additions and 733 deletions
+7 -2
View File
@@ -3,6 +3,7 @@
#include "extract_level.h"
#include "decompiler/level_extractor/BspHeader.h"
#include "decompiler/level_extractor/extract_tfrag.h"
#include "decompiler/level_extractor/extract_tie.h"
#include "common/util/FileUtil.h"
namespace decompiler {
@@ -91,10 +92,14 @@ void extract_from_level(ObjectFileDB& db,
}
extract_tfrag(as_tfrag_tree, fmt::format("{}-{}", dgo_name, i++),
bsp_header.texture_remap_table, tex_db, expected_missing_textures, tfrag_level);
} else if (draw_tree->my_type() == "drawable-tree-instance-tie") {
fmt::print(" extracting TIE\n");
auto as_tie_tree = dynamic_cast<level_tools::DrawableTreeInstanceTie*>(draw_tree.get());
assert(as_tie_tree);
extract_tie(as_tie_tree, fmt::format("{}-{}-tie", dgo_name, i++),
bsp_header.texture_remap_table, tex_db, tfrag_level);
} else {
fmt::print(" unsupported tree {}\n", draw_tree->my_type());
tfrag_level.trees.emplace_back();
tfrag_level.trees.back().kind = tfrag3::TFragmentTreeKind::INVALID;
}
}