emil28092005
|
2e0970e769
|
feat: rebuild Vulkan renderer from scratch — pure P/Invoke triangle (Vulkan 1.3)
- Complete rewrite of Engine.Graphics.Vulkan with pure P/Invoke (no wrapper libs)
- Vulkan 1.3: dynamic rendering (vkCmdBeginRendering/vkCmdEndRendering),
synchronization2 (vkQueueSubmit2, vkCmdPipelineBarrier2)
- Split types into VulkanHandles.cs, VulkanEnums.cs, VulkanStructs.cs
- Staging buffer → device-local vertex buffer pattern
- Correct swapchain semaphore indexing (per-image, not per-frame-in-flight)
- VK_EXT_debug_utils debug messenger with validation layer fallback
- Dynamic viewport/scissor (no pipeline recreation on resize)
- Simplified Program.cs to triangle-only rendering
- Removed old Silk.NET renderer, ImGui, PBR shaders, screenshot code
- Updated VULKAN_IMPLEMENTATION_PLAN.md with full architecture decisions
|
2026-06-18 01:49:25 +03:00 |
|
emil28092005
|
80238b08f5
|
feat: pure Vulkan P/Invoke renderer — no wrappers, SDL3 window, SPIR-V shaders
- Engine.Graphics: restored interfaces (IRenderContext, IRenderer, RenderBackendFactory),
loaders (ObjLoader, GltfLoader), ProceduralMesh, MeshMath, SceneSerializer
- Engine.Graphics.Vulkan: pure P/Invoke to libvulkan.so.1/vulkan-1.dll
- VulkanNative: library loading, function pointer loading via vkGetInstanceProcAddr
- Vk: static function cache for ~80 Vulkan functions, all delegate types
- VulkanTypes: ~50 structs, ~20 enums matching Vulkan C headers
- VulkanContext: instance, physical device, logical device, surface, memory types
- VulkanSwapchain: swapchain, image views, depth image, render pass, framebuffers
- VulkanPipeline: graphics pipeline, descriptor set layout, shader modules
- VulkanBuffer: vertex/index/uniform buffers, staging, memory allocation
- VulkanRenderer: command buffers, sync (semaphores/fences), render loop, 2 frames in flight
- GLSL 450 shaders: PBR lighting (Fresnel, ACES, gamma), directional+point lights
- Compiled to SPIR-V via @webgpu/glslang WASM
- CortexEngine.App: switched to vulkan backend, removed Raylib/OpenTK/ImGui refs
- Tests: all 66 pass (ObjLoader, MeshMath, ProceduralMesh, SceneSerializer, etc.)
- Camera tour: 16 poses, screenshots captured, clean shutdown
|
2026-06-17 23:03:24 +03:00 |
|
emil28092005
|
c82ff48119
|
fix: rlgl depth FBO shadows, correct normals, linear gamma, per-channel Fresnel
- Shadow mapping via rlgl: custom depth FBO (2048x2048, 24-bit depth texture)
instead of color-attachment approach. Proper depth-only render pass.
- Shadow map bound via MaterialMapIndex.Emission (texture unit 1), sampled
in shadow receiver shader with PCF 3x3 soft shadows.
- Fixed inverted normals: Cross(ac, ab) for CW winding in OBJ files.
- Linear workflow: pow(albedo, 2.2) before lighting, pow(result, 1/2.2) after.
- Per-channel Fresnel: vec3 F0 + (1-F0)*pow(1-HdotV,5) instead of F0.x.
- Single CollectLights call after BeginMode3D.
- Shadow pass after BeginDrawing (inside frame).
- Backface culling disabled globally for mixed-winding meshes.
- Point light support: Light.Point/Directional factory methods, attenuation,
ImGui inspector with type combo, position/range for point lights.
- Floor rendered for both light types (shadow receiver or main shader).
- 66/66 tests passing.
|
2026-06-17 16:13:46 +03:00 |
|
emil28092005
|
2d30dec01c
|
feat: Dear ImGui editor, GLTF materials, scene serialization
- ImGuiLayer: entity inspector (Transform/Material/Light/Camera editing),
hierarchy panel, debug overlay with FPS graph (rlImgui-cs + ImGui.NET)
- GltfLoader.LoadWithMaterials: extracts PBR albedo, roughness, metallic,
base color texture from glTF files
- SceneSerializer: save/load ECS world to/from JSON with custom
Vector3/Quaternion converters, 6 tests
- ImGui disabled in tour/test mode to keep screenshots clean
- 66/66 tests passing
|
2026-06-17 14:12:02 +03:00 |
|