Refactor editor rendering contracts
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "SceneToolState.h"
|
||||
#include "HostFwd.h"
|
||||
#include "Assets/EditorIconService.h"
|
||||
|
||||
#include <XCEngine/UI/DrawData.h>
|
||||
#include <XCEngine/UI/Types.h>
|
||||
@@ -9,7 +9,6 @@
|
||||
#include <array>
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
#include <filesystem>
|
||||
#include <string>
|
||||
|
||||
namespace XCEngine::UI::Editor::App {
|
||||
@@ -57,10 +56,7 @@ struct SceneViewportToolOverlayFrame {
|
||||
|
||||
class SceneViewportToolOverlay {
|
||||
public:
|
||||
bool Initialize(
|
||||
const std::filesystem::path& repoRoot,
|
||||
Rendering::Host::UiTextureHost& renderer);
|
||||
void Shutdown(Rendering::Host::UiTextureHost& renderer);
|
||||
void SetIconService(const EditorIconService* iconService);
|
||||
void ResetFrame();
|
||||
|
||||
void BuildFrame(
|
||||
@@ -82,15 +78,8 @@ public:
|
||||
const SceneViewportToolOverlayFrame& GetFrame() const;
|
||||
|
||||
private:
|
||||
struct ToolTextureSet {
|
||||
SceneToolMode mode = SceneToolMode::View;
|
||||
const char* label = "";
|
||||
::XCEngine::UI::UITextureHandle inactiveTexture = {};
|
||||
::XCEngine::UI::UITextureHandle activeTexture = {};
|
||||
};
|
||||
|
||||
std::array<ToolTextureSet, 5> m_toolTextures = {};
|
||||
SceneViewportToolOverlayFrame m_frame = {};
|
||||
const EditorIconService* m_iconService = nullptr;
|
||||
};
|
||||
|
||||
void AppendSceneViewportToolOverlay(
|
||||
|
||||
Reference in New Issue
Block a user