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

Side by Side Diff: gpu/command_buffer/client/share_group.cc

Issue 1001833005: Update from https://crrev.com/320343 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Supress Created 5 years, 9 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <stack> 5 #include <stack>
6 #include <vector> 6 #include <vector>
7 7
8 #include "gpu/command_buffer/client/share_group.h" 8 #include "gpu/command_buffer/client/share_group.h"
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 DeleteFn delete_fn) override { 53 DeleteFn delete_fn) override {
54 base::AutoLock auto_lock(lock_); 54 base::AutoLock auto_lock(lock_);
55 55
56 for (GLsizei ii = 0; ii < n; ++ii) { 56 for (GLsizei ii = 0; ii < n; ++ii) {
57 id_allocator_.FreeID(ids[ii]); 57 id_allocator_.FreeID(ids[ii]);
58 } 58 }
59 59
60 (gl_impl->*delete_fn)(n, ids); 60 (gl_impl->*delete_fn)(n, ids);
61 // We need to ensure that the delete call is evaluated on the service side 61 // We need to ensure that the delete call is evaluated on the service side
62 // before any other contexts issue commands using these client ids. 62 // before any other contexts issue commands using these client ids.
63 // TODO(vmiura): Can remove this by virtualizing internal ids, however 63 gl_impl->helper()->CommandBufferHelper::OrderingBarrier();
64 // this code only affects PPAPI for now.
65 gl_impl->helper()->CommandBufferHelper::Flush();
66 return true; 64 return true;
67 } 65 }
68 66
69 // Overridden from IdHandlerInterface. 67 // Overridden from IdHandlerInterface.
70 bool MarkAsUsedForBind(GLES2Implementation* gl_impl, 68 bool MarkAsUsedForBind(GLES2Implementation* gl_impl,
71 GLenum target, 69 GLenum target,
72 GLuint id, 70 GLuint id,
73 BindFn bind_fn) override { 71 BindFn bind_fn) override {
74 base::AutoLock auto_lock(lock_); 72 base::AutoLock auto_lock(lock_);
75 bool result = id ? id_allocator_.MarkAsUsed(id) : true; 73 bool result = id ? id_allocator_.MarkAsUsed(id) : true;
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after
342 } 340 }
343 341
344 void ShareGroup::set_program_info_manager(ProgramInfoManager* manager) { 342 void ShareGroup::set_program_info_manager(ProgramInfoManager* manager) {
345 program_info_manager_.reset(manager); 343 program_info_manager_.reset(manager);
346 } 344 }
347 345
348 ShareGroup::~ShareGroup() {} 346 ShareGroup::~ShareGroup() {}
349 347
350 } // namespace gles2 348 } // namespace gles2
351 } // namespace gpu 349 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/command_buffer/client/gles2_trace_implementation_impl_autogen.h ('k') | gpu/command_buffer/cmd_buffer_functions.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698