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

Side by Side Diff: cc/output/ca_layer_overlay.h

Issue 2164613003: Add logic to convert from RenderPassDrawQuads to CALayerOverlays. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@temp41_rpdq_converter
Patch Set: Static asserts. Created 4 years, 5 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 | « no previous file | cc/output/ca_layer_overlay.cc » ('j') | ui/gl/ca_renderer_layer_params.h » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_CA_LAYER_OVERLAY_H_ 5 #ifndef CC_OUTPUT_CA_LAYER_OVERLAY_H_
6 #define CC_OUTPUT_CA_LAYER_OVERLAY_H_ 6 #define CC_OUTPUT_CA_LAYER_OVERLAY_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "cc/quads/render_pass.h" 9 #include "cc/quads/render_pass.h"
10 #include "third_party/skia/include/core/SkColor.h" 10 #include "third_party/skia/include/core/SkColor.h"
11 #include "third_party/skia/include/core/SkMatrix44.h" 11 #include "third_party/skia/include/core/SkMatrix44.h"
12 #include "ui/gfx/geometry/rect_f.h" 12 #include "ui/gfx/geometry/rect_f.h"
13 #include "ui/gl/ca_renderer_layer_params.h"
13 14
14 namespace cc { 15 namespace cc {
15 16
16 class DrawQuad; 17 class DrawQuad;
17 class ResourceProvider; 18 class ResourceProvider;
18 19
19 // Holds information that is frequently shared between consecutive 20 // Holds information that is frequently shared between consecutive
20 // CALayerOverlays. 21 // CALayerOverlays.
21 class CC_EXPORT CALayerOverlaySharedState 22 class CC_EXPORT CALayerOverlaySharedState
22 : public base::RefCounted<CALayerOverlaySharedState> { 23 : public base::RefCounted<CALayerOverlaySharedState> {
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 // The background color property for the CALayer. 60 // The background color property for the CALayer.
60 SkColor background_color = SK_ColorTRANSPARENT; 61 SkColor background_color = SK_ColorTRANSPARENT;
61 // The edge anti-aliasing mask property for the CALayer. 62 // The edge anti-aliasing mask property for the CALayer.
62 unsigned edge_aa_mask = 0; 63 unsigned edge_aa_mask = 0;
63 // The minification and magnification filters for the CALayer. 64 // The minification and magnification filters for the CALayer.
64 unsigned filter; 65 unsigned filter;
65 66
66 // If valid, the renderer must copy the contents of the render pass into an 67 // If valid, the renderer must copy the contents of the render pass into an
67 // overlay resource to use as the contents. 68 // overlay resource to use as the contents.
68 RenderPassId render_pass_id; 69 RenderPassId render_pass_id;
70 ui::CARendererLayerParams::FilterEffects filter_effects;
69 }; 71 };
70 72
71 typedef std::vector<CALayerOverlay> CALayerOverlayList; 73 typedef std::vector<CALayerOverlay> CALayerOverlayList;
72 74
73 // Returns true if all quads in the root render pass have been replaced by 75 // Returns true if all quads in the root render pass have been replaced by
74 // CALayerOverlays. 76 // CALayerOverlays.
75 bool ProcessForCALayerOverlays(ResourceProvider* resource_provider, 77 bool ProcessForCALayerOverlays(ResourceProvider* resource_provider,
76 const gfx::RectF& display_rect, 78 const gfx::RectF& display_rect,
77 const QuadList& quad_list, 79 const QuadList& quad_list,
78 CALayerOverlayList* ca_layer_overlays); 80 CALayerOverlayList* ca_layer_overlays);
79 81
82 // Allows RenderPassDrawQuads to be converted to CALayerOverlays.
83 void CC_EXPORT EnableRenderPassDrawQuadForTesting();
84
80 } // namespace cc 85 } // namespace cc
81 86
82 #endif // CC_OUTPUT_CA_LAYER_OVERLAY_H_ 87 #endif // CC_OUTPUT_CA_LAYER_OVERLAY_H_
OLDNEW
« no previous file with comments | « no previous file | cc/output/ca_layer_overlay.cc » ('j') | ui/gl/ca_renderer_layer_params.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698