De-bloat anm2 core: templates, tables, unified emitter
- Collapse const/non-const pairs into templates; Anm2::element_get uses deducing this - Drive container/track/item mappings from ANM2_ELEMENT_TYPES, ANM2_ITEM_TYPES and TRACK_CONTAINERS - One sink-based emitter feeds both XML writing and hashing - frame_mix and frame_bake_split replace five copies of the bake/lerp loop - item_add replaces layer_animation_add/null_animation_add - Fix timeline split ignoring shear Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
41ed347925
commit
a9f48bc3a0
23 files changed
+1087
-1978
No files matched your search
+2
-2
@@ -190,7 +190,7 @@ namespace anm2ed::snapshots
|
||||
{
|
||||
auto spritesheet = anm2.element_get(ElementType::SPRITESHEET, spritesheetId);
|
||||
if (!spritesheet) return std::nullopt;
|
||||
auto region = element_child_id_get(*spritesheet, ElementType::REGION, regionId);
|
||||
auto region = child_id_get(*spritesheet, ElementType::REGION, regionId);
|
||||
if (!region) return std::nullopt;
|
||||
|
||||
std::vector<int> path{};
|
||||
@@ -256,7 +256,7 @@ namespace anm2ed::snapshots
|
||||
|
||||
auto spritesheet = snapshot.anm2.element_get(ElementType::SPRITESHEET, spritesheetId);
|
||||
if (!spritesheet) return;
|
||||
auto region = element_child_id_get(*spritesheet, ElementType::REGION, regionId);
|
||||
auto region = child_id_get(*spritesheet, ElementType::REGION, regionId);
|
||||
if (!region) return;
|
||||
|
||||
step.anm2.elements.push_back({std::move(*path), *region, {}});
|
||||
|
||||
Reference in new issue
Block a user