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

Unified Diff: content/renderer/pepper/pepper_platform_context_3d.cc

Issue 185363009: ppapi: Send sync point whenever the pepper texture changes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: pepper: negates Created 6 years, 10 months 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
Index: content/renderer/pepper/pepper_platform_context_3d.cc
diff --git a/content/renderer/pepper/pepper_platform_context_3d.cc b/content/renderer/pepper/pepper_platform_context_3d.cc
index a10a221efb067327f2150e902575bd7cb6d0c962..3d46f330e444a6220d004f9abe00fe56b23ed4d5 100644
--- a/content/renderer/pepper/pepper_platform_context_3d.cc
+++ b/content/renderer/pepper/pepper_platform_context_3d.cc
@@ -104,6 +104,7 @@ bool PlatformContext3D::Init(const int32* attrib_list,
if (!command_buffer_->ProduceFrontBuffer(mailbox))
return false;
mailbox_ = mailbox;
+ sync_point_ = command_buffer_->InsertSyncPoint();
command_buffer_->SetChannelErrorCallback(
base::Bind(&PlatformContext3D::OnContextLost,
@@ -115,8 +116,15 @@ bool PlatformContext3D::Init(const int32* attrib_list,
return true;
}
-void PlatformContext3D::GetBackingMailbox(gpu::Mailbox* mailbox) {
+void PlatformContext3D::GetBackingMailbox(gpu::Mailbox* mailbox,
+ uint32* sync_point) {
*mailbox = mailbox_;
+ *sync_point = sync_point_;
+}
+
+void PlatformContext3D::InsertSyncPointForBackingMailbox() {
+ DCHECK(command_buffer_);
+ sync_point_ = command_buffer_->InsertSyncPoint();
}
bool PlatformContext3D::IsOpaque() {
« no previous file with comments | « content/renderer/pepper/pepper_platform_context_3d.h ('k') | content/renderer/pepper/pepper_plugin_instance_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698