Go to file
2022-11-21 18:49:51 -05:00
.idea reflect: clean up public reflect API a little 2022-11-11 01:44:41 -05:00
librashader lib: sort out base library structure 2022-11-21 16:53:36 -05:00
librashader-common reflect: desugar rpitit into tait to avoid incomplete feature warning 2022-11-21 18:19:43 -05:00
librashader-preprocess fmt: cleanup unused items 2022-11-21 17:47:38 -05:00
librashader-presets fmt: clean up unused items 2022-11-21 16:21:50 -05:00
librashader-reflect reflect: desugar rpitit into tait to avoid incomplete feature warning 2022-11-21 18:19:43 -05:00
librashader-runtime-dx11 lib: sort out base library structure 2022-11-21 16:53:36 -05:00
librashader-runtime-gl reflect: desugar rpitit into tait to avoid incomplete feature warning 2022-11-21 18:19:43 -05:00
target fmt: run clippy 2022-11-11 01:53:02 -05:00
test gl: initialize history and feedback fbos before drawing 2022-11-21 02:36:37 -05:00
.gitignore preset: consider scale when parsing xy scale 2022-10-20 23:11:23 -04:00
.gitmodules reflect: some cursed experiments 2022-10-25 01:47:41 -04:00
Cargo.lock fmt: clean up unused items 2022-11-21 16:21:50 -05:00
Cargo.toml lib: sort out base library structure 2022-11-21 16:53:36 -05:00
LICENSE.md doc: update license 2022-11-21 18:49:51 -05:00
README.md doc: update license 2022-11-21 18:49:51 -05:00

librashader

image

crt-royale-fake-bloom

A preprocessor, compiler, and runtime for RetroArch 'slang' shaders, rewritten in pure Rust.

Heavily WIP.

Supported Render APIs

librashader supports OpenGL 3, Vulkan, DirectX 11, and DirectX 12. Support is WIP for all runtimes except OpenGL 3. Older versions of DirectX and OpenGL, as well as Metal, are not supported (but pull-requests are welcome).

API Status librashader feature
OpenGL 3 gl
Vulkan 🚧 vk
DirectX 11 🚧 dx11
DirectX 12 🚧 dx12
OpenGL 2
DirectX 9
Metal

License

Unless otherwise specified, librashader is licensed under the GPLv3.

 Copyright (C) 2022 Ronny Chan <ronny@ronnychan.ca>

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, version 3 of the License.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <http://www.gnu.org/licenses/>.

While librashader is an independent reimplementation of the RetroArch shader pipeline, referencing the RetroArch source code was indispensable to its creation. As it is therefore considered a derivative work, the core parts of librashader such as the preprocessor, the preset parser, the reflection library, and the runtimes, are all licensed under GPLv3.

The librashader C API, i.e. its headers and definitions, not its implementation in librashader_capi, are unique to librashader and are more permissively licensed, and may allow you to use librashader in your permissively licensed or proprietary project.

While the code for librashader_capi (librashader.so and rashader.dll) is still under GPLv3, you may use librashader in a non-GPL work by linking against the MIT licensed librashader_ld, which implements the librashader C API, and thunks its calls to any librashader.so or rashader.dll library found in the load path, provided that librashader.so or rashader.dll are distributed under the restrictions of GPLv3.

Note that if your project is not compatible with GPLv3, you can not distribute librashader.so or rashader.dll alongside your project, only librashader-ld.so or rashader-ld.dll, which will do nothing without a librashader implementation in the load path. The end user must obtain the implementation of librashader themselves.