diff --git a/src/app/editor/editor_manager.cc b/src/app/editor/editor_manager.cc index 1420c9f3..12c1ea77 100644 --- a/src/app/editor/editor_manager.cc +++ b/src/app/editor/editor_manager.cc @@ -29,7 +29,7 @@ #include "app/editor/ui/editor_selection_dialog.h" #include "app/emu/emulator.h" #include "app/gfx/arena.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/editor/ui/background_renderer.h" #include "app/gui/icons.h" #include "app/gui/input.h" @@ -53,7 +53,7 @@ #include "app/editor/system/settings_editor.h" #include "app/editor/system/toast_manager.h" #include "app/emu/emulator.h" -#include "app/gfx/performance_dashboard.h" +#include "app/gfx/performance/performance_dashboard.h" #include "editor/editor.h" #ifdef YAZE_WITH_GRPC #include "app/core/service/screenshot_utils.h" diff --git a/src/app/editor/editor_manager.h b/src/app/editor/editor_manager.h index 1ae6e741..5f668146 100644 --- a/src/app/editor/editor_manager.h +++ b/src/app/editor/editor_manager.h @@ -37,7 +37,7 @@ #include "app/editor/ui/editor_selection_dialog.h" #include "app/editor/ui/welcome_screen.h" #include "app/emu/emulator.h" -#include "app/gfx/performance_dashboard.h" +#include "app/gfx/performance/performance_dashboard.h" #include "app/rom.h" #include "yaze_config.h" diff --git a/src/app/editor/graphics/graphics_editor.cc b/src/app/editor/graphics/graphics_editor.cc index 72a557a7..b8915c2d 100644 --- a/src/app/editor/graphics/graphics_editor.cc +++ b/src/app/editor/graphics/graphics_editor.cc @@ -21,7 +21,7 @@ #include "app/gui/modules/asset_browser.h" #include "app/gui/style.h" #include "app/rom.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "imgui/imgui.h" #include "imgui/misc/cpp/imgui_stdlib.h" #include "imgui_memory_editor.h" diff --git a/src/app/editor/graphics/palette_editor.cc b/src/app/editor/graphics/palette_editor.cc index 2c3402c8..5ceeea9e 100644 --- a/src/app/editor/graphics/palette_editor.cc +++ b/src/app/editor/graphics/palette_editor.cc @@ -2,7 +2,7 @@ #include "absl/status/status.h" #include "absl/strings/str_cat.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/snes_palette.h" #include "app/gui/color.h" #include "imgui/imgui.h" diff --git a/src/app/editor/graphics/screen_editor.cc b/src/app/editor/graphics/screen_editor.cc index fa1e4616..8b759b8f 100644 --- a/src/app/editor/graphics/screen_editor.cc +++ b/src/app/editor/graphics/screen_editor.cc @@ -6,13 +6,13 @@ #include "absl/strings/str_format.h" #include "absl/strings/string_view.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "util/file_util.h" #include "app/core/window.h" #include "app/gfx/arena.h" #include "app/gfx/atlas_renderer.h" #include "app/gfx/bitmap.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/snes_tile.h" #include "app/gui/canvas.h" #include "app/gui/color.h" diff --git a/src/app/editor/message/message_editor.cc b/src/app/editor/message/message_editor.cc index e4799464..edcf0788 100644 --- a/src/app/editor/message/message_editor.cc +++ b/src/app/editor/message/message_editor.cc @@ -7,7 +7,7 @@ #include "absl/strings/str_cat.h" #include "absl/strings/str_format.h" #include "app/gfx/arena.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "util/file_util.h" #include "app/gfx/bitmap.h" #include "app/gfx/snes_palette.h" diff --git a/src/app/editor/music/music_editor.cc b/src/app/editor/music/music_editor.cc index 64e834a9..6036ca59 100644 --- a/src/app/editor/music/music_editor.cc +++ b/src/app/editor/music/music_editor.cc @@ -1,7 +1,7 @@ #include "music_editor.h" #include "absl/strings/str_format.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/editor/code/assembly_editor.h" #include "app/emu/emulator.h" #include "app/gui/icons.h" diff --git a/src/app/editor/overworld/map_properties.cc b/src/app/editor/overworld/map_properties.cc index fbe0d200..8c128850 100644 --- a/src/app/editor/overworld/map_properties.cc +++ b/src/app/editor/overworld/map_properties.cc @@ -1,6 +1,6 @@ #include "app/editor/overworld/map_properties.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/editor/overworld/overworld_editor.h" #include "app/editor/overworld/ui_constants.h" #include "app/gui/canvas.h" diff --git a/src/app/editor/overworld/overworld_editor.cc b/src/app/editor/overworld/overworld_editor.cc index 30e6626b..d6fca05e 100644 --- a/src/app/editor/overworld/overworld_editor.cc +++ b/src/app/editor/overworld/overworld_editor.cc @@ -20,7 +20,7 @@ #include "app/gfx/arena.h" #include "app/gfx/bitmap.h" #include "app/gui/widgets/tile_selector_widget.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/snes_palette.h" #include "app/gfx/tilemap.h" #include "app/gui/canvas.h" diff --git a/src/app/editor/overworld/scratch_space.cc b/src/app/editor/overworld/scratch_space.cc index dbebe17e..89bf28e2 100644 --- a/src/app/editor/overworld/scratch_space.cc +++ b/src/app/editor/overworld/scratch_space.cc @@ -12,14 +12,14 @@ #include "absl/strings/str_format.h" #include "app/core/asar_wrapper.h" #include "app/core/features.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/core/window.h" #include "app/editor/overworld/entity.h" #include "app/editor/overworld/map_properties.h" #include "app/editor/overworld/tile16_editor.h" #include "app/gfx/arena.h" #include "app/gfx/bitmap.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/snes_palette.h" #include "app/gfx/tilemap.h" #include "app/gui/canvas.h" diff --git a/src/app/editor/overworld/tile16_editor.cc b/src/app/editor/overworld/tile16_editor.cc index 4fca0de0..3b7cc036 100644 --- a/src/app/editor/overworld/tile16_editor.cc +++ b/src/app/editor/overworld/tile16_editor.cc @@ -6,7 +6,7 @@ #include "app/gfx/arena.h" #include "app/gfx/bitmap.h" #include "app/gfx/backend/irenderer.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/snes_palette.h" #include "app/gui/canvas.h" #include "app/gui/input.h" diff --git a/src/app/editor/sprite/sprite_editor.cc b/src/app/editor/sprite/sprite_editor.cc index 899f407c..4257c10b 100644 --- a/src/app/editor/sprite/sprite_editor.cc +++ b/src/app/editor/sprite/sprite_editor.cc @@ -1,6 +1,6 @@ #include "sprite_editor.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "gui/ui_helpers.h" #include "util/file_util.h" #include "app/editor/sprite/zsprite.h" diff --git a/src/app/editor/system/settings_editor.cc b/src/app/editor/system/settings_editor.cc index 4fb82dbe..21853c05 100644 --- a/src/app/editor/system/settings_editor.cc +++ b/src/app/editor/system/settings_editor.cc @@ -3,7 +3,7 @@ #include "absl/status/status.h" #include "app/gui/feature_flags_menu.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gui/style.h" #include "app/gui/icons.h" #include "app/gui/theme_manager.h" diff --git a/src/app/gfx/atlas_renderer.h b/src/app/gfx/atlas_renderer.h index 5966b904..b78d2aad 100644 --- a/src/app/gfx/atlas_renderer.h +++ b/src/app/gfx/atlas_renderer.h @@ -7,7 +7,7 @@ #include #include "app/gfx/bitmap.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/bpp_format_manager.h" namespace yaze { diff --git a/src/app/gfx/bitmap.cc b/src/app/gfx/bitmap.cc index 5090db3c..9389124c 100644 --- a/src/app/gfx/bitmap.cc +++ b/src/app/gfx/bitmap.cc @@ -8,7 +8,7 @@ #include #include "app/gfx/arena.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/snes_palette.h" #include "util/log.h" diff --git a/src/app/gfx/bpp_format_manager.h b/src/app/gfx/bpp_format_manager.h index bd57f3fb..084269fc 100644 --- a/src/app/gfx/bpp_format_manager.h +++ b/src/app/gfx/bpp_format_manager.h @@ -9,7 +9,7 @@ #include "app/gfx/bitmap.h" #include "app/gfx/snes_palette.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" namespace yaze { namespace gfx { diff --git a/src/app/gfx/gfx_library.cmake b/src/app/gfx/gfx_library.cmake index 95015e0a..8837f34c 100644 --- a/src/app/gfx/gfx_library.cmake +++ b/src/app/gfx/gfx_library.cmake @@ -6,8 +6,8 @@ set( app/gfx/bitmap.cc app/gfx/compression.cc app/gfx/memory_pool.cc - app/gfx/performance_dashboard.cc - app/gfx/performance_profiler.cc + app/gfx/performance/performance_dashboard.cc + app/gfx/performance/performance_profiler.cc app/gfx/scad_format.cc app/gfx/snes_palette.cc app/gfx/snes_tile.cc diff --git a/src/app/gfx/graphics_optimizer.h b/src/app/gfx/graphics_optimizer.h index 18b4c8b6..4c8fc9d0 100644 --- a/src/app/gfx/graphics_optimizer.h +++ b/src/app/gfx/graphics_optimizer.h @@ -6,7 +6,7 @@ #include #include "app/gfx/bpp_format_manager.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" namespace yaze { namespace gfx { diff --git a/src/app/gfx/performance_dashboard.cc b/src/app/gfx/performance/performance_dashboard.cc similarity index 99% rename from src/app/gfx/performance_dashboard.cc rename to src/app/gfx/performance/performance_dashboard.cc index 95460e7c..aae82a58 100644 --- a/src/app/gfx/performance_dashboard.cc +++ b/src/app/gfx/performance/performance_dashboard.cc @@ -1,4 +1,4 @@ -#include "app/gfx/performance_dashboard.h" +#include "app/gfx/performance/performance_dashboard.h" #include #include @@ -6,7 +6,7 @@ #include "app/gfx/atlas_renderer.h" #include "app/gfx/memory_pool.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "imgui/imgui.h" namespace yaze { diff --git a/src/app/gfx/performance_dashboard.h b/src/app/gfx/performance/performance_dashboard.h similarity index 95% rename from src/app/gfx/performance_dashboard.h rename to src/app/gfx/performance/performance_dashboard.h index 6221826d..b7908ed3 100644 --- a/src/app/gfx/performance_dashboard.h +++ b/src/app/gfx/performance/performance_dashboard.h @@ -1,12 +1,12 @@ -#ifndef YAZE_APP_GFX_PERFORMANCE_DASHBOARD_H -#define YAZE_APP_GFX_PERFORMANCE_DASHBOARD_H +#ifndef YAZE_APP_GFX_PERFORMANCE_PERFORMANCE_DASHBOARD_H +#define YAZE_APP_GFX_PERFORMANCE_PERFORMANCE_DASHBOARD_H #include #include #include #include -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/memory_pool.h" #include "app/gfx/atlas_renderer.h" @@ -159,4 +159,4 @@ class PerformanceDashboard { } // namespace gfx } // namespace yaze -#endif // YAZE_APP_GFX_PERFORMANCE_DASHBOARD_H +#endif // YAZE_APP_GFX_PERFORMANCE_PERFORMANCE_DASHBOARD_H diff --git a/src/app/gfx/performance_profiler.cc b/src/app/gfx/performance/performance_profiler.cc similarity index 99% rename from src/app/gfx/performance_profiler.cc rename to src/app/gfx/performance/performance_profiler.cc index b0de6755..1b9ed0cc 100644 --- a/src/app/gfx/performance_profiler.cc +++ b/src/app/gfx/performance/performance_profiler.cc @@ -1,4 +1,4 @@ -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include #include diff --git a/src/app/gfx/performance_profiler.h b/src/app/gfx/performance/performance_profiler.h similarity index 97% rename from src/app/gfx/performance_profiler.h rename to src/app/gfx/performance/performance_profiler.h index 5163a7eb..92fa8106 100644 --- a/src/app/gfx/performance_profiler.h +++ b/src/app/gfx/performance/performance_profiler.h @@ -1,5 +1,5 @@ -#ifndef YAZE_APP_GFX_PERFORMANCE_PROFILER_H -#define YAZE_APP_GFX_PERFORMANCE_PROFILER_H +#ifndef YAZE_APP_GFX_PERFORMANCE_PERFORMANCE_PROFILER_H +#define YAZE_APP_GFX_PERFORMANCE_PERFORMANCE_PROFILER_H #include #include @@ -206,4 +206,4 @@ class ScopedTimer { } // namespace gfx } // namespace yaze -#endif // YAZE_APP_GFX_PERFORMANCE_PROFILER_H \ No newline at end of file +#endif // YAZE_APP_GFX_PERFORMANCE_PERFORMANCE_PROFILER_H \ No newline at end of file diff --git a/src/app/gfx/tilemap.cc b/src/app/gfx/tilemap.cc index e608c482..854c679b 100644 --- a/src/app/gfx/tilemap.cc +++ b/src/app/gfx/tilemap.cc @@ -5,7 +5,7 @@ #include "app/gfx/arena.h" #include "app/gfx/atlas_renderer.h" #include "app/gfx/bitmap.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/snes_tile.h" namespace yaze { diff --git a/src/app/gui/canvas.cc b/src/app/gui/canvas.cc index 986bdd09..0543ad0f 100644 --- a/src/app/gui/canvas.cc +++ b/src/app/gui/canvas.cc @@ -4,7 +4,7 @@ #include #include "app/gfx/bpp_format_manager.h" #include "app/gfx/bitmap.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gui/canvas_utils.h" #include "app/gui/style.h" #include "app/gui/canvas/canvas_automation_api.h" @@ -150,8 +150,8 @@ void Canvas::Cleanup() { selection_.Clear(); // Stop performance monitoring before cleanup to prevent segfault - if (performance_integration_) { - performance_integration_->StopMonitoring(); + if (performance/performance_integration_) { + performance/performance_integration_->StopMonitoring(); } // Cleanup enhanced components @@ -175,7 +175,7 @@ void Canvas::InitializeEnhancedComponents() { canvas::CanvasUsageManager::Get().RegisterTracker(canvas_id_, usage_tracker_); // Initialize performance integration - performance_integration_ = + performance/performance_integration_ = std::make_shared(); performance_integration_->Initialize(canvas_id_); performance_integration_->SetUsageTracker(usage_tracker_); @@ -208,15 +208,15 @@ void Canvas::RecordCanvasOperation(const std::string& operation_name, if (usage_tracker_) { usage_tracker_->RecordOperation(operation_name, time_ms); } - if (performance_integration_) { - performance_integration_->RecordOperation(operation_name, time_ms, + if (performance/performance_integration_) { + performance/performance_integration_->RecordOperation(operation_name, time_ms, GetUsageMode()); } } void Canvas::ShowPerformanceUI() { - if (performance_integration_) { - performance_integration_->RenderPerformanceUI(); + if (performance/performance_integration_) { + performance/performance_integration_->RenderPerformanceUI(); } } diff --git a/src/app/zelda3/overworld/overworld.cc b/src/app/zelda3/overworld/overworld.cc index 44c0b7ff..ea6ed2aa 100644 --- a/src/app/zelda3/overworld/overworld.cc +++ b/src/app/zelda3/overworld/overworld.cc @@ -10,7 +10,7 @@ #include "absl/status/status.h" #include "app/core/features.h" -#include "app/gfx/performance_profiler.h" +#include "app/gfx/performance/performance_profiler.h" #include "app/gfx/compression.h" #include "app/gfx/snes_tile.h" #include "app/rom.h"