OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 CONTENT_COMMON_GPU_CA_LAYER_TREE_MAC_H_ | 5 #ifndef GPU_IPC_SERVICE_CA_LAYER_TREE_MAC_H_ |
6 #define CONTENT_COMMON_GPU_CA_LAYER_TREE_MAC_H_ | 6 #define GPU_IPC_SERVICE_CA_LAYER_TREE_MAC_H_ |
7 | 7 |
8 #include <IOSurface/IOSurface.h> | 8 #include <IOSurface/IOSurface.h> |
9 #include <QuartzCore/QuartzCore.h> | 9 #include <QuartzCore/QuartzCore.h> |
10 #include <deque> | 10 #include <deque> |
11 #include <vector> | 11 #include <vector> |
12 | 12 |
13 #include "base/mac/scoped_cftyperef.h" | 13 #include "base/mac/scoped_cftyperef.h" |
14 #include "base/mac/scoped_nsobject.h" | 14 #include "base/mac/scoped_nsobject.h" |
15 #include "base/memory/scoped_ptr.h" | 15 #include "base/memory/scoped_ptr.h" |
16 #include "content/common/content_export.h" | 16 #include "gpu/gpu_export.h" |
17 #include "ui/gfx/geometry/rect.h" | 17 #include "ui/gfx/geometry/rect.h" |
18 #include "ui/gfx/geometry/rect_f.h" | 18 #include "ui/gfx/geometry/rect_f.h" |
19 #include "ui/gfx/mac/io_surface.h" | 19 #include "ui/gfx/mac/io_surface.h" |
20 #include "ui/gfx/transform.h" | 20 #include "ui/gfx/transform.h" |
21 | 21 |
22 @class AVSampleBufferDisplayLayer; | 22 @class AVSampleBufferDisplayLayer; |
23 | 23 |
24 namespace content { | 24 namespace gpu { |
25 | 25 |
26 // The CALayerTree will construct a hierarchy of CALayers from a linear list, | 26 // The CALayerTree will construct a hierarchy of CALayers from a linear list, |
27 // using the algorithm and structure referenced described in | 27 // using the algorithm and structure referenced described in |
28 // https://docs.google.com/document/d/1DtSN9zzvCF44_FQPM7ie01UxGHagQ66zfF5L9Hnig
QY/edit?usp=sharing | 28 // https://docs.google.com/document/d/1DtSN9zzvCF44_FQPM7ie01UxGHagQ66zfF5L9Hnig
QY/edit?usp=sharing |
29 class CONTENT_EXPORT CALayerTree { | 29 class GPU_EXPORT CALayerTree { |
30 public: | 30 public: |
31 CALayerTree(); | 31 CALayerTree(); |
32 | 32 |
33 // This will remove all CALayers from this tree from their superlayer. | 33 // This will remove all CALayers from this tree from their superlayer. |
34 ~CALayerTree(); | 34 ~CALayerTree(); |
35 | 35 |
36 // Append the description of a new CALayer to the tree. This will not | 36 // Append the description of a new CALayer to the tree. This will not |
37 // create any new CALayers until CommitScheduledCALayers is called. This | 37 // create any new CALayers until CommitScheduledCALayers is called. This |
38 // cannot be called anymore after CommitScheduledCALayers has been called. | 38 // cannot be called anymore after CommitScheduledCALayers has been called. |
39 bool ScheduleCALayer(bool is_clipped, | 39 bool ScheduleCALayer(bool is_clipped, |
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
190 }; | 190 }; |
191 | 191 |
192 RootLayer root_layer_; | 192 RootLayer root_layer_; |
193 float scale_factor_ = 1; | 193 float scale_factor_ = 1; |
194 bool has_committed_ = false; | 194 bool has_committed_ = false; |
195 | 195 |
196 private: | 196 private: |
197 DISALLOW_COPY_AND_ASSIGN(CALayerTree); | 197 DISALLOW_COPY_AND_ASSIGN(CALayerTree); |
198 }; | 198 }; |
199 | 199 |
200 } // namespace content | 200 } // namespace gpu |
201 | 201 |
202 #endif // CONTENT_COMMON_GPU_CA_LAYER_TREE_MAC_H_ | 202 #endif // GPU_IPC_SERVICE_CA_LAYER_TREE_MAC_H_ |
OLD | NEW |