8000 rafx and basis-universal by aclysma · Pull Request #501 · rust-gamedev/rust-gamedev.github.io · GitHub
[go: up one dir, main page]

Skip to content

rafx and basis-universal #501

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
76 changes: 76 additions & 0 deletions content/posts/newsletter-019/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,82 @@ this in action!

## Library & Tooling Updates

### [Rafx][rafx-github]

![Screenshot from Rafx Rendering Framework](rafx-screenshot.png)

Rafx is a multi-backend renderer that optionally integrates with the
[distill][rafx-distill] asset pipeline. Rafx is divided into three tiers of
functionality:

`rafx-api` provides a custom GPU API abstraction layer that currently supports
vulkan and metal. ([API in rust psuedocode][rafx-api-design])

`rafx-framework` builds on the API layer using ideas found in modern shipping
AAA titles. Rendering is pipelined in a separate thread in three phases, using
jobs to extract data from the main thread, process the data on the render
thread, and write the draw calls to command buffers.
[[Tatarchuk 2015][rafx-gdc-2015]] A render graph ensures correct
synchronization. [[O'Donnell 2017][rafx-gdc-2017]] The framework also provides
a material abstraction and shader pipeline.

`rafx-assets` adds integration with the [distill][rafx-distill] asset pipeline.
This ensures that when an asset like a mesh is loaded, other related assets
like textures/material/vertex data are loaded. By integrating with distill,
rafx provides advanced features like streaming live asset updates to remote
devices.

More information about rafx:

- [Github][rafx-github]
- [Documentation][rafx-documentation]
- [Why Rafx?][why-rafx] (includes similarities/differences with other rust
and non-rust alternatives)

[rafx-github]: https://github.com/aclysma/rafx
[rafx-documentation]: https://github.com/aclysma/rafx/blob/master/docs/index.md
[why-rafx]: https://github.com/aclysma/rafx/blob/master/docs/why_rafx.md
[rafx-api-design]: https://github.com/aclysma/rafx/blob/master/docs/api/api_design_in_rust_psuedocode.rs
[rafx-api-triangle-example]: https://github.com/aclysma/rafx/blob/master/rafx/examples/api_triangle/api_triangle.rs
[rafx-gdc-2015]: http://advances.realtimerendering.com/destiny/gdc_2015/Tatarchuk_GDC_2015__Destiny_Renderer_web.pdf
[rafx-gdc-2017]: https://www.gdcvault.com/play/1024612/FrameGraph-Extensible-Rendering-Architecture-in
[rafx-distill]: https://github.com/amethyst/distill

### [basis-universal-rs]

`basis-universal` provides bindings for [Binomial LLC][binomial-llc]'s
[Basis Universal texture codec][basis-universal-upstream].

Basis Universal is a state-of-the art
[supercompressed][basis-universal-supercompression] texture codec that
was recently [open-sourced][basis-universal-open-sourced] by Binomial in
partnership with Google. It was
[contributed][basis-universal-contributed-kronos] to the Khronos glTF
3D Transmission Open Standard.

The library has two primary uses:

- Compresses and encode textures "offline" to a custom format
- Transcoding: Unpack the custom format directly to GPU-friendly compressed
formats. The final format can be chosen at game runtime to be compatible
with available GPU hardware.

Basis universal format can also store mipmapped textures and cubemaps,
neither of which is possible with "normal" file formats. Mipmaps can be
generated by the library during compression.

Compression is very slow (around 7-10s for a 2k texture) but transcoding is
relatively fast (around 5-40ms for a 2k texture depending on quality). Memory
savings at runtime are generally >= 75% (depending on the transcode format
and quality)

[binomial-llc]: http://www.binomial.info
[basis-universal-rs]: https://github.com/aclysma/basis-universal-rs
[basis-universal-upstream]: https://github.com/BinomialLLC/basis_universal
[basis-universal-supercompression]: http://gamma.cs.unc.edu/GST/gst.pdf
[basis-universal-open-sourced]: https://opensource.googleblog.com/2019/05/google-and-binomial-partner-to-open.html
[basis-universal-contributed-kronos]: https://www.khronos.org/blog/google-and-binomial-contribute-basis-universal-texture-format-to-khronos-gltf-3d-transmission-open-standard

### [egui]

![The plot thickens](egui-plot.gif)
Expand Down
Binary file added content/posts/newsletter-019/rafx-screenshot.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
0