| 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 <deque> | 8 #include <deque> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 260 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 271 DrawingFrame* external_frame); | 271 DrawingFrame* external_frame); |
| 272 | 272 |
| 273 // Setup/flush all pending overdraw feedback to framebuffer. | 273 // Setup/flush all pending overdraw feedback to framebuffer. |
| 274 void SetupOverdrawFeedback(); | 274 void SetupOverdrawFeedback(); |
| 275 void FlushOverdrawFeedback(const DrawingFrame* frame, | 275 void FlushOverdrawFeedback(const DrawingFrame* frame, |
| 276 const gfx::Rect& output_rect); | 276 const gfx::Rect& output_rect); |
| 277 // Process overdraw feedback from query. | 277 // Process overdraw feedback from query. |
| 278 using OverdrawFeedbackCallback = base::Callback<void(unsigned, int)>; | 278 using OverdrawFeedbackCallback = base::Callback<void(unsigned, int)>; |
| 279 void ProcessOverdrawFeedback(std::vector<int>* overdraw, | 279 void ProcessOverdrawFeedback(std::vector<int>* overdraw, |
| 280 size_t num_expected_results, | 280 size_t num_expected_results, |
| 281 int max_result, |
| 281 unsigned query, | 282 unsigned query, |
| 282 int multiplier); | 283 int multiplier); |
| 283 | 284 |
| 284 using OverlayResourceLock = | 285 using OverlayResourceLock = |
| 285 std::unique_ptr<ResourceProvider::ScopedReadLockGL>; | 286 std::unique_ptr<ResourceProvider::ScopedReadLockGL>; |
| 286 using OverlayResourceLockList = std::vector<OverlayResourceLock>; | 287 using OverlayResourceLockList = std::vector<OverlayResourceLock>; |
| 287 | 288 |
| 288 // Resources that have been sent to the GPU process, but not yet swapped. | 289 // Resources that have been sent to the GPU process, but not yet swapped. |
| 289 OverlayResourceLockList pending_overlay_resources_; | 290 OverlayResourceLockList pending_overlay_resources_; |
| 290 | 291 |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 357 // The method FlippedFramebuffer determines whether the framebuffer associated | 358 // The method FlippedFramebuffer determines whether the framebuffer associated |
| 358 // with a DrawingFrame is flipped. It makes the assumption that the | 359 // with a DrawingFrame is flipped. It makes the assumption that the |
| 359 // DrawingFrame is being used as part of a render pass. If a DrawingFrame is | 360 // DrawingFrame is being used as part of a render pass. If a DrawingFrame is |
| 360 // not being used as part of a render pass, setting it here forces | 361 // not being used as part of a render pass, setting it here forces |
| 361 // FlippedFramebuffer to return |true|. | 362 // FlippedFramebuffer to return |true|. |
| 362 bool force_drawing_frame_framebuffer_unflipped_ = false; | 363 bool force_drawing_frame_framebuffer_unflipped_ = false; |
| 363 | 364 |
| 364 BoundGeometry bound_geometry_; | 365 BoundGeometry bound_geometry_; |
| 365 ColorLUTCache color_lut_cache_; | 366 ColorLUTCache color_lut_cache_; |
| 366 | 367 |
| 368 bool use_occlusion_query_; |
| 367 unsigned offscreen_stencil_renderbuffer_id_ = 0; | 369 unsigned offscreen_stencil_renderbuffer_id_ = 0; |
| 368 gfx::Size offscreen_stencil_renderbuffer_size_; | 370 gfx::Size offscreen_stencil_renderbuffer_size_; |
| 369 | 371 |
| 370 base::WeakPtrFactory<GLRenderer> weak_ptr_factory_; | 372 base::WeakPtrFactory<GLRenderer> weak_ptr_factory_; |
| 371 | 373 |
| 372 DISALLOW_COPY_AND_ASSIGN(GLRenderer); | 374 DISALLOW_COPY_AND_ASSIGN(GLRenderer); |
| 373 }; | 375 }; |
| 374 | 376 |
| 375 } // namespace cc | 377 } // namespace cc |
| 376 | 378 |
| 377 #endif // CC_OUTPUT_GL_RENDERER_H_ | 379 #endif // CC_OUTPUT_GL_RENDERER_H_ |
| OLD | NEW |