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

Issue 2095873005: Add SurfaceTexture::release and call it from AVDA. (Closed)

Created:
4 years, 6 months ago by liberato (no reviews please)
Modified:
4 years, 5 months ago
Reviewers:
watk, no sievers
CC:
chromium-reviews, posciak+watch_chromium.org, piman+watch_chromium.org, feature-media-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add SurfaceTexture::release and call it from AVDA. SurfaceTexture::release() discards unused buffers and tears down the SurfaceTexture, leaving only the front buffer if it's bound to a GL texture. This CL plumbs that down to native. This CL also uses it for AVDA, so that back buffers don't take up memory when the deferred strategy is shut down. As part of that, it splits strategy cleanup into two parts. The first is called before flush, while the latter is called after. This prevents transitioning the SurfaceTexture into the released state while the flush is still trying to talk to MediaCodec. It's unclear that would be safe. BUG=619658 Committed: https://crrev.com/2c238bbd17a40008c3d0a2b437f36fd8b0455f0e Cr-Commit-Position: refs/heads/master@{#402187}

Patch Set 1 #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+46 lines, -8 lines) Patch
M media/gpu/android_copying_backing_strategy.h View 1 chunk +2 lines, -1 line 0 comments Download
M media/gpu/android_copying_backing_strategy.cc View 2 chunks +3 lines, -1 line 0 comments Download
M media/gpu/android_deferred_rendering_backing_strategy.h View 1 chunk +2 lines, -1 line 0 comments Download
M media/gpu/android_deferred_rendering_backing_strategy.cc View 1 chunk +13 lines, -1 line 1 comment Download
M media/gpu/android_video_decode_accelerator.h View 1 chunk +7 lines, -3 lines 0 comments Download
M media/gpu/android_video_decode_accelerator.cc View 2 chunks +4 lines, -1 line 0 comments Download
M ui/android/java/src/org/chromium/ui/gl/SurfaceTexturePlatformWrapper.java View 1 chunk +5 lines, -0 lines 0 comments Download
M ui/gl/android/surface_texture.h View 1 chunk +5 lines, -0 lines 0 comments Download
M ui/gl/android/surface_texture.cc View 1 chunk +5 lines, -0 lines 0 comments Download

Messages

Total messages: 21 (10 generated)
liberato (no reviews please)
https://codereview.chromium.org/2095873005/diff/1/media/gpu/android_deferred_rendering_backing_strategy.cc File media/gpu/android_deferred_rendering_backing_strategy.cc (right): https://codereview.chromium.org/2095873005/diff/1/media/gpu/android_deferred_rendering_backing_strategy.cc#newcode83 media/gpu/android_deferred_rendering_backing_strategy.cc:83: surface_texture_->ReleaseSurfaceTexture(); i was on the fence about whether we ...
4 years, 6 months ago (2016-06-24 17:40:20 UTC) #3
watk
Nice! I assume you tested this manually by backgrounding chrome, etc? lgtm
4 years, 6 months ago (2016-06-24 22:04:01 UTC) #4
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/2095873005/1
4 years, 6 months ago (2016-06-24 23:10:18 UTC) #6
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/207133)
4 years, 6 months ago (2016-06-24 23:18:47 UTC) #8
liberato (no reviews please)
sievers, PTAL at surface_texture.* and SurfaceTexturePlatformWrapper.java . i forgot that i modified non-media stuff. watk: ...
4 years, 6 months ago (2016-06-24 23:24:59 UTC) #10
no sievers
On 2016/06/24 23:24:59, liberato wrote: > sievers, PTAL at surface_texture.* and SurfaceTexturePlatformWrapper.java . i > ...
4 years, 6 months ago (2016-06-25 00:03:15 UTC) #11
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/2095873005/1
4 years, 6 months ago (2016-06-25 00:11:43 UTC) #13
commit-bot: I haz the power
Try jobs failed on following builders: win_chromium_rel_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/245375)
4 years, 6 months ago (2016-06-25 00:41:14 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/2095873005/1
4 years, 5 months ago (2016-06-27 14:20:03 UTC) #17
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years, 5 months ago (2016-06-27 15:41:07 UTC) #19
commit-bot: I haz the power
4 years, 5 months ago (2016-06-27 15:45:01 UTC) #21
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/2c238bbd17a40008c3d0a2b437f36fd8b0455f0e
Cr-Commit-Position: refs/heads/master@{#402187}

Powered by Google App Engine
This is Rietveld 408576698