OLD | NEW |
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_RASTER_GPU_RASTERIZER_H_ | 5 #ifndef CC_RASTER_GPU_RASTERIZER_H_ |
6 #define CC_RASTER_GPU_RASTERIZER_H_ | 6 #define CC_RASTER_GPU_RASTERIZER_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "cc/base/cc_export.h" | 11 #include "cc/base/cc_export.h" |
| 12 #include "cc/playback/raster_source.h" |
12 #include "cc/resources/resource_pool.h" | 13 #include "cc/resources/resource_pool.h" |
13 #include "cc/tiles/tile.h" | 14 #include "cc/tiles/tile.h" |
14 #include "third_party/skia/include/core/SkMultiPictureDraw.h" | 15 #include "third_party/skia/include/core/SkMultiPictureDraw.h" |
15 | 16 |
16 namespace cc { | 17 namespace cc { |
17 | 18 |
18 class ContextProvider; | 19 class ContextProvider; |
19 class RasterSource; | 20 class RasterSource; |
20 class ResourceProvider; | 21 class ResourceProvider; |
21 | 22 |
22 class CC_EXPORT GpuRasterizer { | 23 class CC_EXPORT GpuRasterizer { |
23 public: | 24 public: |
24 ~GpuRasterizer(); | 25 ~GpuRasterizer(); |
25 | 26 |
26 void RasterizeSource(ResourceProvider::ScopedWriteLockGr* write_lock, | 27 void RasterizeSource(ResourceProvider::ScopedWriteLockGr* write_lock, |
27 const RasterSource* raster_source, | 28 const RasterSource* raster_source, |
28 const gfx::Rect& raster_full_rect, | 29 const gfx::Rect& raster_full_rect, |
29 const gfx::Rect& playback_rect, | 30 const gfx::Rect& playback_rect, |
30 float scale); | 31 float scale, |
| 32 const RasterSource::PlaybackSettings& playback_settings); |
31 | 33 |
32 ResourceProvider* resource_provider() { return resource_provider_; } | 34 ResourceProvider* resource_provider() { return resource_provider_; } |
33 | 35 |
34 private: | 36 private: |
35 GpuRasterizer(ContextProvider* context_provider, | 37 GpuRasterizer(ContextProvider* context_provider, |
36 ResourceProvider* resource_provider, | 38 ResourceProvider* resource_provider, |
37 bool use_distance_filed_text, | 39 bool use_distance_filed_text, |
38 int msaa_sample_count); | 40 int msaa_sample_count); |
39 | 41 |
40 ResourceProvider* resource_provider_; | 42 ResourceProvider* resource_provider_; |
41 | 43 |
42 bool use_distance_field_text_; | 44 bool use_distance_field_text_; |
43 int msaa_sample_count_; | 45 int msaa_sample_count_; |
44 | 46 |
45 friend class GpuTileTaskWorkerPool; | 47 friend class GpuTileTaskWorkerPool; |
46 DISALLOW_COPY_AND_ASSIGN(GpuRasterizer); | 48 DISALLOW_COPY_AND_ASSIGN(GpuRasterizer); |
47 }; | 49 }; |
48 | 50 |
49 } // namespace cc | 51 } // namespace cc |
50 | 52 |
51 #endif // CC_RASTER_GPU_RASTERIZER_H_ | 53 #endif // CC_RASTER_GPU_RASTERIZER_H_ |
OLD | NEW |