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

Side by Side Diff: content/renderer/gpu/webgraphicscontext3d_command_buffer_impl.cc

Issue 7458010: Revert 93066 - Execute all GL commands up to the put offset reported by a each flush.This means g... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 5 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #if defined(ENABLE_GPU) 5 #if defined(ENABLE_GPU)
6 6
7 #include "content/renderer/gpu/webgraphicscontext3d_command_buffer_impl.h" 7 #include "content/renderer/gpu/webgraphicscontext3d_command_buffer_impl.h"
8 8
9 #include <GLES2/gl2.h> 9 #include <GLES2/gl2.h>
10 #ifndef GL_GLEXT_PROTOTYPES 10 #ifndef GL_GLEXT_PROTOTYPES
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 if (!context_->GetChildToParentLatch(latch_id)) { 353 if (!context_->GetChildToParentLatch(latch_id)) {
354 LOG(ERROR) << "getLatch must only be called on child context"; 354 LOG(ERROR) << "getLatch must only be called on child context";
355 synthesizeGLError(GL_INVALID_OPERATION); 355 synthesizeGLError(GL_INVALID_OPERATION);
356 *latch_id = gpu::kInvalidLatchId; 356 *latch_id = gpu::kInvalidLatchId;
357 } 357 }
358 } 358 }
359 359
360 void WebGraphicsContext3DCommandBufferImpl::waitLatchCHROMIUM( 360 void WebGraphicsContext3DCommandBufferImpl::waitLatchCHROMIUM(
361 WGC3Duint latch_id) 361 WGC3Duint latch_id)
362 { 362 {
363 TRACE_EVENT1("gpu", "WebGfxCtx3DCmdBfrImpl::WaitLatch", "latch_id", latch_id);
364 gl_->WaitLatchCHROMIUM(latch_id);
363 } 365 }
364 366
365 void WebGraphicsContext3DCommandBufferImpl::setLatchCHROMIUM( 367 void WebGraphicsContext3DCommandBufferImpl::setLatchCHROMIUM(
366 WGC3Duint latch_id) 368 WGC3Duint latch_id)
367 { 369 {
370 TRACE_EVENT1("gpu", "WebGfxCtx3DCmdBfrImpl::SetLatch", "latch_id", latch_id);
371 gl_->SetLatchCHROMIUM(latch_id);
372 // required to ensure set command is sent to GPU process
373 gl_->Flush();
368 } 374 }
369 375
370 void WebGraphicsContext3DCommandBufferImpl:: 376 void WebGraphicsContext3DCommandBufferImpl::
371 rateLimitOffscreenContextCHROMIUM() { 377 rateLimitOffscreenContextCHROMIUM() {
372 gl_->RateLimitOffscreenContextCHROMIUM(); 378 gl_->RateLimitOffscreenContextCHROMIUM();
373 } 379 }
374 380
375 WebKit::WebString WebGraphicsContext3DCommandBufferImpl:: 381 WebKit::WebString WebGraphicsContext3DCommandBufferImpl::
376 getRequestableExtensionsCHROMIUM() { 382 getRequestableExtensionsCHROMIUM() {
377 return WebKit::WebString::fromUTF8( 383 return WebKit::WebString::fromUTF8(
(...skipping 671 matching lines...) Expand 10 before | Expand all | Expand 10 after
1049 context_lost_callback_->onContextLost(); 1055 context_lost_callback_->onContextLost();
1050 } 1056 }
1051 1057
1052 RenderView* renderview = 1058 RenderView* renderview =
1053 web_view_ ? RenderView::FromWebView(web_view_) : NULL; 1059 web_view_ ? RenderView::FromWebView(web_view_) : NULL;
1054 if (renderview) 1060 if (renderview)
1055 renderview->OnViewContextSwapBuffersAborted(); 1061 renderview->OnViewContextSwapBuffersAborted();
1056 } 1062 }
1057 1063
1058 #endif // defined(ENABLE_GPU) 1064 #endif // defined(ENABLE_GPU)
OLDNEW
« no previous file with comments | « content/renderer/gpu/command_buffer_proxy.cc ('k') | gpu/command_buffer/build_gles2_cmd_buffer.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698