Use Linear filter algorithm in texture object for OffscreenCanvas 2d |
|||
Issue descriptionWhen implementing the OffscreenCanvas resizing, we notice that the current OffscreenCanvas 2d rendering context does not use nearest neighbor in texture object. The webgl rendering context is doing it correctly. The code should be something like TextureMailbox::set_nearest_neighbor(false). In canvas it is fixed via CSS. But in OffscreenCanvas this is going to be a bit tricky. When this bug is fixed, the gpu reference image of test Pixel_OffscreenCanvas2DResizeOnWorker should show soft edge of red rectangle inside green rectangle (Currently it is sharp edge).
,
Jan 2 2017
I'm having a WIP CL for this now: https://codereview.chromium.org/2607373002
,
Jan 3 2017
For records: By running webgl and 2d cases on all four commit cases, we note that the current situation is that the resizing works properly for all the other cases (i.e. blurred image when resizing is applied) except the single case when 2d rendering context is accelerated with gpu compositing enabled, which happens to be the default case of 2d rendering context.
,
Jan 11 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/7a66a4125991912014552fd1edbb58c37e9feede commit 7a66a4125991912014552fd1edbb58c37e9feede Author: xlai <xlai@chromium.org> Date: Wed Jan 11 04:40:50 2017 Linear filter for texture object in 2d context This is a temporary fix to enforce linear filter for texture object in OffscreenCanvasRenderingContext2D in commit(). An ideal solution, which is not urgent for OffscreenCanvas launch, is to adapt the filter to respect image-rendering CSS property, as indicated in crbug.com/645590 . BUG= 676666 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel Review-Url: https://codereview.chromium.org/2607373002 Cr-Commit-Position: refs/heads/master@{#442803} [modify] https://crrev.com/7a66a4125991912014552fd1edbb58c37e9feede/content/test/gpu/gpu_tests/pixel_expectations.py [modify] https://crrev.com/7a66a4125991912014552fd1edbb58c37e9feede/content/test/gpu/gpu_tests/pixel_test_pages.py [modify] https://crrev.com/7a66a4125991912014552fd1edbb58c37e9feede/third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.cpp
,
Jan 12 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/d310ed6a3cb42969b1353c81737325eef2f06c58 commit d310ed6a3cb42969b1353c81737325eef2f06c58 Author: xlai <xlai@chromium.org> Date: Thu Jan 12 19:08:25 2017 Remove failed gpu pixel tests The images generated on gpu reference archive are correctly showing blurry edge on enlarged canvas. TBR=zmo@chromium.org BUG= 676666 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel Review-Url: https://codereview.chromium.org/2625393002 Cr-Commit-Position: refs/heads/master@{#443314} [modify] https://crrev.com/d310ed6a3cb42969b1353c81737325eef2f06c58/content/test/gpu/gpu_tests/pixel_expectations.py
,
Jan 12 2017
This issue is fixed. The original title was wrong; we are using linear filter algorithm, not nearest-neighbor algorithm. |
|||
►
Sign in to add a comment |
|||
Comment 1 by xlai@chromium.org
, Dec 22 2016