mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2026-06-16 04:32:47 +02:00
9ebfd68096
The 'sws_dither' and 'alphablend' options access 'SwsDither' and 'SwsAlphaBlend' enum fields as integers. This is unsafe when the code is compiled with -fshort-enums, as the enum size might be smaller than an int. Since the 'dither' and 'alpha_blend' struct members are part of the public API, their types cannot be easily changed. To ensure safe integer access and maintain ABI compatibility across different compiler settings, a MAX_ENUM value is added to force the enums to a 32-bit underlying type.