Split vulkan_window.cpp by responsibility and render() into phases
VulkanWindow's 3000-line TU becomes sdl_window.cpp (window, events, cursor, screenshot BMP), vk_device.cpp (device, swapchain, MSAA, framebuffers), vk_pipelines.cpp (render passes, pipelines), vk_resources.cpp (buffers, render targets, geometry), vk_textures.cpp (textures, samplers, descriptors), vk_frame.cpp (render) and ui_batches.cpp; vulkan_window.cpp keeps construction and timing stats. Function bodies move verbatim. render() now reads fence/acquire -> prepare_draws -> prepare_ui -> write_draw_states -> record_passes -> record_readbacks -> submit -> finish_readbacks -> present, with FrameDraws / Readback carrying the locals that used to live across 500 lines. Verified: login-screen screenshot byte-identical to HEAD; game-world draw/vertex/index/UI counts identical; ctest, port_gate macos+android, Android build pass. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
eab5938072
commit
22d534c5eb
@@ -33,7 +33,7 @@
|
||||
- `src/port/<Lib>/<File>.{h,cpp}` — mirror of each 40250 `logic`/`python` unit (see SKILL.md "Code layout").
|
||||
- `src/platform/` — implementations of the mirrored 40250 platform classes (D3D8 recorder, Granny,
|
||||
Miles, SpeedTree stand-in, window/input, ScriptLib boot).
|
||||
- `src/host/` — SDL3 + Vulkan host (`main.cpp` entry, `live_client.cpp` loop, `vulkan_window.cpp` renderer); `src/gr2/` — Granny reader; `src/codepage/` — code pages.
|
||||
- `src/host/` — SDL3 + Vulkan host (`main.cpp` entry, `live_client.cpp` loop, `vulkan_window.h` renderer split across `vulkan_window.cpp`/`vk_*.cpp`/`sdl_window.cpp`/`ui_batches.cpp`); `src/gr2/` — Granny reader; `src/codepage/` — code pages.
|
||||
- `third_party/` — vendored cpython 2.7.18, cryptopp, freetype, minilzo.
|
||||
- `tests/port/` — port tests and the fake login server; `tests/gr2/` — Granny reader tests.
|
||||
- `android/` — SDLActivity shell, `android/build.sh`, `android/push-client.sh`.
|
||||
|
||||
Reference in New Issue
Block a user