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

Issue 2631263003: [headless] Fix screenshots with gpu enabled. (Closed)

Created:
3 years, 11 months ago by Eric Seckler
Modified:
3 years, 11 months ago
Reviewers:
bsalomon, Sami, jbauman
CC:
chromium-reviews, jam, jbauman+watch_chromium.org, darin-cc_chromium.org, piman+watch_chromium.org, kalyank, danakj+watch_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[headless] Fix screenshots with gpu enabled. Turns out this is due to two things: 1) We were overriding ShouldCreateCompositorFrameSink in the browser compositor to always return false (which is unnecessary). 2) Contrary to what GpuBrowserCompositorOutputSurface and SoftwareBrowserCompositorOutputSurface do, the OffscreenBrowserCompositorOutputSurface wasn't letting the RWHI know about swapped frames. This fixes both issues. BUG=681614 Review-Url: https://codereview.chromium.org/2631263003 Cr-Original-Commit-Position: refs/heads/master@{#444694} Committed: https://chromium.googlesource.com/chromium/src/+/f5077ffe4f7a3d8c053e8bd8b2070bc699ca937f Review-Url: https://codereview.chromium.org/2631263003 Cr-Commit-Position: refs/heads/master@{#444730} Committed: https://chromium.googlesource.com/chromium/src/+/d2869ffcce7a030d6cceabb6f52d3c67f897e06a

Patch Set 1 : . #

Patch Set 2 : add test. #

Patch Set 3 : make test work with gpu compositing, run it for both gpu/software comp. #

Total comments: 2

Patch Set 4 : limit skia dep to test file only. #

Patch Set 5 : add skia dep to build file. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+71 lines, -10 lines) Patch
M content/browser/compositor/gpu_process_transport_factory.cc View 1 chunk +0 lines, -4 lines 0 comments Download
M content/browser/compositor/offscreen_browser_compositor_output_surface.h View 2 chunks +2 lines, -1 line 0 comments Download
M content/browser/compositor/offscreen_browser_compositor_output_surface.cc View 3 chunks +5 lines, -2 lines 0 comments Download
M headless/BUILD.gn View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
A headless/lib/DEPS View 1 2 3 1 chunk +6 lines, -0 lines 0 comments Download
M headless/lib/headless_web_contents_browsertest.cc View 1 2 4 chunks +53 lines, -3 lines 0 comments Download
M headless/test/headless_browser_test.h View 1 2 1 chunk +4 lines, -0 lines 0 comments Download

Messages

Total messages: 29 (17 generated)
Eric Seckler
Sami, PTAL. +John for content/browser/compositor. Thanks!
3 years, 11 months ago (2017-01-18 12:48:41 UTC) #7
Eric Seckler
+bsalomon for dependency on third_party/skia/include.
3 years, 11 months ago (2017-01-18 12:55:53 UTC) #9
Sami
Thanks! headless/ lgtm (other parts too as far as I can tell.) https://codereview.chromium.org/2631263003/diff/60001/headless/lib/headless_web_contents_browsertest.cc File headless/lib/headless_web_contents_browsertest.cc ...
3 years, 11 months ago (2017-01-18 13:57:37 UTC) #12
bsalomon
lgtm
3 years, 11 months ago (2017-01-18 14:28:01 UTC) #13
Eric Seckler
https://codereview.chromium.org/2631263003/diff/60001/headless/lib/headless_web_contents_browsertest.cc File headless/lib/headless_web_contents_browsertest.cc (right): https://codereview.chromium.org/2631263003/diff/60001/headless/lib/headless_web_contents_browsertest.cc#newcode69 headless/lib/headless_web_contents_browsertest.cc:69: return gfx::PNGCodec::Decode( On 2017/01/18 13:57:37, Sami wrote: > FWIW ...
3 years, 11 months ago (2017-01-18 19:22:51 UTC) #14
jbauman
lgtm
3 years, 11 months ago (2017-01-19 00:18:06 UTC) #15
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/2631263003/100001
3 years, 11 months ago (2017-01-19 09:08:25 UTC) #18
commit-bot: I haz the power
Committed patchset #5 (id:100001) as https://chromium.googlesource.com/chromium/src/+/f5077ffe4f7a3d8c053e8bd8b2070bc699ca937f
3 years, 11 months ago (2017-01-19 10:14:03 UTC) #21
Mike West
A revert of this CL (patchset #5 id:100001) has been created in https://codereview.chromium.org/2641073004/ by mkwst@chromium.org. ...
3 years, 11 months ago (2017-01-19 13:37:24 UTC) #22
Eric Seckler
On 2017/01/19 13:37:24, Mike West (sloooooow) wrote: > A revert of this CL (patchset #5 ...
3 years, 11 months ago (2017-01-19 14:41:53 UTC) #23
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/2631263003/100001
3 years, 11 months ago (2017-01-19 14:42:29 UTC) #26
commit-bot: I haz the power
3 years, 11 months ago (2017-01-19 14:46:57 UTC) #29
Message was sent while issue was closed.
Committed patchset #5 (id:100001) as
https://chromium.googlesource.com/chromium/src/+/d2869ffcce7a030d6cceabb6f52d...

Powered by Google App Engine
This is Rietveld 408576698