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

Unified Diff: cc/resources/video_resource_updater.cc

Issue 1414793018: Revert of Converted video frame and image callbacks to use new sync tokens. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | cc/test/test_gpu_memory_buffer_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/video_resource_updater.cc
diff --git a/cc/resources/video_resource_updater.cc b/cc/resources/video_resource_updater.cc
index 3ef6e76c98caff89d8efff04342e9ba083bc7c60..fd3221258de64ece6c64980a144eb95a29f424db 100644
--- a/cc/resources/video_resource_updater.cc
+++ b/cc/resources/video_resource_updater.cc
@@ -75,14 +75,13 @@
const gpu::SyncToken& sync_token)
: gl_(gl), sync_token_(sync_token) {}
~SyncTokenClientImpl() override {}
- void GenerateSyncToken(gpu::SyncToken* sync_token) override {
+ uint32 InsertSyncPoint() override {
if (sync_token_.HasData()) {
- *sync_token = sync_token_;
- } else {
- const uint64_t fence_sync = gl_->InsertFenceSyncCHROMIUM();
- gl_->ShallowFlushCHROMIUM();
- gl_->GenSyncTokenCHROMIUM(fence_sync, sync_token->GetData());
- }
+ DCHECK_EQ(gpu::CommandBufferNamespace::OLD_SYNC_POINTS,
+ sync_token_.namespace_id());
+ return static_cast<uint32>(sync_token_.release_count());
+ }
+ return gl_->InsertSyncPointCHROMIUM();
}
void WaitSyncToken(const gpu::SyncToken& sync_token) override {
if (sync_token.HasData()) {
« no previous file with comments | « no previous file | cc/test/test_gpu_memory_buffer_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698