United StatesCrossGL/crosstl
Translate GPU shaders and compute kernels between GLSL, HLSL, Metal, SPIR-V, Slang, CUDA and HIP, and to WGSL, through the CrossGL IR
Thành tựu nổi bật
Những danh hiệu mới nhất của dự án
#1 Repository Của Tháng
#1 Repository Của Tháng
#1 Repository Của Tháng
🔀 CrossTL: Universal Shader Translator
Convert shaders across GLSL, HLSL, Metal, SPIR-V and more with a single IR.
CrossTL is a Python library built around CrossGL, an intermediate representation that bridges graphics APIs and compute platforms. It provides source import and codegen backends for DirectX/HLSL, Metal, OpenGL/GLSL, Vulkan/SPIR-V, CUDA, HIP, Rust, Mojo, Slang, and WGSL, enabling round‑trip translation between native shader languages.
✨ Highlights
- CrossGL IR: Central intermediate representation that unifies multiple shader languages.
- Bidirectional backends: Source parsing and code generation for DirectX, Metal, and OpenGL.
- Wide target support: Output to HLSL, MSL, GLSL, GLSL ES, WGSL, SPIR-V, CUDA, HIP, Rust, Mojo, Slang, and CrossGL.
- Stage coverage: Handles vertex, fragment, compute, geometry, hull/domain, mesh/task, and ray‑tracing stages.
- Resource model: Translates cbuffers, UAV/RW textures, structured buffers, atomics, and wave ops.
- Round‑trip verified: Tested with unit suites ensuring parity across backends.
💡 Why it matters
CrossTL solves the headache of maintaining separate shader code for each platform by offering a single source that can be translated to many targets. Its first‑class bidirectional support for DirectX, Metal, and OpenGL means developers can import existing shaders and regenerate them without lossy conversions. The project is ideal for cross‑platform graphics engines, game development studios, and researchers who need to experiment with different GPU APIs without rewriting shaders.
#Shader #Translation #GPU #CrossGL #TiniX
Similar Projects
Discover other similar projects and AI models.
Khronos-reference front end for GLSL/ESSL, partial front end for HLSL, and a SPIR-V generator.
ShaderConductor is a tool designed for cross-compiling HLSL to other shading languages
Cross-platform, graphics API agnostic, "Bring Your Own Engine/Framework" style rendering library.