FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

pixelforge/shader at main · hgaiser/pixelforge · GitHub

Latest commit

 

History

History

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

README.md

PixelForge Shaders

Precompiled Vulkan compute shaders for GPU-accelerated color format conversion.

Shaders

color_convert.comp — RGB → YUV compute shader. Converts BGRx/RGBx/BGRA/RGBA/ABGR2101010/RGBA16F input to NV12/I420/YUV444/P010/YUV444P10 output using BT.709, BT.2020, or sRGB→BT.2020+PQ color space matrices.

Compilation

Requires glslc from the Vulkan SDK.

./compile.sh

This compiles both shaders to SPIR-V 1.6 (Vulkan 1.3, optimized). The .spv files are included in source via include_bytes!, so rerun this after editing a .comp and commit the result.

The examples carry one more, outside the library: examples/shader/sample_frame.comp reads a decoded frame through a sampler-YCbCr conversion and writes RGBA, which is what examples/sample_frame.rs uses to show the zero-copy render path.


Back | FazBrowse Home | New Git URL