| 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 SkJpegCodec_DEFINED | 8 #ifndef SkJpegCodec_DEFINED |
| 9 #define SkJpegCodec_DEFINED | 9 #define SkJpegCodec_DEFINED |
| 10 | 10 |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 99 * before the decode manager. | 99 * before the decode manager. |
| 100 */ | 100 */ |
| 101 ~SkJpegCodec() override; | 101 ~SkJpegCodec() override; |
| 102 | 102 |
| 103 /* | 103 /* |
| 104 * Handles rewinding the input stream if it is necessary | 104 * Handles rewinding the input stream if it is necessary |
| 105 */ | 105 */ |
| 106 bool handleRewind(); | 106 bool handleRewind(); |
| 107 | 107 |
| 108 /* | 108 /* |
| 109 * Checks if the conversion between the input image and the requested output |
| 110 * image has been implemented |
| 111 * Sets the output color space |
| 112 */ |
| 113 bool setOutputColorSpace(const SkImageInfo& dst); |
| 114 |
| 115 /* |
| 109 * Checks if we can scale to the requested dimensions and scales the dimensi
ons | 116 * Checks if we can scale to the requested dimensions and scales the dimensi
ons |
| 110 * if possible | 117 * if possible |
| 111 */ | 118 */ |
| 112 bool scaleToDimensions(uint32_t width, uint32_t height); | 119 bool scaleToDimensions(uint32_t width, uint32_t height); |
| 113 | 120 |
| 114 /* | 121 /* |
| 115 * Create the swizzler based on the encoded format | 122 * Create the swizzler based on the encoded format |
| 116 */ | 123 */ |
| 117 void initializeSwizzler(const SkImageInfo& dstInfo, void* dst, size_t dstRow
Bytes, | 124 void initializeSwizzler(const SkImageInfo& dstInfo, void* dst, size_t dstRow
Bytes, |
| 118 const Options& options); | 125 const Options& options); |
| 119 | 126 |
| 120 SkAutoTDelete<JpegDecoderMgr> fDecoderMgr; | 127 SkAutoTDelete<JpegDecoderMgr> fDecoderMgr; |
| 121 SkAutoTDelete<SkSwizzler> fSwizzler; | |
| 122 size_t fSrcRowBytes; | |
| 123 | 128 |
| 124 friend class SkJpegScanlineDecoder; | 129 friend class SkJpegScanlineDecoder; |
| 125 | 130 |
| 126 typedef SkCodec INHERITED; | 131 typedef SkCodec INHERITED; |
| 127 }; | 132 }; |
| 128 | 133 |
| 129 #endif | 134 #endif |
| OLD | NEW |