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

Side by Side Diff: ppapi/proxy/ppb_graphics_3d_proxy.cc

Issue 1801493003: Fix ppb_graphics_3d such that the thunk can be generated again (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
« no previous file with comments | « no previous file | ppapi/shared_impl/ppb_graphics_3d_shared.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "ppapi/proxy/ppb_graphics_3d_proxy.h" 5 #include "ppapi/proxy/ppb_graphics_3d_proxy.h"
6 6
7 #include "base/numerics/safe_conversions.h" 7 #include "base/numerics/safe_conversions.h"
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 #include "gpu/command_buffer/client/gles2_implementation.h" 9 #include "gpu/command_buffer/client/gles2_implementation.h"
10 #include "gpu/command_buffer/common/command_buffer.h" 10 #include "gpu/command_buffer/common/command_buffer.h"
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after
334 if (enter.succeeded()) 334 if (enter.succeeded())
335 enter.object()->DestroyTransferBuffer(id); 335 enter.object()->DestroyTransferBuffer(id);
336 } 336 }
337 337
338 void PPB_Graphics3D_Proxy::OnMsgSwapBuffers(const HostResource& context, 338 void PPB_Graphics3D_Proxy::OnMsgSwapBuffers(const HostResource& context,
339 const gpu::SyncToken& sync_token) { 339 const gpu::SyncToken& sync_token) {
340 EnterHostFromHostResourceForceCallback<PPB_Graphics3D_API> enter( 340 EnterHostFromHostResourceForceCallback<PPB_Graphics3D_API> enter(
341 context, callback_factory_, 341 context, callback_factory_,
342 &PPB_Graphics3D_Proxy::SendSwapBuffersACKToPlugin, context); 342 &PPB_Graphics3D_Proxy::SendSwapBuffersACKToPlugin, context);
343 if (enter.succeeded()) 343 if (enter.succeeded())
344 enter.SetResult(enter.object()->SwapBuffers(enter.callback(), sync_token)); 344 enter.SetResult(
345 enter.object()->SwapBuffersWithSyncToken(enter.callback(), sync_token));
345 } 346 }
346 347
347 void PPB_Graphics3D_Proxy::OnMsgEnsureWorkVisible(const HostResource& context) { 348 void PPB_Graphics3D_Proxy::OnMsgEnsureWorkVisible(const HostResource& context) {
348 EnterHostFromHostResource<PPB_Graphics3D_API> enter(context); 349 EnterHostFromHostResource<PPB_Graphics3D_API> enter(context);
349 if (enter.succeeded()) 350 if (enter.succeeded())
350 enter.object()->EnsureWorkVisible(); 351 enter.object()->EnsureWorkVisible();
351 } 352 }
352 #endif // !defined(OS_NACL) 353 #endif // !defined(OS_NACL)
353 354
354 void PPB_Graphics3D_Proxy::OnMsgSwapBuffersACK(const HostResource& resource, 355 void PPB_Graphics3D_Proxy::OnMsgSwapBuffersACK(const HostResource& resource,
355 int32_t pp_error) { 356 int32_t pp_error) {
356 EnterPluginFromHostResource<PPB_Graphics3D_API> enter(resource); 357 EnterPluginFromHostResource<PPB_Graphics3D_API> enter(resource);
357 if (enter.succeeded()) 358 if (enter.succeeded())
358 static_cast<Graphics3D*>(enter.object())->SwapBuffersACK(pp_error); 359 static_cast<Graphics3D*>(enter.object())->SwapBuffersACK(pp_error);
359 } 360 }
360 361
361 #if !defined(OS_NACL) 362 #if !defined(OS_NACL)
362 void PPB_Graphics3D_Proxy::SendSwapBuffersACKToPlugin( 363 void PPB_Graphics3D_Proxy::SendSwapBuffersACKToPlugin(
363 int32_t result, 364 int32_t result,
364 const HostResource& context) { 365 const HostResource& context) {
365 dispatcher()->Send(new PpapiMsg_PPBGraphics3D_SwapBuffersACK( 366 dispatcher()->Send(new PpapiMsg_PPBGraphics3D_SwapBuffersACK(
366 API_ID_PPB_GRAPHICS_3D, context, result)); 367 API_ID_PPB_GRAPHICS_3D, context, result));
367 } 368 }
368 #endif // !defined(OS_NACL) 369 #endif // !defined(OS_NACL)
369 370
370 } // namespace proxy 371 } // namespace proxy
371 } // namespace ppapi 372 } // namespace ppapi
OLDNEW
« no previous file with comments | « no previous file | ppapi/shared_impl/ppb_graphics_3d_shared.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698