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

Unified Diff: ppapi/shared_impl/ppb_video_decoder_shared.cc

Issue 11781004: Tell Graphics3D not to lock on Flush(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 11 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
« no previous file with comments | « ppapi/shared_impl/ppb_graphics_3d_shared.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ppapi/shared_impl/ppb_video_decoder_shared.cc
===================================================================
--- ppapi/shared_impl/ppb_video_decoder_shared.cc (revision 175266)
+++ ppapi/shared_impl/ppb_video_decoder_shared.cc (working copy)
@@ -7,6 +7,7 @@
#include "base/logging.h"
#include "gpu/command_buffer/client/gles2_implementation.h"
#include "ppapi/c/pp_errors.h"
+#include "ppapi/shared_impl/ppb_graphics_3d_shared.h"
#include "ppapi/shared_impl/resource_tracker.h"
#include "ppapi/thunk/enter.h"
@@ -90,8 +91,16 @@
}
void PPB_VideoDecoder_Shared::FlushCommandBuffer() {
- if (gles2_impl_)
+ if (gles2_impl_) {
Scott Hess - ex-Googler 2013/01/07 22:41:02 This looks broadly like what I expected it to look
+ // To call Flush() we have to tell Graphics3D that we hold the proxy lock.
+ thunk::EnterResource<thunk::PPB_Graphics3D_API, false> enter_g3d(
+ graphics_context_, false);
+ DCHECK(enter_g3d.succeeded());
+ PPB_Graphics3D_Shared* graphics3d =
+ static_cast<PPB_Graphics3D_Shared*>(enter_g3d.object());
+ PPB_Graphics3D_Shared::ScopedNoLocking dont_lock(graphics3d);
gles2_impl_->Flush();
+ }
}
} // namespace ppapi
« no previous file with comments | « ppapi/shared_impl/ppb_graphics_3d_shared.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698