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

Side by Side Diff: ui/gl/gl_surface.h

Issue 320283002: Fix crash when using surfaceless EGL on Android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Fix Mac build issue Created 6 years, 6 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 | « ui/gl/gl_context_android.cc ('k') | ui/gl/gl_surface.cc » ('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 #ifndef UI_GL_GL_SURFACE_H_ 5 #ifndef UI_GL_GL_SURFACE_H_
6 #define UI_GL_GL_SURFACE_H_ 6 #define UI_GL_GL_SURFACE_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 // Swaps front and back buffers. This has no effect for off-screen 50 // Swaps front and back buffers. This has no effect for off-screen
51 // contexts. 51 // contexts.
52 virtual bool SwapBuffers() = 0; 52 virtual bool SwapBuffers() = 0;
53 53
54 // Get the size of the surface. 54 // Get the size of the surface.
55 virtual gfx::Size GetSize() = 0; 55 virtual gfx::Size GetSize() = 0;
56 56
57 // Get the underlying platform specific surface "handle". 57 // Get the underlying platform specific surface "handle".
58 virtual void* GetHandle() = 0; 58 virtual void* GetHandle() = 0;
59 59
60 // Check if this object represents a surface managed by a surrounding
61 // framework rather than a surface managed by Chromium.
62 virtual bool RepresentsNonOwnedSurface();
63
60 // Returns whether or not the surface supports PostSubBuffer. 64 // Returns whether or not the surface supports PostSubBuffer.
61 virtual bool SupportsPostSubBuffer(); 65 virtual bool SupportsPostSubBuffer();
62 66
63 // Returns the internal frame buffer object name if the surface is backed by 67 // Returns the internal frame buffer object name if the surface is backed by
64 // FBO. Otherwise returns 0. 68 // FBO. Otherwise returns 0.
65 virtual unsigned int GetBackingFrameBufferObject(); 69 virtual unsigned int GetBackingFrameBufferObject();
66 70
67 // Copy part of the backbuffer to the frontbuffer. 71 // Copy part of the backbuffer to the frontbuffer.
68 virtual bool PostSubBuffer(int x, int y, int width, int height); 72 virtual bool PostSubBuffer(int x, int y, int width, int height);
69 73
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 168
165 private: 169 private:
166 scoped_refptr<GLSurface> surface_; 170 scoped_refptr<GLSurface> surface_;
167 171
168 DISALLOW_COPY_AND_ASSIGN(GLSurfaceAdapter); 172 DISALLOW_COPY_AND_ASSIGN(GLSurfaceAdapter);
169 }; 173 };
170 174
171 } // namespace gfx 175 } // namespace gfx
172 176
173 #endif // UI_GL_GL_SURFACE_H_ 177 #endif // UI_GL_GL_SURFACE_H_
OLDNEW
« no previous file with comments | « ui/gl/gl_context_android.cc ('k') | ui/gl/gl_surface.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698