mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-11-11 04:07:21 +03:00
Added version check for WebP
This commit is contained in:
parent
1f6df76c42
commit
3587f27780
|
@ -635,7 +635,10 @@ WebPEncode_wrapper(PyObject *self, PyObject *args) {
|
|||
config.lossless = lossless;
|
||||
config.quality = quality_factor;
|
||||
config.method = method;
|
||||
#if WEBP_ENCODER_ABI_VERSION >= 0x0209
|
||||
// the exact flag is only available in libwebp 0.5.0 and later
|
||||
config.exact = exact;
|
||||
#endif
|
||||
|
||||
// Validate the config
|
||||
if (!WebPValidateConfig(&config)) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user