Re: [FFmpeg-devel] [PATCH v2] avcodec: add farbfeld encoder

2024-06-18 Thread Tomas Härdin
mån 2024-06-03 klockan 19:16 + skrev marcus: > > > > > > > Check the return value of av_image_get_buffer_size() before > > > adding > > > > > HEADER_SIZE to it. There will be a signed overflow (UB) for > > > images of > > > size 16385x16385 (and many others). > > > > > > Sorry, I missed th

Re: [FFmpeg-devel] [PATCH v2] avcodec: add farbfeld encoder

2024-06-03 Thread Tomas Härdin
> Check the return value of av_image_get_buffer_size() before adding > HEADER_SIZE to it. There will be a signed overflow (UB) for images of > size 16385x16385 (and many others). Sorry, I missed the multiplication by h+128 in av_image_check_size2(). So this isn't a problem in this specific case.

Re: [FFmpeg-devel] [PATCH v2] avcodec: add farbfeld encoder

2024-06-03 Thread Tomas Härdin
This format seems to reproduce some of the same issues as QOI: > The RGB-data should be sRGB for best interoperability and not alpha- > premultiplied. This seems to imply it could be something other than sRGB since it says SHOULD rather than MUST. This probably isn't a huge issue, but it should