Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(556)

Issue 2418173002: Fix HTML5 video blurry (Closed)

Created:
4 years, 2 months ago by dshwang
Modified:
4 years, 1 month ago
CC:
cc-bugs_chromium.org, chromium-reviews, feature-media-reviews_chromium.org, posciak+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix HTML5 video blurry HW decoded video is blurry, because crbug.com/575587 shinked visual rect by 1 pixel, if coded rect is larger than visual rect. This fixed bleeding texture, but caused blurry issue. Meanwhile, crbug.com/429640 fixed bleeding texture for software YUV video in the elegant way. It clamps all texture coordinates to this maximum value in the fragment shader. This CL removes the 1 pixel hack and applies the way to TextureDrawQuad and StreamVideoDrawQuad (i.e. HW decoded video path). BUG=615325 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_precise_blink_rel Committed: https://crrev.com/b38566a76c4af61c0d34df7d8b906e7936b8e524 Cr-Commit-Position: refs/heads/master@{#428707}

Patch Set 1 #

Patch Set 2 : build fix #

Patch Set 3 : add pixeltests #

Total comments: 7

Patch Set 4 : fix canvas tests #

Patch Set 5 : fix plugin test #

Total comments: 12

Patch Set 6 : resolve reviewer's concerns #

Total comments: 3

Patch Set 7 : add dcheck #

Total comments: 6

Patch Set 8 : fix nits #

Unified diffs Side-by-side diffs Delta from patch set Stats (+530 lines, -237 lines) Patch
M cc/layers/video_layer_impl.cc View 2 chunks +7 lines, -12 lines 0 comments Download
M cc/output/gl_renderer.h View 1 2 3 4 5 6 2 chunks +4 lines, -3 lines 0 comments Download
M cc/output/gl_renderer.cc View 1 2 3 4 5 6 7 7 chunks +50 lines, -2 lines 0 comments Download
M cc/output/gl_renderer_draw_cache.h View 2 chunks +2 lines, -0 lines 0 comments Download
M cc/output/renderer_pixeltest.cc View 1 2 3 4 5 14 chunks +197 lines, -74 lines 0 comments Download
M cc/output/shader.h View 1 3 chunks +49 lines, -20 lines 0 comments Download
M cc/output/shader.cc View 1 5 chunks +89 lines, -36 lines 0 comments Download
M cc/resources/resource_provider.h View 1 2 2 chunks +0 lines, -3 lines 0 comments Download
M cc/resources/resource_provider.cc View 1 2 3 chunks +0 lines, -18 lines 0 comments Download
M cc/resources/video_resource_updater.h View 1 2 3 4 5 6 7 1 chunk +2 lines, -0 lines 0 comments Download
M cc/resources/video_resource_updater.cc View 1 2 3 4 5 6 7 6 chunks +33 lines, -10 lines 0 comments Download
M cc/test/data/yuv_stripes.png View 1 2 Binary file 0 comments Download
M cc/test/data/yuv_stripes_alpha.png View 1 2 Binary file 0 comments Download
M cc/test/data/yuv_stripes_clipped.png View 1 2 Binary file 0 comments Download
A cc/test/data/yuv_stripes_clipped_rgba.png View 1 2 Binary file 0 comments Download
M cc/test/data/yuv_stripes_offset.png View 1 2 Binary file 0 comments Download
A cc/test/data/yuv_stripes_rgba.png View 1 2 Binary file 0 comments Download
M cc/test/render_pass_test_utils.cc View 1 2 3 4 1 chunk +2 lines, -1 line 0 comments Download
M cc/test/test_in_process_context_provider.h View 1 2 2 chunks +10 lines, -0 lines 0 comments Download
M cc/test/test_in_process_context_provider.cc View 1 2 1 chunk +4 lines, -0 lines 0 comments Download
M components/test_runner/test_plugin.cc View 1 2 3 4 1 chunk +3 lines, -1 line 0 comments Download
M content/browser/renderer_host/delegated_frame_host.cc View 1 2 3 4 5 6 7 1 chunk +2 lines, -1 line 0 comments Download
M media/renderers/skcanvas_video_renderer.h View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M media/renderers/skcanvas_video_renderer.cc View 1 2 3 4 5 6 7 4 chunks +70 lines, -55 lines 0 comments Download
M third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp View 1 2 3 4 5 6 7 1 chunk +4 lines, -1 line 0 comments Download

Messages

