{"id":13635033,"url":"https://github.com/KaminariOS/rustracer","last_synced_at":"2025-04-19T03:34:19.793Z","repository":{"id":142305658,"uuid":"612522381","full_name":"KaminariOS/rustracer","owner":"KaminariOS","description":"Vulkan path tracing with Rust","archived":false,"fork":false,"pushed_at":"2023-10-13T02:16:19.000Z","size":21224,"stargazers_count":64,"open_issues_count":7,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-04-22T13:31:39.716Z","etag":null,"topics":["3d-graphics","animation","ash-rs","compute-shader","gltf","nix","path-tracer","physically-based-rendering","ray-tracing","raytracing","rendering","rust","skinning","vulkan"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/KaminariOS.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2023-03-11T07:34:57.000Z","updated_at":"2024-04-15T16:54:17.000Z","dependencies_parsed_at":"2024-01-07T21:53:56.896Z","dependency_job_id":null,"html_url":"https://github.com/KaminariOS/rustracer","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KaminariOS%2Frustracer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KaminariOS%2Frustracer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KaminariOS%2Frustracer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KaminariOS%2Frustracer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/KaminariOS","download_url":"https://codeload.github.com/KaminariOS/rustracer/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249600503,"owners_count":21297707,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["3d-graphics","animation","ash-rs","compute-shader","gltf","nix","path-tracer","physically-based-rendering","ray-tracing","raytracing","rendering","rust","skinning","vulkan"],"created_at":"2024-08-02T00:00:39.418Z","updated_at":"2025-04-19T03:34:17.259Z","avatar_url":"https://github.com/KaminariOS.png","language":"Rust","funding_links":[],"categories":["Applications"],"sub_categories":["Graphics"],"readme":"\u003cdiv align=\"center\"\u003e\n\n# `Rustracer`\n\n![Lines of code](https://tokei.rs/b1/github/KaminariOS/rustracer)\n![GitHub repo size](https://img.shields.io/github/repo-size/KaminariOS/rustracer)\n[![dependency status](https://deps.rs/repo/github/KaminariOS/rustracer/status.svg)](https://deps.rs/repo/github/KaminariOS/rustracer)\n![GitHub](https://img.shields.io/github/license/KaminariOS/rustracer)\n\n\u003c/div\u003e\n\nA PBR [glTF 2.0](https://www.khronos.org/gltf) renderer based on Vulkan ray-tracing, written in Rust.\n\n## Naming\nThis project and I are not affiliated with the [Rust Foundation](https://foundation.rust-lang.org). I name it `rus-tracer` only because I love [Rust](https://rust.facepunch.com) and ray tracing.\n\n## Credits\n\nThis project is based on Adrien Ben's [vulkan-examples-rs](https://github.com/adrien-ben/vulkan-examples-rs). \n\nSample accumulation implementation, heatmap and Lucy obj model are from project [Ray Tracing In Vulkan](https://github.com/GPSnoopy/RayTracingInVulkan).\n\nI stole the PBR shaders from the [referencePT](https://github.com/boksajak/referencePT) project and made some changes.\n\n## Demos\n[rustracer-0.2.0-Demo videos](https://www.youtube.com/watch?v=HYZCgwP7rmA\u0026list=LLeDjbBFLvS94sHm_j6i3CHw).\n\n[rustracer-0.1.0-Demo videos](https://www.youtube.com/playlist?list=PLD1H28onwV_mFsPySwOtlBn9h5ybzepir).\n\n\n![Lucy in Cornell](images/lucy.png)\n\n## Features\n* [x] Loading arbitrary glTF 2.0 models\n  * [x] Full node hierarchy\n    * [x] Mesh\n      * [x] Geometry normal generation\n      * [x] Two sets of texture coords\n      * [x] Mikktspace tangent generation\n      * [x] Normal mapping\n    * [ ] Camera\n  * [x] Alpha blending and testing\n  * [x] Full PBR material support\n    * [x] Metallic-Roughness workflow\n    * [x] Specular-Glossiness workflow\n  * [x] Animations\n    * [x] Articulated (translate, rotate, scale)\n    * [x] Skinning(using compute shader)\n    * [ ] Morph targets\n  * [x] Extensions\n      * [x] \"KHR_materials_ior\",\n      * [x] \"KHR_materials_pbrSpecularGlossiness\",\n      * [x] \"KHR_materials_transmission\",\n        * [ ] importance sampling and BTDF \n      * [x] \"KHR_materials_variants\",\n        * [ ] GUI support\n      * [x] \"KHR_materials_volume\",\n      * [ ] \"KHR_materials_specular\",\n      * [ ] \"KHR_texture_transform\",\n      * [x] \"KHR_materials_unlit\",\n      * [x] \"KHR_lights_punctual\",\n* [x] Optimizations\n  * [x] Rayon-accelerated texture loading\n  * [x] Async model loading\n  * [ ] Async acceleration structure building\n\n* [ ] Realtime ray tracing \n  * [ ] Rasterization mode\n  * [ ] G-buffer\n  * [ ] Hybrid mode\n  * [ ] SVGF denoiser\n  * [ ] Path regularization\n  * [ ] Better multi-light sampling like ReSTIR\n  * [ ] Blue noise and Halton sequence\n  \n* [x] Extras\n  * [x] Open file by drag-and-drop\n  * [x] Skybox\n  * [ ] Skydome(hdr)\n  * [ ] Loading multiple glTF scene dynamically\n  * [ ] Rigid-body simulation\n    \n## Building\n### Prerequisites\n- Linux and a graphics card that supports KHR ray tracing\n  - Currently, I hard-coded all test model paths in an enum(in [`gui_state.rs`](crates/examples/gltf_viewer/src/gui_state.rs)) and load models in the search paths(see [`resource manager`](crates/libs/resource_manager)). \n  - You can open arbitrary glTF file by `cargo run -- -f \u003cfilename\u003e` or drag-and-drop\n- Windows not supported. Need some minor cfg tweaks to work on Windows. Open to pull requests.\n\n### Build command\nThanks to the superior Rust package manager `Cargo`, building and running can be as brainless as a one-liner: `cargo run`. \n\nHowever, some external C libraries like Vulkan SDK may be missing on your system(those libraries are necessary for basically any Vulkan or non-trivial graphics programming project, regardless of whatever programming language used). \n\n\n- To install those libraries automatically,\n  - Install [Nix](https://nixos.org/download.html) package manager(Linux only) and [direnv](https://direnv.net). \n  - `cd` into the project directory and `direnv allow`.\n- To install external libraries manually\n  - `cargo run` to find out what is missing and install it\n  - Look into the list in [flake.nix](flake.nix).\n  \n## Assets\nPointers to glTF models: \n- [My collection](./assets/models/licenses)\n- [glTF sample models](https://github.com/KhronosGroup/glTF-Sample-Models).\n- [A ton of glTF models](https://sketchfab.com/search?features=downloadable\u0026type=models)\n- [Open Research Content Archive](https://developer.nvidia.com/orca) can be converted to glTF with Blender.\n- [Poly heaven](https://polyhaven.com)\n\n## References\n- [boksajak/referencePT](https://github.com/boksajak/referencePT)\n- [NVIDIA Vulkan Ray Tracing Tutorial](https://nvpro-samples.github.io/vk_raytracing_tutorial_KHR/)\n- [adrien-ben/gltf-viewer-rs](https://github.com/adrien-ben/gltf-viewer-rs)\n- [adrien-ben/vulkan-examples-rs](https://github.com/adrien-ben/vulkan-examples-rs)\n- [GPSnoopy/RayTracingInVulkan](https://github.com/GPSnoopy/RayTracingInVulkan)\n- [Ray Tracing Gems II](https://www.realtimerendering.com/raytracinggems/rtg2/index.html)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FKaminariOS%2Frustracer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FKaminariOS%2Frustracer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FKaminariOS%2Frustracer/lists"}