On Thu, Jul 04, 2024 at 04:30:59PM +0200, Niklas Haas wrote: > From: Niklas Haas > > When dealing with 4x subsampling ratios (log2 == 2), such as can arise > with 4:1:1 or 4:1:0, a value range of 512 is not enough to cover the > range of possible scenarios. > > For example, bottom-sited chroma in 4:1:0 would require an offset of 768 > (three luma rows). Simply double the limit to 1024. I don't see any > place in initFilter() that would experience overflow as a result of this > change, especially since get_local_pos() right-shifts it by the > subsampling ratio again. > --- > libswscale/options.c | 8 ++++---- > 1 file changed, 4 insertions(+), 4 deletions(-) maybe limit it to the max value you know is needed instead of simply doubling. it can be bumped up more later if we run in cases needing more either way LGTM thx [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB He who knows, does not speak. He who speaks, does not know. -- Lao Tsu