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
3 // found in the LICENSE file.
5 #ifndef CC_OUTPUT_GL_RENDERER_H_
6 #define CC_OUTPUT_GL_RENDERER_H_
8 #include "base/cancelable_callback.h"
9 #include "cc/base/cc_export.h"
10 #include "cc/base/scoped_ptr_deque.h"
11 #include "cc/base/scoped_ptr_vector.h"
12 #include "cc/output/direct_renderer.h"
13 #include "cc/output/gl_renderer_draw_cache.h"
14 #include "cc/output/program_binding.h"
15 #include "cc/output/renderer.h"
16 #include "cc/quads/checkerboard_draw_quad.h"
17 #include "cc/quads/debug_border_draw_quad.h"
18 #include "cc/quads/io_surface_draw_quad.h"
19 #include "cc/quads/render_pass_draw_quad.h"
20 #include "cc/quads/solid_color_draw_quad.h"
21 #include "cc/quads/tile_draw_quad.h"
22 #include "cc/quads/yuv_video_draw_quad.h"
23 #include "ui/gfx/geometry/quad_f.h"
35 class GLRendererShaderTest
;
37 class PictureDrawQuad
;
39 class StreamVideoDrawQuad
;
40 class TextureDrawQuad
;
41 class TextureMailboxDeleter
;
42 class StaticGeometryBinding
;
43 class DynamicGeometryBinding
;
44 class ScopedEnsureFramebufferAllocation
;
46 // Class that handles drawing of composited render layers using GL.
47 class CC_EXPORT GLRenderer
: public DirectRenderer
{
49 class ScopedUseGrContext
;
51 static scoped_ptr
<GLRenderer
> Create(
52 RendererClient
* client
,
53 const RendererSettings
* settings
,
54 OutputSurface
* output_surface
,
55 ResourceProvider
* resource_provider
,
56 TextureMailboxDeleter
* texture_mailbox_deleter
,
57 int highp_threshold_min
);
59 ~GLRenderer() override
;
61 const RendererCapabilitiesImpl
& Capabilities() const override
;
63 // Waits for rendering to finish.
64 void Finish() override
;
66 void DoNoOp() override
;
67 void SwapBuffers(const CompositorFrameMetadata
& metadata
) override
;
69 virtual bool IsContextLost();
72 GLRenderer(RendererClient
* client
,
73 const RendererSettings
* settings
,
74 OutputSurface
* output_surface
,
75 ResourceProvider
* resource_provider
,
76 TextureMailboxDeleter
* texture_mailbox_deleter
,
77 int highp_threshold_min
);
79 void DidChangeVisibility() override
;
81 bool IsBackbufferDiscarded() const { return is_backbuffer_discarded_
; }
83 const gfx::QuadF
& SharedGeometryQuad() const { return shared_geometry_quad_
; }
84 const StaticGeometryBinding
* SharedGeometry() const {
85 return shared_geometry_
.get();
88 void GetFramebufferPixelsAsync(const DrawingFrame
* frame
,
89 const gfx::Rect
& rect
,
90 scoped_ptr
<CopyOutputRequest
> request
);
91 void GetFramebufferTexture(unsigned texture_id
,
92 ResourceFormat texture_format
,
93 const gfx::Rect
& device_rect
);
94 void ReleaseRenderPassTextures();
95 enum BoundGeometry
{ NO_BINDING
, SHARED_BINDING
, CLIPPED_BINDING
};
96 void PrepareGeometry(BoundGeometry geometry_to_bind
);
97 void SetStencilEnabled(bool enabled
);
98 bool stencil_enabled() const { return stencil_shadow_
; }
99 void SetBlendEnabled(bool enabled
);
100 bool blend_enabled() const { return blend_shadow_
; }
102 void BindFramebufferToOutputSurface(DrawingFrame
* frame
) override
;
103 bool BindFramebufferToTexture(DrawingFrame
* frame
,
104 const ScopedResource
* resource
,
105 const gfx::Rect
& target_rect
) override
;
106 void SetScissorTestRect(const gfx::Rect
& scissor_rect
) override
;
107 void PrepareSurfaceForPass(DrawingFrame
* frame
,
108 SurfaceInitializationMode initialization_mode
,
109 const gfx::Rect
& render_pass_scissor
) override
;
110 void DoDrawQuad(DrawingFrame
* frame
,
111 const class DrawQuad
*,
112 const gfx::QuadF
* draw_region
) override
;
113 void BeginDrawingFrame(DrawingFrame
* frame
) override
;
114 void FinishDrawingFrame(DrawingFrame
* frame
) override
;
115 bool FlippedFramebuffer(const DrawingFrame
* frame
) const override
;
116 bool FlippedRootFramebuffer() const;
117 void EnsureScissorTestEnabled() override
;
118 void EnsureScissorTestDisabled() override
;
119 void CopyCurrentRenderPassToBitmap(
121 scoped_ptr
<CopyOutputRequest
> request
) override
;
122 void FinishDrawingQuadList() override
;
124 // Returns true if quad requires antialiasing and false otherwise.
125 static bool ShouldAntialiasQuad(const gfx::QuadF
& device_layer_quad
,
129 // Inflate the quad and fill edge array for fragment shader.
130 // |local_quad| is set to inflated quad. |edge| array is filled with
131 // inflated quad's edge data.
132 static void SetupQuadForClippingAndAntialiasing(
133 const gfx::Transform
& device_transform
,
134 const DrawQuad
* quad
,
135 const gfx::QuadF
* device_layer_quad
,
136 const gfx::QuadF
* clip_region
,
137 gfx::QuadF
* local_quad
,
139 static void SetupRenderPassQuadForClippingAndAntialiasing(
140 const gfx::Transform
& device_transform
,
141 const RenderPassDrawQuad
* quad
,
142 const gfx::QuadF
* device_layer_quad
,
143 const gfx::QuadF
* clip_region
,
144 gfx::QuadF
* local_quad
,
148 friend class GLRendererShaderPixelTest
;
149 friend class GLRendererShaderTest
;
151 static void ToGLMatrix(float* gl_matrix
, const gfx::Transform
& transform
);
153 void DiscardPixels();
154 void ClearFramebuffer(DrawingFrame
* frame
);
157 void DrawCheckerboardQuad(const DrawingFrame
* frame
,
158 const CheckerboardDrawQuad
* quad
,
159 const gfx::QuadF
* clip_region
);
160 void DrawDebugBorderQuad(const DrawingFrame
* frame
,
161 const DebugBorderDrawQuad
* quad
);
162 static bool IsDefaultBlendMode(SkXfermode::Mode blend_mode
) {
163 return blend_mode
== SkXfermode::kSrcOver_Mode
;
165 bool CanApplyBlendModeUsingBlendFunc(SkXfermode::Mode blend_mode
);
166 void ApplyBlendModeUsingBlendFunc(SkXfermode::Mode blend_mode
);
167 void RestoreBlendFuncToDefault(SkXfermode::Mode blend_mode
);
169 gfx::Rect
GetBackdropBoundingBoxForRenderPassQuad(
171 const RenderPassDrawQuad
* quad
,
172 const gfx::Transform
& contents_device_transform
,
173 const gfx::QuadF
* clip_region
,
175 scoped_ptr
<ScopedResource
> GetBackdropTexture(const gfx::Rect
& bounding_rect
);
177 static bool ShouldApplyBackgroundFilters(DrawingFrame
* frame
,
178 const RenderPassDrawQuad
* quad
);
179 skia::RefPtr
<SkImage
> ApplyBackgroundFilters(
181 const RenderPassDrawQuad
* quad
,
182 ScopedResource
* background_texture
);
184 void DrawRenderPassQuad(DrawingFrame
* frame
,
185 const RenderPassDrawQuad
* quadi
,
186 const gfx::QuadF
* clip_region
);
187 void DrawSolidColorQuad(const DrawingFrame
* frame
,
188 const SolidColorDrawQuad
* quad
,
189 const gfx::QuadF
* clip_region
);
190 void DrawStreamVideoQuad(const DrawingFrame
* frame
,
191 const StreamVideoDrawQuad
* quad
,
192 const gfx::QuadF
* clip_region
);
193 void DrawTextureQuad(const DrawingFrame
* frame
,
194 const TextureDrawQuad
* quad
,
195 const gfx::QuadF
* clip_region
);
196 void EnqueueTextureQuad(const DrawingFrame
* frame
,
197 const TextureDrawQuad
* quad
,
198 const gfx::QuadF
* clip_region
);
199 void FlushTextureQuadCache(BoundGeometry flush_binding
);
200 void DrawIOSurfaceQuad(const DrawingFrame
* frame
,
201 const IOSurfaceDrawQuad
* quad
,
202 const gfx::QuadF
* clip_region
);
203 void DrawTileQuad(const DrawingFrame
* frame
,
204 const TileDrawQuad
* quad
,
205 const gfx::QuadF
* clip_region
);
206 void DrawContentQuad(const DrawingFrame
* frame
,
207 const ContentDrawQuadBase
* quad
,
208 ResourceId resource_id
,
209 const gfx::QuadF
* clip_region
);
210 void DrawContentQuadAA(const DrawingFrame
* frame
,
211 const ContentDrawQuadBase
* quad
,
212 ResourceId resource_id
,
213 const gfx::Transform
& device_transform
,
214 const gfx::QuadF
& aa_quad
,
215 const gfx::QuadF
* clip_region
);
216 void DrawContentQuadNoAA(const DrawingFrame
* frame
,
217 const ContentDrawQuadBase
* quad
,
218 ResourceId resource_id
,
219 const gfx::QuadF
* clip_region
);
220 void DrawYUVVideoQuad(const DrawingFrame
* frame
,
221 const YUVVideoDrawQuad
* quad
,
222 const gfx::QuadF
* clip_region
);
223 void DrawPictureQuad(const DrawingFrame
* frame
,
224 const PictureDrawQuad
* quad
,
225 const gfx::QuadF
* clip_region
);
227 void SetShaderOpacity(float opacity
, int alpha_location
);
228 void SetShaderQuadF(const gfx::QuadF
& quad
, int quad_location
);
229 void DrawQuadGeometryClippedByQuadF(const DrawingFrame
* frame
,
230 const gfx::Transform
& draw_transform
,
231 const gfx::RectF
& quad_rect
,
232 const gfx::QuadF
& clipping_region_quad
,
235 void DrawQuadGeometry(const DrawingFrame
* frame
,
236 const gfx::Transform
& draw_transform
,
237 const gfx::RectF
& quad_rect
,
238 int matrix_location
);
239 void SetUseProgram(unsigned program
);
241 bool UseScopedTexture(DrawingFrame
* frame
,
242 const ScopedResource
* resource
,
243 const gfx::Rect
& viewport_rect
);
245 bool MakeContextCurrent();
247 void InitializeSharedObjects();
248 void CleanupSharedObjects();
250 typedef base::Callback
<void(scoped_ptr
<CopyOutputRequest
> copy_request
,
252 AsyncGetFramebufferPixelsCleanupCallback
;
253 void FinishedReadback(unsigned source_buffer
,
255 const gfx::Size
& size
);
257 void ReinitializeGLState();
258 void RestoreGLState();
259 void RestoreFramebuffer(DrawingFrame
* frame
);
261 void DiscardBackbuffer() override
;
262 void EnsureBackbuffer() override
;
263 void EnforceMemoryPolicy();
265 void ScheduleOverlays(DrawingFrame
* frame
);
267 typedef ScopedPtrVector
<ResourceProvider::ScopedReadLockGL
>
268 OverlayResourceLockList
;
269 OverlayResourceLockList pending_overlay_resources_
;
270 OverlayResourceLockList in_use_overlay_resources_
;
272 RendererCapabilitiesImpl capabilities_
;
274 unsigned offscreen_framebuffer_id_
;
276 scoped_ptr
<StaticGeometryBinding
> shared_geometry_
;
277 scoped_ptr
<DynamicGeometryBinding
> clipped_geometry_
;
278 gfx::QuadF shared_geometry_quad_
;
280 // This block of bindings defines all of the programs used by the compositor
281 // itself. Add any new programs here to GLRendererShaderTest.
283 // Tiled layer shaders.
284 typedef ProgramBinding
<VertexShaderTile
, FragmentShaderRGBATexAlpha
>
286 typedef ProgramBinding
<VertexShaderTileAA
, FragmentShaderRGBATexClampAlphaAA
>
288 typedef ProgramBinding
<VertexShaderTileAA
,
289 FragmentShaderRGBATexClampSwizzleAlphaAA
>
290 TileProgramSwizzleAA
;
291 typedef ProgramBinding
<VertexShaderTile
, FragmentShaderRGBATexOpaque
>
293 typedef ProgramBinding
<VertexShaderTile
, FragmentShaderRGBATexSwizzleAlpha
>
295 typedef ProgramBinding
<VertexShaderTile
, FragmentShaderRGBATexSwizzleOpaque
>
296 TileProgramSwizzleOpaque
;
297 typedef ProgramBinding
<VertexShaderPosTex
, FragmentShaderCheckerboard
>
298 TileCheckerboardProgram
;
301 typedef ProgramBinding
<VertexShaderPosTexTransform
,
302 FragmentShaderRGBATexVaryingAlpha
> TextureProgram
;
303 typedef ProgramBinding
<VertexShaderPosTexTransform
,
304 FragmentShaderRGBATexPremultiplyAlpha
>
305 NonPremultipliedTextureProgram
;
306 typedef ProgramBinding
<VertexShaderPosTexTransform
,
307 FragmentShaderTexBackgroundVaryingAlpha
>
308 TextureBackgroundProgram
;
309 typedef ProgramBinding
<VertexShaderPosTexTransform
,
310 FragmentShaderTexBackgroundPremultiplyAlpha
>
311 NonPremultipliedTextureBackgroundProgram
;
313 // Render surface shaders.
314 typedef ProgramBinding
<VertexShaderPosTexTransform
,
315 FragmentShaderRGBATexAlpha
> RenderPassProgram
;
316 typedef ProgramBinding
<VertexShaderPosTexTransform
,
317 FragmentShaderRGBATexAlphaMask
> RenderPassMaskProgram
;
318 typedef ProgramBinding
<VertexShaderQuadTexTransformAA
,
319 FragmentShaderRGBATexAlphaAA
> RenderPassProgramAA
;
320 typedef ProgramBinding
<VertexShaderQuadTexTransformAA
,
321 FragmentShaderRGBATexAlphaMaskAA
>
322 RenderPassMaskProgramAA
;
323 typedef ProgramBinding
<VertexShaderPosTexTransform
,
324 FragmentShaderRGBATexColorMatrixAlpha
>
325 RenderPassColorMatrixProgram
;
326 typedef ProgramBinding
<VertexShaderQuadTexTransformAA
,
327 FragmentShaderRGBATexAlphaMaskColorMatrixAA
>
328 RenderPassMaskColorMatrixProgramAA
;
329 typedef ProgramBinding
<VertexShaderQuadTexTransformAA
,
330 FragmentShaderRGBATexAlphaColorMatrixAA
>
331 RenderPassColorMatrixProgramAA
;
332 typedef ProgramBinding
<VertexShaderPosTexTransform
,
333 FragmentShaderRGBATexAlphaMaskColorMatrix
>
334 RenderPassMaskColorMatrixProgram
;
337 typedef ProgramBinding
<VertexShaderVideoTransform
, FragmentShaderRGBATex
>
338 VideoStreamTextureProgram
;
339 typedef ProgramBinding
<VertexShaderPosTexYUVStretchOffset
,
340 FragmentShaderYUVVideo
> VideoYUVProgram
;
341 typedef ProgramBinding
<VertexShaderPosTexYUVStretchOffset
,
342 FragmentShaderYUVAVideo
> VideoYUVAProgram
;
344 // Special purpose / effects shaders.
345 typedef ProgramBinding
<VertexShaderPos
, FragmentShaderColor
>
347 typedef ProgramBinding
<VertexShaderQuad
, FragmentShaderColor
>
349 typedef ProgramBinding
<VertexShaderQuadAA
, FragmentShaderColorAA
>
352 const TileProgram
* GetTileProgram(
353 TexCoordPrecision precision
, SamplerType sampler
);
354 const TileProgramOpaque
* GetTileProgramOpaque(
355 TexCoordPrecision precision
, SamplerType sampler
);
356 const TileProgramAA
* GetTileProgramAA(
357 TexCoordPrecision precision
, SamplerType sampler
);
358 const TileProgramSwizzle
* GetTileProgramSwizzle(
359 TexCoordPrecision precision
, SamplerType sampler
);
360 const TileProgramSwizzleOpaque
* GetTileProgramSwizzleOpaque(
361 TexCoordPrecision precision
, SamplerType sampler
);
362 const TileProgramSwizzleAA
* GetTileProgramSwizzleAA(
363 TexCoordPrecision precision
, SamplerType sampler
);
365 const TileCheckerboardProgram
* GetTileCheckerboardProgram();
367 const RenderPassProgram
* GetRenderPassProgram(TexCoordPrecision precision
,
368 BlendMode blend_mode
);
369 const RenderPassProgramAA
* GetRenderPassProgramAA(TexCoordPrecision precision
,
370 BlendMode blend_mode
);
371 const RenderPassMaskProgram
* GetRenderPassMaskProgram(
372 TexCoordPrecision precision
,
374 BlendMode blend_mode
,
375 bool mask_for_background
);
376 const RenderPassMaskProgramAA
* GetRenderPassMaskProgramAA(
377 TexCoordPrecision precision
,
379 BlendMode blend_mode
,
380 bool mask_for_background
);
381 const RenderPassColorMatrixProgram
* GetRenderPassColorMatrixProgram(
382 TexCoordPrecision precision
,
383 BlendMode blend_mode
);
384 const RenderPassColorMatrixProgramAA
* GetRenderPassColorMatrixProgramAA(
385 TexCoordPrecision precision
,
386 BlendMode blend_mode
);
387 const RenderPassMaskColorMatrixProgram
* GetRenderPassMaskColorMatrixProgram(
388 TexCoordPrecision precision
,
390 BlendMode blend_mode
,
391 bool mask_for_background
);
392 const RenderPassMaskColorMatrixProgramAA
*
393 GetRenderPassMaskColorMatrixProgramAA(TexCoordPrecision precision
,
395 BlendMode blend_mode
,
396 bool mask_for_background
);
398 const TextureProgram
* GetTextureProgram(TexCoordPrecision precision
,
399 SamplerType sampler
);
400 const NonPremultipliedTextureProgram
* GetNonPremultipliedTextureProgram(
401 TexCoordPrecision precision
,
402 SamplerType sampler
);
403 const TextureBackgroundProgram
* GetTextureBackgroundProgram(
404 TexCoordPrecision precision
,
405 SamplerType sampler
);
406 const NonPremultipliedTextureBackgroundProgram
*
407 GetNonPremultipliedTextureBackgroundProgram(TexCoordPrecision precision
,
408 SamplerType sampler
);
409 const TextureProgram
* GetTextureIOSurfaceProgram(
410 TexCoordPrecision precision
);
412 const VideoYUVProgram
* GetVideoYUVProgram(TexCoordPrecision precision
,
413 SamplerType sampler
);
414 const VideoYUVAProgram
* GetVideoYUVAProgram(TexCoordPrecision precision
,
415 SamplerType sampler
);
416 const VideoStreamTextureProgram
* GetVideoStreamTextureProgram(
417 TexCoordPrecision precision
);
419 const DebugBorderProgram
* GetDebugBorderProgram();
420 const SolidColorProgram
* GetSolidColorProgram();
421 const SolidColorProgramAA
* GetSolidColorProgramAA();
424 tile_program_
[LAST_TEX_COORD_PRECISION
+ 1][LAST_SAMPLER_TYPE
+ 1];
426 tile_program_opaque_
[LAST_TEX_COORD_PRECISION
+ 1][LAST_SAMPLER_TYPE
+ 1];
428 tile_program_aa_
[LAST_TEX_COORD_PRECISION
+ 1][LAST_SAMPLER_TYPE
+ 1];
429 TileProgramSwizzle tile_program_swizzle_
[LAST_TEX_COORD_PRECISION
+
430 1][LAST_SAMPLER_TYPE
+ 1];
431 TileProgramSwizzleOpaque
432 tile_program_swizzle_opaque_
[LAST_TEX_COORD_PRECISION
+
433 1][LAST_SAMPLER_TYPE
+ 1];
434 TileProgramSwizzleAA tile_program_swizzle_aa_
[LAST_TEX_COORD_PRECISION
+
435 1][LAST_SAMPLER_TYPE
+ 1];
437 TileCheckerboardProgram tile_checkerboard_program_
;
440 texture_program_
[LAST_TEX_COORD_PRECISION
+ 1][LAST_SAMPLER_TYPE
+ 1];
441 NonPremultipliedTextureProgram
442 nonpremultiplied_texture_program_
[LAST_TEX_COORD_PRECISION
+
443 1][LAST_SAMPLER_TYPE
+ 1];
444 TextureBackgroundProgram
445 texture_background_program_
[LAST_TEX_COORD_PRECISION
+
446 1][LAST_SAMPLER_TYPE
+ 1];
447 NonPremultipliedTextureBackgroundProgram
448 nonpremultiplied_texture_background_program_
[LAST_TEX_COORD_PRECISION
+
449 1][LAST_SAMPLER_TYPE
+ 1];
450 TextureProgram texture_io_surface_program_
[LAST_TEX_COORD_PRECISION
+ 1];
453 render_pass_program_
[LAST_TEX_COORD_PRECISION
+ 1][LAST_BLEND_MODE
+ 1];
454 RenderPassProgramAA render_pass_program_aa_
[LAST_TEX_COORD_PRECISION
+
455 1][LAST_BLEND_MODE
+ 1];
456 RenderPassMaskProgram
457 render_pass_mask_program_
[LAST_TEX_COORD_PRECISION
+ 1]
458 [LAST_SAMPLER_TYPE
+ 1]
459 [LAST_BLEND_MODE
+ 1]
460 [LAST_MASK_VALUE
+ 1];
461 RenderPassMaskProgramAA
462 render_pass_mask_program_aa_
[LAST_TEX_COORD_PRECISION
+ 1]
463 [LAST_SAMPLER_TYPE
+ 1]
464 [LAST_BLEND_MODE
+ 1]
465 [LAST_MASK_VALUE
+ 1];
466 RenderPassColorMatrixProgram
467 render_pass_color_matrix_program_
[LAST_TEX_COORD_PRECISION
+
468 1][LAST_BLEND_MODE
+ 1];
469 RenderPassColorMatrixProgramAA
470 render_pass_color_matrix_program_aa_
[LAST_TEX_COORD_PRECISION
+
471 1][LAST_BLEND_MODE
+ 1];
472 RenderPassMaskColorMatrixProgram
473 render_pass_mask_color_matrix_program_
[LAST_TEX_COORD_PRECISION
+ 1]
474 [LAST_SAMPLER_TYPE
+ 1]
475 [LAST_BLEND_MODE
+ 1]
476 [LAST_MASK_VALUE
+ 1];
477 RenderPassMaskColorMatrixProgramAA
478 render_pass_mask_color_matrix_program_aa_
[LAST_TEX_COORD_PRECISION
+ 1]
479 [LAST_SAMPLER_TYPE
+ 1]
480 [LAST_BLEND_MODE
+ 1]
481 [LAST_MASK_VALUE
+ 1];
484 video_yuv_program_
[LAST_TEX_COORD_PRECISION
+ 1][LAST_SAMPLER_TYPE
+ 1];
486 video_yuva_program_
[LAST_TEX_COORD_PRECISION
+ 1][LAST_SAMPLER_TYPE
+ 1];
487 VideoStreamTextureProgram
488 video_stream_texture_program_
[LAST_TEX_COORD_PRECISION
+ 1];
490 DebugBorderProgram debug_border_program_
;
491 SolidColorProgram solid_color_program_
;
492 SolidColorProgramAA solid_color_program_aa_
;
494 gpu::gles2::GLES2Interface
* gl_
;
495 gpu::ContextSupport
* context_support_
;
497 TextureMailboxDeleter
* texture_mailbox_deleter_
;
499 gfx::Rect swap_buffer_rect_
;
500 gfx::Rect scissor_rect_
;
501 bool is_backbuffer_discarded_
;
502 bool is_using_bind_uniform_
;
503 bool is_scissor_enabled_
;
504 bool scissor_rect_needs_reset_
;
505 bool stencil_shadow_
;
507 unsigned program_shadow_
;
508 TexturedQuadDrawCache draw_cache_
;
509 int highp_threshold_min_
;
510 int highp_threshold_cache_
;
512 struct PendingAsyncReadPixels
;
513 ScopedPtrVector
<PendingAsyncReadPixels
> pending_async_read_pixels_
;
515 scoped_ptr
<ResourceProvider::ScopedWriteLockGL
> current_framebuffer_lock_
;
518 ScopedPtrDeque
<SyncQuery
> pending_sync_queries_
;
519 ScopedPtrDeque
<SyncQuery
> available_sync_queries_
;
520 scoped_ptr
<SyncQuery
> current_sync_query_
;
521 bool use_sync_query_
;
522 bool use_blend_equation_advanced_
;
523 bool use_blend_equation_advanced_coherent_
;
525 SkBitmap on_demand_tile_raster_bitmap_
;
526 ResourceId on_demand_tile_raster_resource_id_
;
527 BoundGeometry bound_geometry_
;
528 DISALLOW_COPY_AND_ASSIGN(GLRenderer
);
533 #endif // CC_OUTPUT_GL_RENDERER_H_