| OLD | NEW |
| 1 // Copyright 2012 Google Inc. All Rights Reserved. | 1 // Copyright 2012 Google Inc. All Rights Reserved. |
| 2 // | 2 // |
| 3 // Use of this source code is governed by a BSD-style license | 3 // Use of this source code is governed by a BSD-style license |
| 4 // that can be found in the COPYING file in the root of the source | 4 // that can be found in the COPYING file in the root of the source |
| 5 // tree. An additional intellectual property rights grant can be found | 5 // tree. An additional intellectual property rights grant can be found |
| 6 // in the file PATENTS. All contributing project authors may | 6 // in the file PATENTS. All contributing project authors may |
| 7 // be found in the AUTHORS file in the root of the source tree. | 7 // be found in the AUTHORS file in the root of the source tree. |
| 8 // ----------------------------------------------------------------------------- | 8 // ----------------------------------------------------------------------------- |
| 9 // | 9 // |
| 10 // Author: Jyrki Alakuijala (jyrki@google.com) | 10 // Author: Jyrki Alakuijala (jyrki@google.com) |
| (...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 uint32_t* offset_length_; | 123 uint32_t* offset_length_; |
| 124 // This is the maximum size of the hash_chain that can be constructed. | 124 // This is the maximum size of the hash_chain that can be constructed. |
| 125 // Typically this is the pixel count (width x height) for a given image. | 125 // Typically this is the pixel count (width x height) for a given image. |
| 126 int size_; | 126 int size_; |
| 127 }; | 127 }; |
| 128 | 128 |
| 129 // Must be called first, to set size. | 129 // Must be called first, to set size. |
| 130 int VP8LHashChainInit(VP8LHashChain* const p, int size); | 130 int VP8LHashChainInit(VP8LHashChain* const p, int size); |
| 131 // Pre-compute the best matches for argb. | 131 // Pre-compute the best matches for argb. |
| 132 int VP8LHashChainFill(VP8LHashChain* const p, int quality, | 132 int VP8LHashChainFill(VP8LHashChain* const p, int quality, |
| 133 const uint32_t* const argb, int xsize, int ysize); | 133 const uint32_t* const argb, int xsize, int ysize, |
| 134 int low_effort); |
| 134 void VP8LHashChainClear(VP8LHashChain* const p); // release memory | 135 void VP8LHashChainClear(VP8LHashChain* const p); // release memory |
| 135 | 136 |
| 136 // ----------------------------------------------------------------------------- | 137 // ----------------------------------------------------------------------------- |
| 137 // VP8LBackwardRefs (block-based backward-references storage) | 138 // VP8LBackwardRefs (block-based backward-references storage) |
| 138 | 139 |
| 139 // maximum number of reference blocks the image will be segmented into | 140 // maximum number of reference blocks the image will be segmented into |
| 140 #define MAX_REFS_BLOCK_PER_IMAGE 16 | 141 #define MAX_REFS_BLOCK_PER_IMAGE 16 |
| 141 | 142 |
| 142 typedef struct PixOrCopyBlock PixOrCopyBlock; // forward declaration | 143 typedef struct PixOrCopyBlock PixOrCopyBlock; // forward declaration |
| 143 typedef struct VP8LBackwardRefs VP8LBackwardRefs; | 144 typedef struct VP8LBackwardRefs VP8LBackwardRefs; |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 197 VP8LBackwardRefs* VP8LGetBackwardReferences( | 198 VP8LBackwardRefs* VP8LGetBackwardReferences( |
| 198 int width, int height, const uint32_t* const argb, int quality, | 199 int width, int height, const uint32_t* const argb, int quality, |
| 199 int low_effort, int* const cache_bits, | 200 int low_effort, int* const cache_bits, |
| 200 const VP8LHashChain* const hash_chain, VP8LBackwardRefs refs[2]); | 201 const VP8LHashChain* const hash_chain, VP8LBackwardRefs refs[2]); |
| 201 | 202 |
| 202 #ifdef __cplusplus | 203 #ifdef __cplusplus |
| 203 } | 204 } |
| 204 #endif | 205 #endif |
| 205 | 206 |
| 206 #endif // WEBP_ENC_BACKWARD_REFERENCES_H_ | 207 #endif // WEBP_ENC_BACKWARD_REFERENCES_H_ |
| OLD | NEW |