Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 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 #ifndef DMSrcSink_DEFINED | 8 #ifndef DMSrcSink_DEFINED |
| 9 #define DMSrcSink_DEFINED | 9 #define DMSrcSink_DEFINED |
| 10 | 10 |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 93 | 93 |
| 94 Error draw(SkCanvas*) const override; | 94 Error draw(SkCanvas*) const override; |
| 95 SkISize size() const override; | 95 SkISize size() const override; |
| 96 Name name() const override; | 96 Name name() const override; |
| 97 void modifyGrContextOptions(GrContextOptions* options) const override; | 97 void modifyGrContextOptions(GrContextOptions* options) const override; |
| 98 | 98 |
| 99 private: | 99 private: |
| 100 skiagm::GMRegistry::Factory fFactory; | 100 skiagm::GMRegistry::Factory fFactory; |
| 101 }; | 101 }; |
| 102 | 102 |
| 103 class CodecSrc : public Src { | 103 class CodecSrc : public Src { |
|
msarett
2016/01/12 15:02:33
I think you could make the argument that fZeroInit
scroggo
2016/01/12 22:27:46
sgtm. Maybe add a comment explaining that in the c
msarett
2016/01/13 14:58:16
Done.
| |
| 104 public: | 104 public: |
| 105 enum Mode { | 105 enum Mode { |
| 106 kCodec_Mode, | 106 kCodec_Mode, |
| 107 kCodecZeroInit_Mode, | |
| 107 kScanline_Mode, | 108 kScanline_Mode, |
| 108 kStripe_Mode, // Tests the skipping of scanlines | 109 kStripe_Mode, // Tests the skipping of scanlines |
| 109 kSubset_Mode, // For codecs that support subsets directly. | 110 kSubset_Mode, // For codecs that support subsets directly. |
| 110 }; | 111 }; |
| 111 enum DstColorType { | 112 enum DstColorType { |
| 112 kGetFromCanvas_DstColorType, | 113 kGetFromCanvas_DstColorType, |
| 113 kIndex8_Always_DstColorType, | 114 kIndex8_Always_DstColorType, |
| 114 kGrayscale_Always_DstColorType, | 115 kGrayscale_Always_DstColorType, |
| 115 }; | 116 }; |
| 116 CodecSrc(Path, Mode, DstColorType, float); | 117 CodecSrc(Path, Mode, DstColorType, float); |
| (...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 358 | 359 |
| 359 class ViaTwice : public Via { | 360 class ViaTwice : public Via { |
| 360 public: | 361 public: |
| 361 explicit ViaTwice(Sink* sink) : Via(sink) {} | 362 explicit ViaTwice(Sink* sink) : Via(sink) {} |
| 362 Error draw(const Src&, SkBitmap*, SkWStream*, SkString*) const override; | 363 Error draw(const Src&, SkBitmap*, SkWStream*, SkString*) const override; |
| 363 }; | 364 }; |
| 364 | 365 |
| 365 } // namespace DM | 366 } // namespace DM |
| 366 | 367 |
| 367 #endif//DMSrcSink_DEFINED | 368 #endif//DMSrcSink_DEFINED |
| OLD | NEW |