X-Git-Url: https://git.sesse.net/?p=movit;a=blobdiff_plain;f=header.comp;h=f4ebbed039cf35333b6f0b7a165169d9ac1e50a8;hp=d922e33efedaaf511f61a9406a1b6bf6a8db7a51;hb=fb1f4f2008f97c71248c0554d93e8d7c11347a8b;hpb=5e771df1523ea3f7926c0b5a115c29d134c53f11 diff --git a/header.comp b/header.comp index d922e33..f4ebbed 100644 --- a/header.comp +++ b/header.comp @@ -1,13 +1,18 @@ #version 150 #extension GL_ARB_compute_shader : enable #extension GL_ARB_shader_image_load_store : enable +#extension GL_ARB_shader_image_size : enable -// FIXME this needs to be auto-output or something -uniform restrict writeonly image2D outbuf; +// The texture the compute shader is writing to. +uniform restrict writeonly image2D tex_outbuf; // Defined in footer.comp. vec4 tex2D(sampler2D s, vec2 coord); void cs_output(uvec2 coord, vec4 val); void cs_output(ivec2 coord, vec4 val); +// Used if there are any steps used to postprocess compute shader output. +// Initialized due to https://bugs.freedesktop.org/show_bug.cgi?id=103895. +vec4 CS_OUTPUT_VAL = vec4(0.0); + #define OUTPUT(tc, val) cs_output(tc, val)