OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2013 Google Inc. | 2 * Copyright 2013 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #include "SkTileImageFilter.h" | 8 #include "SkTileImageFilter.h" |
9 #include "SkBitmap.h" | 9 #include "SkBitmap.h" |
10 #include "SkCanvas.h" | 10 #include "SkCanvas.h" |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 | 103 |
104 void SkTileImageFilter::flatten(SkWriteBuffer& buffer) const { | 104 void SkTileImageFilter::flatten(SkWriteBuffer& buffer) const { |
105 this->INHERITED::flatten(buffer); | 105 this->INHERITED::flatten(buffer); |
106 buffer.writeRect(fSrcRect); | 106 buffer.writeRect(fSrcRect); |
107 buffer.writeRect(fDstRect); | 107 buffer.writeRect(fDstRect); |
108 } | 108 } |
109 | 109 |
110 #ifndef SK_IGNORE_TO_STRING | 110 #ifndef SK_IGNORE_TO_STRING |
111 void SkTileImageFilter::toString(SkString* str) const { | 111 void SkTileImageFilter::toString(SkString* str) const { |
112 str->appendf("SkTileImageFilter: ("); | 112 str->appendf("SkTileImageFilter: ("); |
| 113 str->appendf("src: %.2f %.2f %.2f %.2f", |
| 114 fSrcRect.fLeft, fSrcRect.fTop, fSrcRect.fRight, fSrcRect.fBotto
m); |
| 115 str->appendf(" dst: %.2f %.2f %.2f %.2f", |
| 116 fDstRect.fLeft, fDstRect.fTop, fDstRect.fRight, fDstRect.fBotto
m); |
| 117 if (this->getInput(0)) { |
| 118 str->appendf("input: ("); |
| 119 this->getInput(0)->toString(str); |
| 120 str->appendf(")"); |
| 121 } |
113 str->append(")"); | 122 str->append(")"); |
114 } | 123 } |
115 #endif | 124 #endif |
OLD | NEW |