refactor(new_editor): tighten app dependency boundaries
This commit is contained in:
@@ -4,6 +4,8 @@
|
||||
#define NOMINMAX
|
||||
#endif
|
||||
|
||||
#include "Host/TextureHost.h"
|
||||
|
||||
#include <Rendering/D3D12/D3D12WindowInteropContext.h>
|
||||
#include <Rendering/D3D12/D3D12WindowRenderer.h>
|
||||
|
||||
@@ -29,7 +31,9 @@
|
||||
|
||||
namespace XCEngine::UI::Editor::Host {
|
||||
|
||||
class NativeRenderer : public ::XCEngine::UI::Editor::UIEditorTextMeasurer {
|
||||
class NativeRenderer
|
||||
: public TextureHost
|
||||
, public ::XCEngine::UI::Editor::UIEditorTextMeasurer {
|
||||
public:
|
||||
bool Initialize(HWND hwnd);
|
||||
void Shutdown();
|
||||
@@ -47,13 +51,13 @@ public:
|
||||
bool LoadTextureFromFile(
|
||||
const std::filesystem::path& path,
|
||||
::XCEngine::UI::UITextureHandle& outTexture,
|
||||
std::string& outError);
|
||||
std::string& outError) override;
|
||||
bool LoadTextureFromMemory(
|
||||
const std::uint8_t* data,
|
||||
std::size_t size,
|
||||
::XCEngine::UI::UITextureHandle& outTexture,
|
||||
std::string& outError);
|
||||
void ReleaseTexture(::XCEngine::UI::UITextureHandle& texture);
|
||||
std::string& outError) override;
|
||||
void ReleaseTexture(::XCEngine::UI::UITextureHandle& texture) override;
|
||||
float MeasureTextWidth(
|
||||
const ::XCEngine::UI::Editor::UIEditorTextMeasureRequest& request) const override;
|
||||
bool CaptureToPng(
|
||||
|
||||
Reference in New Issue
Block a user