GLSL (glslangValidator) and Slang shader compilation, pure-MoonBit SPIR-V reflection, and PPM/BMP image loading helpers for Tycho
Part of the Tycho graphics stack — mounted there as the shader/ submodule.
pub suberror ShaderError {
CompileFailed(ShaderStage, String)
SlangFailed(String, String)
LoadFailed(String, String)
}fn compile_shader_checked(source : String, stage : ShaderStage) -> FixedArray[UInt] raise ShaderErrorfn compile_shader_env(source : String, stage : ShaderStage, target : ShaderTarget) -> FixedArray[UInt]fn compile_shader_file_checked(path : String, stage : ShaderStage) -> FixedArray[UInt] raise ShaderErrorfn compile_shader_file_env(path : String, stage : ShaderStage, target : ShaderTarget) -> FixedArray[UInt]fn compile_shader_file_env_checked(path : String, stage : ShaderStage, target : ShaderTarget) -> FixedArray[UInt] raise ShaderErrorfn last_error() -> Stringfn load_spirv(path : String) -> FixedArray[UInt]fn save_png(path : String, width : Int, height : Int, rgba : FixedArray[Byte], bgra? : Bool) -> BoolInstall
Download zipGLSL (glslangValidator) and Slang shader compilation, pure-MoonBit SPIR-V reflection, and PPM/BMP image loading helpers for Tycho