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

Unified Diff: components/pdf_viewer/pdf_viewer.cc

Issue 1427543002: Modified old wait sync point functions to also accept new sync tokens. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: format 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 | « components/mus/public/interfaces/compositor_frame.mojom ('k') | components/test_runner/test_plugin.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/pdf_viewer/pdf_viewer.cc
diff --git a/components/pdf_viewer/pdf_viewer.cc b/components/pdf_viewer/pdf_viewer.cc
index 0934fab36aaa531f8b309247d991f4967c5be273..b62a7dd45ce7fa69cdfb9a4c9b34147a1f0c3afd 100644
--- a/components/pdf_viewer/pdf_viewer.cc
+++ b/components/pdf_viewer/pdf_viewer.cc
@@ -159,7 +159,7 @@ class BitmapUploader : public mus::mojom::SurfaceClient {
GLbyte mailbox[GL_MAILBOX_SIZE_CHROMIUM];
glGenMailboxCHROMIUM(mailbox);
glProduceTextureCHROMIUM(GL_TEXTURE_2D, mailbox);
- GLuint sync_point = glInsertSyncPointCHROMIUM();
+ gpu::SyncToken sync_token(glInsertSyncPointCHROMIUM());
mus::mojom::TransferableResourcePtr resource =
mus::mojom::TransferableResource::New();
@@ -174,7 +174,8 @@ class BitmapUploader : public mus::mojom::SurfaceClient {
for (int i = 0; i < GL_MAILBOX_SIZE_CHROMIUM; ++i)
mailbox_holder->mailbox->name.push_back(mailbox[i]);
mailbox_holder->texture_target = GL_TEXTURE_2D;
- mailbox_holder->sync_point = sync_point;
+ mailbox_holder->sync_token =
+ mus::mojom::SyncToken::From<gpu::SyncToken>(sync_token);
resource->mailbox_holder = mailbox_holder.Pass();
resource->is_repeated = false;
resource->is_software = false;
@@ -285,7 +286,8 @@ class BitmapUploader : public mus::mojom::SurfaceClient {
for (size_t i = 0; i < resources.size(); ++i) {
mus::mojom::ReturnedResourcePtr resource = resources[i].Pass();
DCHECK_EQ(1, resource->count);
- glWaitSyncPointCHROMIUM(resource->sync_point);
+ glWaitSyncTokenCHROMIUM(
+ resource->sync_token.To<gpu::SyncToken>().GetConstData());
uint32_t texture_id = resource_to_texture_id_map_[resource->id];
DCHECK_NE(0u, texture_id);
resource_to_texture_id_map_.erase(resource->id);
« no previous file with comments | « components/mus/public/interfaces/compositor_frame.mojom ('k') | components/test_runner/test_plugin.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698