NEW 138951
[GTK] Fix the broken edge-distance antialiasing
https://bugs.webkit.org/show_bug.cgi?id=138951
Summary [GTK] Fix the broken edge-distance antialiasing
JeongBong Seo
Reported 2014-11-20 22:15:51 PST
There exist a wrong matrix multiply to get viewport space position. --------------------------------------------------------------------------------- vec4 toViewportSpace(vec2 pos) { return vec4(pos, 0., 1.) * u_modelViewMatrix; } --------------------------------------------------------------------------------- It generates wrong position and affects the inflation ratio to each vertices. The transformation matrix should be left side. After fix the multiplication, I got little strange result. Anti-aliased layer's (inner) contents are expanded 1px. But it shouldn't happen and only edge should be inflated. Than I just erase the clamp function to create transformedTexCoord, and finally, got the good result. But in theory clamping the position should be there, because we using GL_REPEAT in many case. Please give me some idea or comment.
Attachments
Patch (4.48 KB, patch)
2014-11-20 22:23 PST, JeongBong Seo
no flags
Patch (4.71 KB, patch)
2014-11-20 22:35 PST, JeongBong Seo
jb.seo: review+
after fix (119.11 KB, image/png)
2014-11-20 22:53 PST, JeongBong Seo
no flags
before fix (113.54 KB, image/png)
2014-11-20 22:53 PST, JeongBong Seo
no flags
JeongBong Seo
Comment 1 2014-11-20 22:23:03 PST
JeongBong Seo
Comment 2 2014-11-20 22:35:41 PST
JeongBong Seo
Comment 3 2014-11-20 22:53:00 PST
Created attachment 242026 [details] after fix
JeongBong Seo
Comment 4 2014-11-20 22:53:20 PST
Created attachment 242027 [details] before fix
JeongBong Seo
Comment 5 2014-11-20 22:54:41 PST
JeongBong Seo
Comment 6 2014-11-20 23:10:49 PST
Comment on attachment 242025 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=242025&action=review > Source/WebCore/platform/graphics/texmap/TextureMapperShaderProgram.cpp:-177 > - vec4 clampedPosition = clamp(vec4(position, 0., 1.), 0., 1.); I'm not sure eliminating the clamp function. But with clamp, it shows expanded output.
JeongBong Seo
Comment 7 2014-11-30 20:38:25 PST
anybody?
Note You need to log in before you can comment on or make changes to this bug.