feat: ImGui integration + real screenshot capture via Vulkan
ImGui: - ImGui.NET 1.91.6.1 NuGet package - VulkanImGui: font texture upload, ImGui pipeline (blending, no depth), vertex/index buffer streaming - GLSL 450 ImGui shaders (vert: scale/translate push constants, frag: font texture sampler) - Compiled to SPIR-V via @webgpu/glslang - Debug overlay: FPS, camera position, entity count, light list - 1600+ FPS with ImGui active Screenshot: - vkCmdCopyImageToBuffer embedded in main command buffer - Layout transition PresentSrcKHR→TransferSrcOptimal→PresentSrcKHR - Deferred read: staging buffer read on next frame after fence - BMP format written directly to FileStream (row by row) - All 16 camera tour screenshots captured (1280x720x32bpp) All 66 tests pass.
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
#version 450
|
||||
|
||||
layout(location = 0) in vec2 inPos;
|
||||
layout(location = 1) in vec2 inUV;
|
||||
layout(location = 2) in vec4 inColor;
|
||||
|
||||
layout(push_constant) uniform PushConstants {
|
||||
vec2 scale;
|
||||
vec2 translate;
|
||||
} pc;
|
||||
|
||||
layout(location = 0) out vec2 fragUV;
|
||||
layout(location = 1) out vec4 fragColor;
|
||||
|
||||
void main() {
|
||||
fragUV = inUV;
|
||||
fragColor = inColor;
|
||||
gl_Position = vec4(inPos * pc.scale + pc.translate, 0.0, 1.0);
|
||||
}
|
||||
Reference in New Issue
Block a user