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

Side by Side Diff: ui/gl/gl_surface_egl.cc

Issue 207443007: Blacklist partial swaps on linux (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix nit Created 6 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 | Annotate | Revision Log
« no previous file with comments | « ui/gl/gl_surface_egl.h ('k') | ui/gl/gl_surface_glx.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 // This include must be here so that the includes provided transitively 5 // This include must be here so that the includes provided transitively
6 // by gl_surface_egl.h don't make it impossible to compile this code. 6 // by gl_surface_egl.h don't make it impossible to compile this code.
7 #include "third_party/mesa/src/include/GL/osmesa.h" 7 #include "third_party/mesa/src/include/GL/osmesa.h"
8 8
9 #include "ui/gl/gl_surface_egl.h" 9 #include "ui/gl/gl_surface_egl.h"
10 10
(...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after
552 LOG(ERROR) << "Failed to create surface."; 552 LOG(ERROR) << "Failed to create surface.";
553 return false; 553 return false;
554 } 554 }
555 return true; 555 return true;
556 } 556 }
557 557
558 EGLSurface NativeViewGLSurfaceEGL::GetHandle() { 558 EGLSurface NativeViewGLSurfaceEGL::GetHandle() {
559 return surface_; 559 return surface_;
560 } 560 }
561 561
562 std::string NativeViewGLSurfaceEGL::GetExtensions() { 562 bool NativeViewGLSurfaceEGL::SupportsPostSubBuffer() {
563 std::string extensions = GLSurface::GetExtensions(); 563 return supports_post_sub_buffer_;
564 if (supports_post_sub_buffer_) {
565 extensions += extensions.empty() ? "" : " ";
566 extensions += "GL_CHROMIUM_post_sub_buffer";
567 }
568 return extensions;
569 } 564 }
570 565
571 bool NativeViewGLSurfaceEGL::PostSubBuffer( 566 bool NativeViewGLSurfaceEGL::PostSubBuffer(
572 int x, int y, int width, int height) { 567 int x, int y, int width, int height) {
573 DCHECK(supports_post_sub_buffer_); 568 DCHECK(supports_post_sub_buffer_);
574 if (!eglPostSubBufferNV(GetDisplay(), surface_, x, y, width, height)) { 569 if (!eglPostSubBufferNV(GetDisplay(), surface_, x, y, width, height)) {
575 DVLOG(1) << "eglPostSubBufferNV failed with error " 570 DVLOG(1) << "eglPostSubBufferNV failed with error "
576 << GetLastEGLErrorString(); 571 << GetLastEGLErrorString();
577 return false; 572 return false;
578 } 573 }
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after
867 } 862 }
868 default: 863 default:
869 NOTREACHED(); 864 NOTREACHED();
870 return NULL; 865 return NULL;
871 } 866 }
872 } 867 }
873 868
874 #endif 869 #endif
875 870
876 } // namespace gfx 871 } // namespace gfx
OLDNEW
« no previous file with comments | « ui/gl/gl_surface_egl.h ('k') | ui/gl/gl_surface_glx.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698