OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 #include "cc/paint/paint_canvas.h" | 5 #include "cc/paint/paint_canvas.h" |
6 | 6 |
7 #include "base/memory/ptr_util.h" | 7 #include "base/memory/ptr_util.h" |
8 #include "cc/paint/display_item_list.h" | 8 #include "cc/paint/display_item_list.h" |
9 #include "cc/paint/paint_record.h" | 9 #include "cc/paint/paint_record.h" |
10 #include "cc/paint/paint_recorder.h" | 10 #include "cc/paint/paint_recorder.h" |
(...skipping 20 matching lines...) Expand all Loading... |
31 } | 31 } |
32 | 32 |
33 SkImageInfo SkiaPaintCanvas::imageInfo() const { | 33 SkImageInfo SkiaPaintCanvas::imageInfo() const { |
34 return canvas_->imageInfo(); | 34 return canvas_->imageInfo(); |
35 } | 35 } |
36 | 36 |
37 void SkiaPaintCanvas::flush() { | 37 void SkiaPaintCanvas::flush() { |
38 canvas_->flush(); | 38 canvas_->flush(); |
39 } | 39 } |
40 | 40 |
| 41 SkISize SkiaPaintCanvas::getBaseLayerSize() const { |
| 42 return canvas_->getBaseLayerSize(); |
| 43 } |
| 44 |
41 bool SkiaPaintCanvas::writePixels(const SkImageInfo& info, | 45 bool SkiaPaintCanvas::writePixels(const SkImageInfo& info, |
42 const void* pixels, | 46 const void* pixels, |
43 size_t row_bytes, | 47 size_t row_bytes, |
44 int x, | 48 int x, |
45 int y) { | 49 int y) { |
46 return canvas_->writePixels(info, pixels, row_bytes, x, y); | 50 return canvas_->writePixels(info, pixels, row_bytes, x, y); |
47 } | 51 } |
48 | 52 |
49 int SkiaPaintCanvas::save() { | 53 int SkiaPaintCanvas::save() { |
50 return canvas_->save(); | 54 return canvas_->save(); |
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
298 break; | 302 break; |
299 case AnnotationType::NAMED_DESTINATION: { | 303 case AnnotationType::NAMED_DESTINATION: { |
300 SkPoint point = SkPoint::Make(rect.x(), rect.y()); | 304 SkPoint point = SkPoint::Make(rect.x(), rect.y()); |
301 SkAnnotateNamedDestination(canvas_, point, data.get()); | 305 SkAnnotateNamedDestination(canvas_, point, data.get()); |
302 break; | 306 break; |
303 } | 307 } |
304 } | 308 } |
305 } | 309 } |
306 | 310 |
307 } // namespace cc | 311 } // namespace cc |
OLD | NEW |