| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_RESOURCES_DISPLAY_LIST_RECORDING_SOURCE_H_ | 5 #ifndef CC_RESOURCES_DISPLAY_LIST_RECORDING_SOURCE_H_ |
| 6 #define CC_RESOURCES_DISPLAY_LIST_RECORDING_SOURCE_H_ | 6 #define CC_RESOURCES_DISPLAY_LIST_RECORDING_SOURCE_H_ |
| 7 | 7 |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "cc/resources/recording_source.h" | 9 #include "cc/resources/recording_source.h" |
| 10 | 10 |
| 11 namespace cc { | 11 namespace cc { |
| 12 class DisplayItemList; | 12 class DisplayItemList; |
| 13 class DisplayListRasterSource; | 13 class DisplayListRasterSource; |
| 14 | 14 |
| 15 class CC_EXPORT DisplayListRecordingSource : public RecordingSource { | 15 class CC_EXPORT DisplayListRecordingSource : public RecordingSource { |
| 16 public: | 16 public: |
| 17 DisplayListRecordingSource(); | 17 DisplayListRecordingSource(); |
| 18 ~DisplayListRecordingSource() override; | 18 ~DisplayListRecordingSource() override; |
| 19 | 19 |
| 20 // RecordingSource overrides. | 20 // RecordingSource overrides. |
| 21 bool UpdateAndExpandInvalidation(ContentLayerClient* painter, | 21 bool UpdateAndExpandInvalidation(ContentLayerClient* painter, |
| 22 Region* invalidation, | 22 Region* invalidation, |
| 23 const gfx::Size& layer_size, | 23 const gfx::Size& layer_size, |
| 24 const gfx::Rect& visible_layer_rect, | 24 const gfx::Rect& visible_layer_rect, |
| 25 int frame_number, | 25 int frame_number, |
| 26 RecordingMode recording_mode) override; | 26 RecordingMode recording_mode) override; |
| 27 void DidMoveToNewCompositor() override; |
| 27 scoped_refptr<RasterSource> CreateRasterSource( | 28 scoped_refptr<RasterSource> CreateRasterSource( |
| 28 bool can_use_lcd_text) const override; | 29 bool can_use_lcd_text) const override; |
| 29 gfx::Size GetSize() const final; | 30 gfx::Size GetSize() const final; |
| 30 void SetEmptyBounds() override; | 31 void SetEmptyBounds() override; |
| 31 void SetSlowdownRasterScaleFactor(int factor) override; | 32 void SetSlowdownRasterScaleFactor(int factor) override; |
| 32 void SetBackgroundColor(SkColor background_color) override; | 33 void SetBackgroundColor(SkColor background_color) override; |
| 33 void SetRequiresClear(bool requires_clear) override; | 34 void SetRequiresClear(bool requires_clear) override; |
| 34 bool IsSuitableForGpuRasterization() const override; | 35 bool IsSuitableForGpuRasterization() const override; |
| 35 void SetUnsuitableForGpuRasterizationForTesting() override; | 36 void SetUnsuitableForGpuRasterizationForTesting() override; |
| 36 gfx::Size GetTileGridSizeForTesting() const override; | 37 gfx::Size GetTileGridSizeForTesting() const override; |
| (...skipping 18 matching lines...) Expand all Loading... |
| 55 void DetermineIfSolidColor(); | 56 void DetermineIfSolidColor(); |
| 56 | 57 |
| 57 bool is_suitable_for_gpu_rasterization_; | 58 bool is_suitable_for_gpu_rasterization_; |
| 58 | 59 |
| 59 DISALLOW_COPY_AND_ASSIGN(DisplayListRecordingSource); | 60 DISALLOW_COPY_AND_ASSIGN(DisplayListRecordingSource); |
| 60 }; | 61 }; |
| 61 | 62 |
| 62 } // namespace cc | 63 } // namespace cc |
| 63 | 64 |
| 64 #endif // CC_RESOURCES_DISPLAY_LIST_RECORDING_SOURCE_H_ | 65 #endif // CC_RESOURCES_DISPLAY_LIST_RECORDING_SOURCE_H_ |
| OLD | NEW |