OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2011 Google Inc. | 3 * Copyright 2011 Google Inc. |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 | 8 |
9 #include "SkAnnotation.h" | 9 #include "SkAnnotation.h" |
10 #include "SkBitmapDevice.h" | 10 #include "SkBitmapDevice.h" |
(...skipping 1034 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1045 | 1045 |
1046 if (base.getFlags() != paint.getFlags()) { | 1046 if (base.getFlags() != paint.getFlags()) { |
1047 *ptr++ = PaintOp_packOpData(kFlags_PaintOp, paint.getFlags()); | 1047 *ptr++ = PaintOp_packOpData(kFlags_PaintOp, paint.getFlags()); |
1048 base.setFlags(paint.getFlags()); | 1048 base.setFlags(paint.getFlags()); |
1049 } | 1049 } |
1050 if (base.getColor() != paint.getColor()) { | 1050 if (base.getColor() != paint.getColor()) { |
1051 *ptr++ = PaintOp_packOp(kColor_PaintOp); | 1051 *ptr++ = PaintOp_packOp(kColor_PaintOp); |
1052 *ptr++ = paint.getColor(); | 1052 *ptr++ = paint.getColor(); |
1053 base.setColor(paint.getColor()); | 1053 base.setColor(paint.getColor()); |
1054 } | 1054 } |
| 1055 if (base.getFilterLevel() != paint.getFilterLevel()) { |
| 1056 *ptr++ = PaintOp_packOpData(kFilterLevel_PaintOp, paint.getFilterLevel()
); |
| 1057 base.setFilterLevel(paint.getFilterLevel()); |
| 1058 } |
1055 if (base.getStyle() != paint.getStyle()) { | 1059 if (base.getStyle() != paint.getStyle()) { |
1056 *ptr++ = PaintOp_packOpData(kStyle_PaintOp, paint.getStyle()); | 1060 *ptr++ = PaintOp_packOpData(kStyle_PaintOp, paint.getStyle()); |
1057 base.setStyle(paint.getStyle()); | 1061 base.setStyle(paint.getStyle()); |
1058 } | 1062 } |
1059 if (base.getStrokeJoin() != paint.getStrokeJoin()) { | 1063 if (base.getStrokeJoin() != paint.getStrokeJoin()) { |
1060 *ptr++ = PaintOp_packOpData(kJoin_PaintOp, paint.getStrokeJoin()); | 1064 *ptr++ = PaintOp_packOpData(kJoin_PaintOp, paint.getStrokeJoin()); |
1061 base.setStrokeJoin(paint.getStrokeJoin()); | 1065 base.setStrokeJoin(paint.getStrokeJoin()); |
1062 } | 1066 } |
1063 if (base.getStrokeCap() != paint.getStrokeCap()) { | 1067 if (base.getStrokeCap() != paint.getStrokeCap()) { |
1064 *ptr++ = PaintOp_packOpData(kCap_PaintOp, paint.getStrokeCap()); | 1068 *ptr++ = PaintOp_packOpData(kCap_PaintOp, paint.getStrokeCap()); |
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1242 return fCanvas->shuttleBitmap(bitmap, slot); | 1246 return fCanvas->shuttleBitmap(bitmap, slot); |
1243 } | 1247 } |
1244 | 1248 |
1245 void BitmapShuttle::removeCanvas() { | 1249 void BitmapShuttle::removeCanvas() { |
1246 if (NULL == fCanvas) { | 1250 if (NULL == fCanvas) { |
1247 return; | 1251 return; |
1248 } | 1252 } |
1249 fCanvas->unref(); | 1253 fCanvas->unref(); |
1250 fCanvas = NULL; | 1254 fCanvas = NULL; |
1251 } | 1255 } |
OLD | NEW |