How hanskristian-work/vkd3d-proton works
vkd3d-proton is a Direct3D 12 implementation layered on Vulkan, intended primarily as drop-in Win32 DLLs for Wine/Proton. The principal path is an application loading the D3D12 proxy, which forwards API work to the core implementation; the core creates devices and implements resources, commands, presentation, pipelines, and ray tracing. Shader translation and developer-facing compiler/debug facilities are distinct supporting branches. The README establishes the overall Vulkan-backed product and DLL role; sampled excerpts show proxy forwarding, while several internal subsystem links are not directly evidenced and are omitted.
Main entry points: device.c Device and capabilities · main.cpp HLSL build tool · d3d12/main.c D3D12 proxy DLL · d3d12core/main.c Core API DLL
Components 19
API entry
- D3D12 proxy DLL
libs/d3d12/main.c - Core API DLL
libs/d3d12core/main.c
D3D12 runtime
- Device and capabilities
libs/vkd3d/device.c - Resources and memory
libs/vkd3d/resource.c - Command recording
libs/vkd3d/command.c - Command queues
libs/vkd3d/command_queue_vkd3d_ext.c - Swapchain
libs/vkd3d/swapchain.c - Pipeline state
libs/vkd3d/state.c - Ray tracing
libs/vkd3d/raytracing_pipeline.c - Work graphs
libs/vkd3d/workgraphs.c
Shader translation
- Shader API
include/vkd3d_shader.h - DXBC translation
libs/vkd3d-shader/dxbc.c - DXIL translation
libs/vkd3d-shader/dxil.c - Shader compiler CLI
programs/vkd3d-compiler/main.c
Diagnostics and tools
- Debug logging
libs/vkd3d-common/debug.c - Platform services
libs/vkd3d-common/platform.c - HLSL build tool
programs/vkd3d-hlsl-build/main.cpp
Other components
- D3D12 application
- Vulkan driver
Connections 14
- D3D12 application → D3D12 proxy DLL: loads DLL
- D3D12 proxy DLL → Core API DLL: forwards API
libs/d3d12/main.c - Core API DLL → Device and capabilities: creates devices
- Device and capabilities → Vulkan driver: uses Vulkan
- Device and capabilities → Resources and memory
- Device and capabilities → Command recording
- Device and capabilities → Command queues
- Device and capabilities → Swapchain
- Device and capabilities → Pipeline state
- Device and capabilities → Ray tracing
- Device and capabilities → Work graphs
- Shader compiler CLI → Shader API: uses API
programs/vkd3d-compiler/main.c - HLSL build tool → DXBC translation: uses library
programs/vkd3d-hlsl-build/main.cpp - HLSL build tool → DXIL translation: uses library
programs/vkd3d-hlsl-build/main.cpp