1
0
mirror of https://github.com/TomHarte/CLK.git synced 2025-01-27 06:35:04 +00:00

Fixed accidental channel duplication.

This commit is contained in:
Thomas Harte 2016-04-22 19:18:28 -04:00
parent 95639f1189
commit 8ff1f82008

View File

@ -563,7 +563,6 @@ char *OpenGLOutputBuilder::get_chrominance_filter_fragment_shader()
"void main(void)" "void main(void)"
"{" "{"
// "fragColour = texture(texID, inputPositionsVarying[5]).rgb;"
"vec3 centreSample = texture(texID, inputPositionsVarying[5]).rgb;" "vec3 centreSample = texture(texID, inputPositionsVarying[5]).rgb;"
"vec2 samples[] = vec2[](" "vec2 samples[] = vec2[]("
"texture(texID, inputPositionsVarying[0]).gb," "texture(texID, inputPositionsVarying[0]).gb,"
@ -579,12 +578,12 @@ char *OpenGLOutputBuilder::get_chrominance_filter_fragment_shader()
"texture(texID, inputPositionsVarying[10]).gb" "texture(texID, inputPositionsVarying[10]).gb"
");" ");"
"vec4 channel1[3] = vec4[](" "vec4 channel1[] = vec4[]("
"vec4(samples[0].r, samples[1].r, samples[2].r, samples[3].r)," "vec4(samples[0].r, samples[1].r, samples[2].r, samples[3].r),"
"vec4(samples[4].r, samples[5].r, samples[6].r, samples[7].r)," "vec4(samples[4].r, samples[5].r, samples[6].r, samples[7].r),"
"vec4(samples[8].r, samples[9].r, samples[10].r, 0.0)" "vec4(samples[8].r, samples[9].r, samples[10].r, 0.0)"
");" ");"
"vec4 channel2[3] = vec4[](" "vec4 channel2[] = vec4[]("
"vec4(samples[0].g, samples[1].g, samples[2].g, samples[3].g)," "vec4(samples[0].g, samples[1].g, samples[2].g, samples[3].g),"
"vec4(samples[4].g, samples[5].g, samples[6].g, samples[7].g)," "vec4(samples[4].g, samples[5].g, samples[6].g, samples[7].g),"
"vec4(samples[8].g, samples[9].g, samples[10].g, 0.0)" "vec4(samples[8].g, samples[9].g, samples[10].g, 0.0)"
@ -597,9 +596,9 @@ char *OpenGLOutputBuilder::get_chrominance_filter_fragment_shader()
"dot(channel1[2], weights[2])" "dot(channel1[2], weights[2])"
"), vec3(1.0, 1.0, 1.0))," "), vec3(1.0, 1.0, 1.0)),"
"dot(vec3(" "dot(vec3("
"dot(channel1[0], weights[0])," "dot(channel2[0], weights[0]),"
"dot(channel1[1], weights[1])," "dot(channel2[1], weights[1]),"
"dot(channel1[2], weights[2])" "dot(channel2[2], weights[2])"
"), vec3(1.0, 1.0, 1.0))" "), vec3(1.0, 1.0, 1.0))"
");" ");"
"}"); "}");