summaryrefslogtreecommitdiff
path: root/thirdparty/libwebp/src/webp/decode.h
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-03-04 13:49:50 +0100
committerGitHub <noreply@github.com>2019-03-04 13:49:50 +0100
commitd2c57e8431a6dd3a279eec9abdd6acd4ba288ca8 (patch)
tree7c516cd7752f1c8a23e5752d489003239099c1bc /thirdparty/libwebp/src/webp/decode.h
parent6e13002034152981efdceed864b4e48d70018a49 (diff)
parent93f6a065f8e0e083582890a245b7dcc3cd8c7ef6 (diff)
Merge pull request #26577 from akien-mga/webp-1.0.2
libwebp: Sync with upstream 1.0.2
Diffstat (limited to 'thirdparty/libwebp/src/webp/decode.h')
-rw-r--r--thirdparty/libwebp/src/webp/decode.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/thirdparty/libwebp/src/webp/decode.h b/thirdparty/libwebp/src/webp/decode.h
index 95d31e7619..ae8bfe840e 100644
--- a/thirdparty/libwebp/src/webp/decode.h
+++ b/thirdparty/libwebp/src/webp/decode.h
@@ -42,6 +42,12 @@ WEBP_EXTERN int WebPGetDecoderVersion(void);
// This function will also validate the header, returning true on success,
// false otherwise. '*width' and '*height' are only valid on successful return.
// Pointers 'width' and 'height' can be passed NULL if deemed irrelevant.
+// Note: The following chunk sequences (before the raw VP8/VP8L data) are
+// considered valid by this function:
+// RIFF + VP8(L)
+// RIFF + VP8X + (optional chunks) + VP8(L)
+// ALPH + VP8 <-- Not a valid WebP format: only allowed for internal purpose.
+// VP8(L) <-- Not a valid WebP format: only allowed for internal purpose.
WEBP_EXTERN int WebPGetInfo(const uint8_t* data, size_t data_size,
int* width, int* height);
@@ -425,6 +431,12 @@ WEBP_EXTERN VP8StatusCode WebPGetFeaturesInternal(
// Returns VP8_STATUS_OK when the features are successfully retrieved. Returns
// VP8_STATUS_NOT_ENOUGH_DATA when more data is needed to retrieve the
// features from headers. Returns error in other cases.
+// Note: The following chunk sequences (before the raw VP8/VP8L data) are
+// considered valid by this function:
+// RIFF + VP8(L)
+// RIFF + VP8X + (optional chunks) + VP8(L)
+// ALPH + VP8 <-- Not a valid WebP format: only allowed for internal purpose.
+// VP8(L) <-- Not a valid WebP format: only allowed for internal purpose.
static WEBP_INLINE VP8StatusCode WebPGetFeatures(
const uint8_t* data, size_t data_size,
WebPBitstreamFeatures* features) {