OLD | NEW |
1 // Copyright 2010 The Chromium Authors. All rights reserved. | 1 // Copyright 2010 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 CC_OUTPUT_GL_RENDERER_H_ | 5 #ifndef CC_OUTPUT_GL_RENDERER_H_ |
6 #define CC_OUTPUT_GL_RENDERER_H_ | 6 #define CC_OUTPUT_GL_RENDERER_H_ |
7 | 7 |
8 #include "base/cancelable_callback.h" | 8 #include "base/cancelable_callback.h" |
9 #include "cc/base/cc_export.h" | 9 #include "cc/base/cc_export.h" |
10 #include "cc/base/scoped_ptr_deque.h" | 10 #include "cc/base/scoped_ptr_deque.h" |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 virtual const RendererCapabilitiesImpl& Capabilities() const OVERRIDE; | 60 virtual const RendererCapabilitiesImpl& Capabilities() const OVERRIDE; |
61 | 61 |
62 // Waits for rendering to finish. | 62 // Waits for rendering to finish. |
63 virtual void Finish() OVERRIDE; | 63 virtual void Finish() OVERRIDE; |
64 | 64 |
65 virtual void DoNoOp() OVERRIDE; | 65 virtual void DoNoOp() OVERRIDE; |
66 virtual void SwapBuffers(const CompositorFrameMetadata& metadata) OVERRIDE; | 66 virtual void SwapBuffers(const CompositorFrameMetadata& metadata) OVERRIDE; |
67 | 67 |
68 virtual bool IsContextLost() OVERRIDE; | 68 virtual bool IsContextLost() OVERRIDE; |
69 | 69 |
70 virtual void SendManagedMemoryStats(size_t bytes_visible, | |
71 size_t bytes_visible_and_nearby, | |
72 size_t bytes_allocated) OVERRIDE; | |
73 | |
74 static void DebugGLCall(gpu::gles2::GLES2Interface* gl, | 70 static void DebugGLCall(gpu::gles2::GLES2Interface* gl, |
75 const char* command, | 71 const char* command, |
76 const char* file, | 72 const char* file, |
77 int line); | 73 int line); |
78 | 74 |
79 protected: | 75 protected: |
80 GLRenderer(RendererClient* client, | 76 GLRenderer(RendererClient* client, |
81 const LayerTreeSettings* settings, | 77 const LayerTreeSettings* settings, |
82 OutputSurface* output_surface, | 78 OutputSurface* output_surface, |
83 ResourceProvider* resource_provider, | 79 ResourceProvider* resource_provider, |
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
440 #if DEBUG_GL_CALLS && !defined(NDEBUG) | 436 #if DEBUG_GL_CALLS && !defined(NDEBUG) |
441 #define GLC(context, x) \ | 437 #define GLC(context, x) \ |
442 (x, GLRenderer::DebugGLCall(&* context, #x, __FILE__, __LINE__)) | 438 (x, GLRenderer::DebugGLCall(&* context, #x, __FILE__, __LINE__)) |
443 #else | 439 #else |
444 #define GLC(context, x) (x) | 440 #define GLC(context, x) (x) |
445 #endif | 441 #endif |
446 | 442 |
447 } // namespace cc | 443 } // namespace cc |
448 | 444 |
449 #endif // CC_OUTPUT_GL_RENDERER_H_ | 445 #endif // CC_OUTPUT_GL_RENDERER_H_ |
OLD | NEW |