checkpoint(new_editor): native d3d12 ui path

Key node 1: move main-window UI presentation onto the D3D12 render loop with native UI renderer, text system, and texture host.

Key node 2: wire frame timing/FPS display, window runtime, swapchain presentation, and native screenshot capture around the new path.

Key node 3: carry editor shell/workspace/viewport/panel interaction updates needed by the new renderer and detached window flow.

Key node 4: pump async resource loads and scene bridge follow-up needed for scene content visibility in new_editor.
This commit is contained in:
2026-04-21 20:49:18 +08:00
parent a779b04dba
commit 6e9265e92e
53 changed files with 5330 additions and 858 deletions

View File

@@ -372,7 +372,8 @@ void AppendUIEditorViewportSlotForeground(
const std::vector<UIEditorStatusBarSegment>& statusSegments,
const UIEditorViewportSlotState& state,
const UIEditorViewportSlotPalette& palette,
const UIEditorViewportSlotMetrics& metrics) {
const UIEditorViewportSlotMetrics& metrics,
const UIEditorViewportSlotForegroundAppendOptions& options) {
if (layout.hasTopBar) {
if (!chrome.title.empty()) {
drawList.AddText(
@@ -405,7 +406,9 @@ void AppendUIEditorViewportSlotForeground(
}
}
if (frame.hasTexture && frame.texture.IsValid()) {
if (options.includeSurfaceTexture &&
frame.hasTexture &&
frame.texture.IsValid()) {
drawList.AddImage(layout.textureRect, frame.texture, palette.imageTint);
}
@@ -419,6 +422,18 @@ void AppendUIEditorViewportSlotForeground(
}
}
void AppendUIEditorViewportSlotSurfaceTexture(
UIDrawList& drawList,
const UIEditorViewportSlotLayout& layout,
const UIEditorViewportSlotFrame& frame,
const UIEditorViewportSlotPalette& palette) {
if (!frame.hasTexture || !frame.texture.IsValid()) {
return;
}
drawList.AddImage(layout.textureRect, frame.texture, palette.imageTint);
}
void AppendUIEditorViewportSlot(
UIDrawList& drawList,
const UIRect& bounds,
@@ -454,7 +469,8 @@ void AppendUIEditorViewportSlot(
statusSegments,
state,
palette,
metrics);
metrics,
{});
}
} // namespace XCEngine::UI::Editor::Widgets