https://github.com/scanmountgoat/ldr_wgpu
An experimental LDraw renderer using WGPU
https://github.com/scanmountgoat/ldr_wgpu
ldraw ldraw-viewer lego wgpu
Last synced: 6 months ago
JSON representation
An experimental LDraw renderer using WGPU
- Host: GitHub
- URL: https://github.com/scanmountgoat/ldr_wgpu
- Owner: ScanMountGoat
- License: mit
- Created: 2023-03-20T17:14:16.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2024-10-08T16:53:51.000Z (over 1 year ago)
- Last Synced: 2025-03-27T22:43:00.166Z (about 1 year ago)
- Topics: ldraw, ldraw-viewer, lego, wgpu
- Language: Rust
- Homepage:
- Size: 175 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ldr_wgpu

ldr_wgpu is an experimental LDraw renderer targeting modern desktop GPU hardware with an emphasis on performance.
The goal of this project is to research and implement suitable techniques for rendering large LDraw scenes in real time. This project is not designed to match the quality of offline renderers like Blender Cycles. The code is intended to serve as a reference for others wanting to build their own renderers and contains numerous comments and links to blog posts, technical docs, papers, etc. This project may be reworked to be useable as a library for future Rust projects at some point.
## Design
High level design decisions are outlined below. See [ARCHITECTURE](https://github.com/ScanMountGoat/ldr_wgpu/blob/main/ARCHITECTURE.md) for details.
If you have any comments or suggestions, feel free to open an [issue](https://github.com/ScanMountGoat/ldr_wgpu/issues) to discuss it.
- Hardware raytracing for efficient rendering of very complex scenes
- Instancing for reduced memory usage
- Heavy usage of multithreading and caching for fast scene load times
## Compatibility
The code is built using WGPU and targets modern GPU hardware for newer versions of Windows, Linux, and MacOS. The renderer takes advantage of modern features like hardware raytracing not available on older devices and requires DX12, Vulkan, or Metal support.
## Building
With a newer version of the [Rust toolchain](https://www.rust-lang.org/tools/install) installed, run `cargo build --release` from the main repository directory. Don't forget the --release since debug builds in Rust will run slowly. The executable will be located in `target/release`. Run the program as `cargo run --release -p ldr_viewer ` or from the executable directory as `ldr_viewer `.
## Copyrights
LDraw™ is a trademark owned and licensed by the Jessiman Estate, which does not sponsor, endorse, or authorize this project.
LEGO® is a registered trademark of the LEGO Group, which does not sponsor, endorse, or authorize this project.