Editable tile8 layout captured from an object's draw trace. More...
#include <object_tile_editor.h>
Classes | |
| struct | Cell |
Public Member Functions | |
| Cell * | FindCell (int rel_x, int rel_y) |
| const Cell * | FindCell (int rel_x, int rel_y) const |
| bool | HasModifications () const |
| void | RevertAll () |
Static Public Member Functions | |
| static ObjectTileLayout | FromTraces (const std::vector< ObjectDrawer::TileTrace > &traces) |
Public Attributes | |
| int16_t | object_id = 0 |
| int | origin_tile_x = 0 |
| int | origin_tile_y = 0 |
| std::vector< Cell > | cells |
| int | bounds_width = 0 |
| int | bounds_height = 0 |
| int | tile_data_address = -1 |
| std::optional< ObjectTileSourceProvenance > | source_provenance |
| bool | is_custom = false |
| int | custom_subtype = -1 |
| std::string | custom_filename |
| std::filesystem::path | custom_resolved_path |
| std::vector< uint8_t > | custom_source_bytes |
Editable tile8 layout captured from an object's draw trace.
Built by running an object draw in trace_only mode and normalizing the resulting TileTrace entries into a 0-based coordinate grid.
Definition at line 101 of file object_tile_editor.h.
|
static |
Definition at line 97 of file object_tile_editor.cc.
References bounds_height, bounds_width, cells, yaze::zelda3::ObjectTileLayout::Cell::modified, object_id, origin_tile_x, origin_tile_y, yaze::zelda3::ObjectTileLayout::Cell::original_word, yaze::zelda3::ObjectTileLayout::Cell::rel_x, yaze::zelda3::ObjectTileLayout::Cell::rel_y, yaze::zelda3::ObjectTileLayout::Cell::tile_info, yaze::gfx::TileInfoToWord(), and yaze::zelda3::ObjectTileLayout::Cell::write_index.
Referenced by yaze::zelda3::ObjectTileEditor::CaptureObjectLayout().

| ObjectTileLayout::Cell * yaze::zelda3::ObjectTileLayout::FindCell | ( | int | rel_x, |
| int | rel_y ) |
Definition at line 164 of file object_tile_editor.cc.
References cells.
| const ObjectTileLayout::Cell * yaze::zelda3::ObjectTileLayout::FindCell | ( | int | rel_x, |
| int | rel_y ) const |
Definition at line 172 of file object_tile_editor.cc.
References cells.
| bool yaze::zelda3::ObjectTileLayout::HasModifications | ( | ) | const |
Definition at line 181 of file object_tile_editor.cc.
References cells.
Referenced by yaze::editor::ObjectTileEditorPanel::HasUnappliedChanges(), yaze::editor::ObjectTileEditorPanel::OnClose(), yaze::editor::ObjectTileEditorPanel::OpenForCustomObject(), yaze::editor::ObjectTileEditorPanel::OpenForObject(), yaze::editor::ObjectTileEditorPanel::RequestSafeWindowClose(), and yaze::zelda3::ObjectTileEditor::WriteBack().
| void yaze::zelda3::ObjectTileLayout::RevertAll | ( | ) |
Definition at line 189 of file object_tile_editor.cc.
References cells, yaze::zelda3::ObjectTileLayout::Cell::tile_info, and yaze::gfx::WordToTileInfo().
Referenced by yaze::editor::ObjectTileEditorPanel::RevertCurrentLayout().

