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