krafix icon indicating copy to clipboard operation
krafix copied to clipboard

GLSL cross-compiler based on glslang and SPIRV-Cross

Results 6 krafix issues
Sort by recently updated
recently updated
newest added

The following shader ```glsl #version 450 in vec3 pos; in vec2 uv; in vec4 col; out vec2 frag_uv; uniform mat4 m[4]; void main() { gl_Position = m[gl_InstanceID] * vec4(pos, 1.0f);...

Minimal GLSL example: ```glsl #version 450 #define BUFFER_SIZE 16 uniform float radius[BUFFER_SIZE]; out vec4 fragColor; void main() { fragColor = vec4(radius[1], radius[1], radius[1], 1.0); } ``` The radius array looks...

Source glsl: ```glsl uniform vec4 shirr[7]; vec3 shIrradiance(const vec3 nor) { vec3 cl00 = vec3(shirr[0].x, shirr[0].y, shirr[0].z); // ... } void main() { // ... shIrradiance(n); } ``` Output metal:...

transpose requires glsl120, but we set 110 on Linux because we had error reports for some 3XX version and 110 seemed like the safest bet, so let's emit a transpose...

Perhaps as an optional flag when calling krafix. https://github.com/KhronosGroup/SPIRV-Tools#optimizer

From what I learned, krafix compiles two sets of shaders for webgl to have both available at runtime. The same thing would make sense to be enabled for targeting Android.