| int16_t yaze::zelda3::ObjectTileLayout::object_id = 0 |
Definition at line 102 of file object_tile_editor.h.
Referenced by yaze::editor::ObjectTileEditorPanel::AnalyzeSourceImpactSnapshot(), yaze::editor::ObjectTileEditorPanel::BuildSourceImpactProvenanceFingerprint(), yaze::zelda3::ObjectTileEditor::BuildStandardWritePlan(), yaze::zelda3::ObjectTileEditor::CaptureEditableObjectLayout(), FromTraces(), yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout(), yaze::zelda3::ObjectTileEditor::RenderLayoutToBitmap(), yaze::editor::ObjectTileEditorPanel::RenderTile8Atlas(), and yaze::zelda3::ObjectTileEditor::WriteBack().
| int yaze::zelda3::ObjectTileLayout::origin_tile_x = 0 |
Definition at line 103 of file object_tile_editor.h.
Referenced by FromTraces(), and yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout().
| int yaze::zelda3::ObjectTileLayout::origin_tile_y = 0 |
Definition at line 104 of file object_tile_editor.h.
Referenced by FromTraces(), and yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout().
| std::vector<Cell> yaze::zelda3::ObjectTileLayout::cells |
Definition at line 119 of file object_tile_editor.h.
Referenced by yaze::editor::ObjectTileEditorPanel::AddFirstTileToEmptyCustomLayout(), yaze::editor::ObjectTileEditorPanel::ApplyChanges(), yaze::editor::ObjectTileEditorPanel::BuildSourceImpactProvenanceFingerprint(), yaze::zelda3::ObjectTileEditor::BuildStandardWritePlan(), yaze::zelda3::ObjectTileEditor::CaptureEditableObjectLayout(), yaze::editor::ObjectTileEditorPanel::Draw(), yaze::editor::ObjectTileEditorPanel::DrawActionBar(), yaze::editor::ObjectTileEditorPanel::DrawSourceSheet(), yaze::editor::ObjectTileEditorPanel::DrawTileGrid(), yaze::editor::ObjectTileEditorPanel::DrawTileProperties(), FindCell(), FindCell(), FromTraces(), yaze::editor::ObjectTileEditorPanel::HandleKeyboardShortcuts(), HasModifications(), yaze::editor::ObjectTileEditorPanel::HasRenderableRoomContext(), yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout(), yaze::zelda3::ObjectTileEditor::RenderLayoutToBitmap(), RevertAll(), yaze::editor::ObjectTileEditorPanel::RevertCurrentLayout(), yaze::editor::ObjectTileEditorPanel::SelectFirstCellIfAvailable(), yaze::editor::ObjectTileEditorPanel::SyncSourceAttributesFromSelectedCell(), yaze::editor::ObjectTileEditorPanel::SyncSourceSelectionFromSelectedCell(), and yaze::zelda3::ObjectTileEditor::WriteBack().
| int yaze::zelda3::ObjectTileLayout::bounds_width = 0 |
Definition at line 120 of file object_tile_editor.h.
Referenced by yaze::editor::ObjectTileEditorPanel::AddFirstTileToEmptyCustomLayout(), yaze::editor::ObjectTileEditorPanel::BuildSourceImpactProvenanceFingerprint(), yaze::zelda3::ObjectTileEditor::BuildStandardWritePlan(), yaze::zelda3::ObjectTileEditor::CaptureEditableObjectLayout(), yaze::editor::ObjectTileEditorPanel::DrawTileGrid(), FromTraces(), yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout(), yaze::zelda3::ObjectTileEditor::RenderLayoutToBitmap(), and yaze::editor::ObjectTileEditorPanel::RevertCurrentLayout().
| int yaze::zelda3::ObjectTileLayout::bounds_height = 0 |
Definition at line 121 of file object_tile_editor.h.
Referenced by yaze::editor::ObjectTileEditorPanel::AddFirstTileToEmptyCustomLayout(), yaze::editor::ObjectTileEditorPanel::BuildSourceImpactProvenanceFingerprint(), yaze::zelda3::ObjectTileEditor::BuildStandardWritePlan(), yaze::zelda3::ObjectTileEditor::CaptureEditableObjectLayout(), yaze::editor::ObjectTileEditorPanel::DrawTileGrid(), FromTraces(), yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout(), yaze::zelda3::ObjectTileEditor::RenderLayoutToBitmap(), and yaze::editor::ObjectTileEditorPanel::RevertCurrentLayout().
| int yaze::zelda3::ObjectTileLayout::tile_data_address = -1 |
Definition at line 125 of file object_tile_editor.h.
Referenced by yaze::editor::ObjectTileEditorPanel::BuildSourceImpactProvenanceFingerprint(), yaze::zelda3::ObjectTileEditor::CaptureEditableObjectLayout(), yaze::zelda3::ObjectTileEditor::CaptureObjectLayout(), and yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout().
| std::optional<ObjectTileSourceProvenance> yaze::zelda3::ObjectTileLayout::source_provenance |
Definition at line 126 of file object_tile_editor.h.
Referenced by yaze::zelda3::ObjectTileEditor::AnalyzeStandardTileSourceImpact(), yaze::editor::ObjectTileEditorPanel::ApplyChanges(), yaze::editor::ObjectTileEditorPanel::BuildSourceImpactProvenanceFingerprint(), yaze::zelda3::ObjectTileEditor::BuildStandardWritePlan(), yaze::zelda3::ObjectTileEditor::CaptureEditableObjectLayout(), and yaze::zelda3::ObjectTileEditor::CaptureObjectLayout().
| bool yaze::zelda3::ObjectTileLayout::is_custom = false |
Definition at line 127 of file object_tile_editor.h.
Referenced by yaze::editor::ObjectTileEditorPanel::AddFirstTileToEmptyCustomLayout(), yaze::editor::ObjectTileEditorPanel::AnalyzeSourceImpactSnapshot(), yaze::zelda3::ObjectTileEditor::AnalyzeStandardTileSourceImpact(), yaze::editor::ObjectTileEditorPanel::ApplyChanges(), yaze::editor::ObjectTileEditorPanel::BuildSourceImpactProvenanceFingerprint(), yaze::zelda3::ObjectTileEditor::BuildStandardWritePlan(), yaze::editor::ObjectTileEditorPanel::BuildWindowTitle(), yaze::zelda3::ObjectTileEditor::CaptureEditableObjectLayout(), yaze::zelda3::ObjectTileEditor::CaptureObjectLayout(), yaze::editor::ObjectTileEditorPanel::Draw(), yaze::editor::ObjectTileEditorPanel::DrawActionBar(), yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout(), yaze::zelda3::ObjectTileEditor::RenderLayoutToBitmap(), yaze::editor::ObjectTileEditorPanel::RenderTile8Atlas(), yaze::editor::ObjectTileEditorPanel::RevertCurrentLayout(), yaze::editor::ObjectTileEditorPanel::SyncSourceAttributesFromSelectedCell(), yaze::zelda3::ObjectTileEditor::WriteBack(), and yaze::editor::ObjectTileEditorPanel::WriteBackCurrentLayout().
| int yaze::zelda3::ObjectTileLayout::custom_subtype = -1 |
Definition at line 128 of file object_tile_editor.h.
Referenced by yaze::editor::ObjectTileEditorPanel::BuildSourceImpactProvenanceFingerprint(), yaze::editor::ObjectTileEditorPanel::BuildWindowTitle(), yaze::zelda3::ObjectTileEditor::CaptureObjectLayout(), yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout(), and yaze::zelda3::ObjectTileEditor::WriteBack().
| std::string yaze::zelda3::ObjectTileLayout::custom_filename |
| std::filesystem::path yaze::zelda3::ObjectTileLayout::custom_resolved_path |
Definition at line 130 of file object_tile_editor.h.
Referenced by yaze::editor::ObjectTileEditorPanel::AnalyzeSourceImpactSnapshot(), yaze::editor::ObjectTileEditorPanel::BuildSourceImpactProvenanceFingerprint(), yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout(), and yaze::zelda3::ObjectTileEditor::WriteBack().
| std::vector<uint8_t> yaze::zelda3::ObjectTileLayout::custom_source_bytes |
Definition at line 131 of file object_tile_editor.h.
Referenced by yaze::zelda3::ObjectTileEditor::LoadCustomObjectLayout(), yaze::editor::ObjectTileEditorPanel::RevertCurrentLayout(), and yaze::zelda3::ObjectTileEditor::WriteBack().