DescriptionHere's GrConvolutionEffect.
Passes GM and GLPrograms unit test; Linux GPU benchmarking is noisy, but the numbers don't look much worse there.
Current shader output looks like:
...
coverage2 = value2 * coverage1;
vec4 coverage3;
float c3 = dot(vStage3, vStage3) - uRadial2Params3[4];
{ // stage 3 Convolution
vec4 sum = vec4(0, 0, 0, 0);
vec2 coord = vec2((-c3 / vRadial2BCoeff3), 0.5);
for (int i = 0; i < 7; i++) {
sum += texture2D(uSampler3, coord) * uKernel3[i];
coord += uImageIncrement3;
}
coverage3 = sum * coverage2;
}
dualSourceOut = vec4(coverage3);
fsColorOut = vec4(matrixedColor * coverage3);
Patch Set 1 #Patch Set 2 : . #Patch Set 3 : . #Patch Set 4 : Restore flushConvolution() for Morphology's sake #Patch Set 5 : Now with extra (unit) testiness! #Patch Set 6 : cleanup #
Total comments: 21
Patch Set 7 : Fix comments that don't require structural changes #Patch Set 8 : New GrProgramStageFactory.{h,cpp} #
Total comments: 2
Patch Set 9 : Respond to Brian's comments #
Total comments: 13
MessagesTotal messages: 12
|