OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef UI_COMPOSITOR_COMPOSITING_RECORDER_H_ |
| 6 #define UI_COMPOSITOR_COMPOSITING_RECORDER_H_ |
| 7 |
| 8 #include "base/macros.h" |
| 9 #include "ui/compositor/compositor_export.h" |
| 10 |
| 11 namespace gfx { |
| 12 class Canvas; |
| 13 class Rect; |
| 14 class Transform; |
| 15 } |
| 16 |
| 17 namespace ui { |
| 18 class PaintContext; |
| 19 |
| 20 // A class to provide scoped compositing filters (eg opacity) of painting to a |
| 21 // DisplayItemList. The filters provided will be applied to any |
| 22 // DisplayItems added to the DisplayItemList while this object is alive. In |
| 23 // other words, any nested PaintRecorders or other such Recorders will |
| 24 // be filtered by the effect. |
| 25 class COMPOSITOR_EXPORT CompositingRecorder { |
| 26 public: |
| 27 CompositingRecorder(const PaintContext& context, float opacity); |
| 28 ~CompositingRecorder(); |
| 29 |
| 30 private: |
| 31 gfx::Canvas* canvas_; |
| 32 |
| 33 DISALLOW_COPY_AND_ASSIGN(CompositingRecorder); |
| 34 }; |
| 35 |
| 36 } // namespace ui |
| 37 |
| 38 #endif // UI_COMPOSITOR_CLIP_TRANSFORM_RECORDER_H_ |
OLD | NEW |