summaryrefslogtreecommitdiffstats
path: root/media/renderers
diff options
context:
space:
mode:
authordyen <dyen@chromium.org>2015-11-06 09:40:56 -0800
committerCommit bot <commit-bot@chromium.org>2015-11-06 17:41:38 +0000
commitac45ecf7a20d34d0f120f78eeca004c12c7f7fd6 (patch)
tree266ef634722bb24bbbaa655244855ce2a2c93934 /media/renderers
parentb6a52da3a216a32f4092aaf8b5c591832d9cdd22 (diff)
downloadchromium_src-ac45ecf7a20d34d0f120f78eeca004c12c7f7fd6.zip
chromium_src-ac45ecf7a20d34d0f120f78eeca004c12c7f7fd6.tar.gz
chromium_src-ac45ecf7a20d34d0f120f78eeca004c12c7f7fd6.tar.bz2
Re-land: Converted video frame and image callbacks to use new sync tokens.
This reverts commit a1ab22a90140fe9e6c669998f3efc52795e569e2. Original issue's description: > Converted video frame and image callbacks to use new sync tokens. > > As an incremental step towards utilizing the new sync tokens, this > CL converts existing video frame and image sync points to use > sync tokens instead. > > In order to accomplish this, the GpuCommandBufferMsg_CreateImage > IPC message has been modified to accept a fence_release parameter > so that it can act as a sync token IPC. > > A new SyncPointClientWaiter concept has also added which can wait > on other sync point clients without an associated order number. > This only works because the SyncPointClientWaiter cannot be waited > on so no deadlocks can occur. > > BUG=514815 > CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel > > Committed: https://crrev.com/c7aff68a0c11820cc2b8d488851c682c0d32cd2b > Cr-Commit-Position: refs/heads/master@{#357997} BUG=514815 CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel Review URL: https://codereview.chromium.org/1427893003 Cr-Commit-Position: refs/heads/master@{#358346}
Diffstat (limited to 'media/renderers')
-rw-r--r--media/renderers/skcanvas_video_renderer.cc6
1 files changed, 5 insertions, 1 deletions
diff --git a/media/renderers/skcanvas_video_renderer.cc b/media/renderers/skcanvas_video_renderer.cc
index 675839b..d2f25d6 100644
--- a/media/renderers/skcanvas_video_renderer.cc
+++ b/media/renderers/skcanvas_video_renderer.cc
@@ -63,7 +63,11 @@ class SyncTokenClientImpl : public VideoFrame::SyncTokenClient {
public:
explicit SyncTokenClientImpl(gpu::gles2::GLES2Interface* gl) : gl_(gl) {}
~SyncTokenClientImpl() override {}
- uint32 InsertSyncPoint() override { return gl_->InsertSyncPointCHROMIUM(); }
+ void GenerateSyncToken(gpu::SyncToken* sync_token) override {
+ const uint64_t fence_sync = gl_->InsertFenceSyncCHROMIUM();
+ gl_->ShallowFlushCHROMIUM();
+ gl_->GenSyncTokenCHROMIUM(fence_sync, sync_token->GetData());
+ }
void WaitSyncToken(const gpu::SyncToken& sync_token) override {
gl_->WaitSyncTokenCHROMIUM(sync_token.GetConstData());
}