Chromium Code Reviews| 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_vector.h" | 10 #include "cc/base/scoped_ptr_vector.h" |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 97 const gfx::QuadF& SharedGeometryQuad() const { return shared_geometry_quad_; } | 97 const gfx::QuadF& SharedGeometryQuad() const { return shared_geometry_quad_; } |
| 98 const GeometryBinding* SharedGeometry() const { | 98 const GeometryBinding* SharedGeometry() const { |
| 99 return shared_geometry_.get(); | 99 return shared_geometry_.get(); |
| 100 } | 100 } |
| 101 | 101 |
| 102 void GetFramebufferPixelsAsync(gfx::Rect rect, | 102 void GetFramebufferPixelsAsync(gfx::Rect rect, |
| 103 scoped_ptr<CopyOutputRequest> request); | 103 scoped_ptr<CopyOutputRequest> request); |
| 104 void GetFramebufferTexture(unsigned texture_id, | 104 void GetFramebufferTexture(unsigned texture_id, |
| 105 ResourceFormat texture_format, | 105 ResourceFormat texture_format, |
| 106 gfx::Rect device_rect); | 106 gfx::Rect device_rect); |
| 107 void GetFramebufferTextureSubImage(unsigned texture_id, | |
| 108 gfx::Point offset, | |
| 109 gfx::Rect device_rect); | |
| 107 void ReleaseRenderPassTextures(); | 110 void ReleaseRenderPassTextures(); |
| 108 | 111 |
| 109 void SetStencilEnabled(bool enabled); | 112 void SetStencilEnabled(bool enabled); |
| 110 bool stencil_enabled() const { return stencil_shadow_; } | 113 bool stencil_enabled() const { return stencil_shadow_; } |
| 111 void SetBlendEnabled(bool enabled); | 114 void SetBlendEnabled(bool enabled); |
| 112 bool blend_enabled() const { return blend_shadow_; } | 115 bool blend_enabled() const { return blend_shadow_; } |
| 113 | 116 |
| 114 virtual void BindFramebufferToOutputSurface(DrawingFrame* frame) OVERRIDE; | 117 virtual void BindFramebufferToOutputSurface(DrawingFrame* frame) OVERRIDE; |
| 115 virtual bool BindFramebufferToTexture(DrawingFrame* frame, | 118 virtual bool BindFramebufferToTexture(DrawingFrame* frame, |
| 116 const ScopedResource* resource, | 119 const ScopedResource* resource, |
| (...skipping 29 matching lines...) Expand all Loading... | |
| 146 private: | 149 private: |
| 147 friend class GLRendererShaderPixelTest; | 150 friend class GLRendererShaderPixelTest; |
| 148 friend class GLRendererShaderTest; | 151 friend class GLRendererShaderTest; |
| 149 | 152 |
| 150 static void ToGLMatrix(float* gl_matrix, const gfx::Transform& transform); | 153 static void ToGLMatrix(float* gl_matrix, const gfx::Transform& transform); |
| 151 | 154 |
| 152 void DrawCheckerboardQuad(const DrawingFrame* frame, | 155 void DrawCheckerboardQuad(const DrawingFrame* frame, |
| 153 const CheckerboardDrawQuad* quad); | 156 const CheckerboardDrawQuad* quad); |
| 154 void DrawDebugBorderQuad(const DrawingFrame* frame, | 157 void DrawDebugBorderQuad(const DrawingFrame* frame, |
| 155 const DebugBorderDrawQuad* quad); | 158 const DebugBorderDrawQuad* quad); |
| 156 scoped_ptr<ScopedResource> DrawBackgroundFilters( | 159 scoped_ptr<ScopedResource> CreateBackgroundTextureWithFilters( |
| 157 DrawingFrame* frame, | 160 DrawingFrame* frame, |
| 158 const RenderPassDrawQuad* quad, | 161 const RenderPassDrawQuad* quad, |
| 159 const gfx::Transform& contents_device_transform, | 162 const gfx::Transform& contents_device_transform, |
| 160 const gfx::Transform& contents_device_transformInverse); | 163 const gfx::Transform& contents_device_transformInverse, |
| 164 bool& background_changed); | |
|
shawnsingh
2013/09/25 05:33:53
We should not use non-const references. Use a poi
rosca
2013/09/25 18:00:00
Done.
| |
| 161 void DrawRenderPassQuad(DrawingFrame* frame, const RenderPassDrawQuad* quad); | 165 void DrawRenderPassQuad(DrawingFrame* frame, const RenderPassDrawQuad* quad); |
| 162 void DrawSolidColorQuad(const DrawingFrame* frame, | 166 void DrawSolidColorQuad(const DrawingFrame* frame, |
| 163 const SolidColorDrawQuad* quad); | 167 const SolidColorDrawQuad* quad); |
| 164 void DrawStreamVideoQuad(const DrawingFrame* frame, | 168 void DrawStreamVideoQuad(const DrawingFrame* frame, |
| 165 const StreamVideoDrawQuad* quad); | 169 const StreamVideoDrawQuad* quad); |
| 166 void EnqueueTextureQuad(const DrawingFrame* frame, | 170 void EnqueueTextureQuad(const DrawingFrame* frame, |
| 167 const TextureDrawQuad* quad); | 171 const TextureDrawQuad* quad); |
| 168 void FlushTextureQuadCache(); | 172 void FlushTextureQuadCache(); |
| 169 void DrawIOSurfaceQuad(const DrawingFrame* frame, | 173 void DrawIOSurfaceQuad(const DrawingFrame* frame, |
| 170 const IOSurfaceDrawQuad* quad); | 174 const IOSurfaceDrawQuad* quad); |
| (...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 469 #if DEBUG_GL_CALLS && !defined(NDEBUG) | 473 #if DEBUG_GL_CALLS && !defined(NDEBUG) |
| 470 #define GLC(context, x) \ | 474 #define GLC(context, x) \ |
| 471 (x, GLRenderer::DebugGLCall(&* context, #x, __FILE__, __LINE__)) | 475 (x, GLRenderer::DebugGLCall(&* context, #x, __FILE__, __LINE__)) |
| 472 #else | 476 #else |
| 473 #define GLC(context, x) (x) | 477 #define GLC(context, x) (x) |
| 474 #endif | 478 #endif |
| 475 | 479 |
| 476 } // namespace cc | 480 } // namespace cc |
| 477 | 481 |
| 478 #endif // CC_OUTPUT_GL_RENDERER_H_ | 482 #endif // CC_OUTPUT_GL_RENDERER_H_ |
| OLD | NEW |