Total messages: 76 (54 generated)
dshwang
enne@: could you review? It's because this CL is inspired by your CL. https://codereview.chromium.org/881963002
4 years, 2 months ago (2016-10-14 17:05:15 UTC) #6
enne (OOO)
On 2016/10/14 at 17:05:15, dongseong.hwang wrote: > enne@: could you review? It's because this CL ...
4 years, 2 months ago (2016-10-14 17:54:42 UTC) #14
dshwang
> This all looks reasonable. Could you add a pixel test that includes texture2d > ...
4 years, 2 months ago (2016-10-18 19:14:37 UTC) #22
enne (OOO)
What was wrong with canvas and the plugin test? https://codereview.chromium.org/2418173002/diff/120001/cc/output/renderer_pixeltest.cc File cc/output/renderer_pixeltest.cc (right): https://codereview.chromium.org/2418173002/diff/120001/cc/output/renderer_pixeltest.cc#newcode222 cc/output/renderer_pixeltest.cc:222: ...
4 years, 2 months ago (2016-10-19 19:04:03 UTC) #33
dshwang
enne@, thank you for reviewing. I resolved or replied your comments. Could you review again? ...
4 years, 2 months ago (2016-10-20 18:57:56 UTC) #36
enne (OOO)
https://codereview.chromium.org/2418173002/diff/180001/cc/output/gl_renderer.cc File cc/output/gl_renderer.cc (right): https://codereview.chromium.org/2418173002/diff/180001/cc/output/gl_renderer.cc#newcode2733 cc/output/gl_renderer.cc:2733: if (draw_cache_.tex_clamp_rect_location != -1) { Here's the issue. tex_clamp_rect ...
4 years, 2 months ago (2016-10-20 20:29:51 UTC) #37
dshwang
Hi enne, I replied your comment. It takes time due to different time zone. (I'm ...
4 years, 2 months ago (2016-10-21 13:26:21 UTC) #40
enne (OOO)
Oh, right, sure. The program id would be different and they wouldn't batch together anyway. ...
4 years, 2 months ago (2016-10-21 18:53:05 UTC) #45
dshwang
junov@, could you review WebKit/Canvas ? ccameron@, could you review content/browser ? dpranke@, could you ...
4 years, 1 month ago (2016-10-25 21:11:03 UTC) #47
Justin Novosad
https://codereview.chromium.org/2418173002/diff/200001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp File third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp (right): https://codereview.chromium.org/2418173002/diff/200001/third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp#newcode436 third_party/WebKit/Source/platform/graphics/Canvas2DLayerBridge.cpp:436: false, false); These "false" literals are bad for code ...
4 years, 1 month ago (2016-10-25 21:28:17 UTC) #48
DaleCurtis
media/ lgtm % nits. https://codereview.chromium.org/2418173002/diff/200001/media/renderers/skcanvas_video_renderer.cc File media/renderers/skcanvas_video_renderer.cc (right): https://codereview.chromium.org/2418173002/diff/200001/media/renderers/skcanvas_video_renderer.cc#newcode528 media/renderers/skcanvas_video_renderer.cc:528: if (size_type == SkCanvasVideoRenderer::ConvertingSize::VISUAL) { ...
4 years, 1 month ago (2016-10-25 23:53:38 UTC) #49
dshwang
junov@, could you review WebKit/Canvas ? ccameron@, could you review content/browser ? dpranke@, could you ...
4 years, 1 month ago (2016-10-26 15:26:28 UTC) #52
Dirk Pranke
lgtm
4 years, 1 month ago (2016-10-26 17:51:19 UTC) #55
ccameron
On 2016/10/26 17:51:19, Dirk Pranke (slow) wrote: > lgtm content/browser lgtm
4 years, 1 month ago (2016-10-26 18:30:16 UTC) #56
Justin Novosad
lgtm
4 years, 1 month ago (2016-10-26 19:38:31 UTC) #57
dshwang
Thank you for review! I'll land it after https://codereview.chromium.org/2454153002/ is landed. mac_chromium_rel_ng fails due to ...
4 years, 1 month ago (2016-10-27 18:24:44 UTC) #64
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2418173002/220001
4 years, 1 month ago (2016-10-31 13:15:35 UTC) #69
commit-bot: I haz the power
Committed patchset #8 (id:220001)
4 years, 1 month ago (2016-10-31 14:42:09 UTC) #71
commit-bot: I haz the power
Patchset 8 (id:??) landed as https://crrev.com/b38566a76c4af61c0d34df7d8b906e7936b8e524 Cr-Commit-Position: refs/heads/master@{#428707}
4 years, 1 month ago (2016-10-31 14:43:42 UTC) #73
xidachen
A revert of this CL (patchset #8 id:220001) has been created in https://codereview.chromium.org/2463103002/ by xidachen@chromium.org. ...
4 years, 1 month ago (2016-10-31 16:26:07 UTC) #74
dshwang
On 2016/10/31 16:26:07, xidachen wrote: > A revert of this CL (patchset #8 id:220001) has ...
4 years, 1 month ago (2016-10-31 17:47:29 UTC) #75
ynovikov
4 years, 1 month ago (2016-10-31 17:54:04 UTC) #76
Message was sent while issue was closed.
On 2016/10/31 17:47:29, dshwang wrote:
> On 2016/10/31 16:26:07, xidachen wrote:
> > A revert of this CL (patchset #8 id:220001) has been created in
> > https://codereview.chromium.org/2463103002/ by mailto:xidachen@chromium.org.
> > 
> > The reason for reverting is: Suspect causing cc_unittests failure:
> >
>
https://build.chromium.org/p/chromium.win/builders/Win7%20Tests%20%28dbg%29%2....
> 
> Thx for reverting. I'm figuring out whether it causes cc_unittests failure. If
> other CL causes the issue, please let me know.

This also causes pixel_test failures on Android GPU.FYI bots. Please update
expectations (reference images) when you reland this.

Powered by Google App Engine
This is Rietveld 408576698