[FFmpeg-devel] [PATCH v3] avfilter/vf_zoompan: fix shaking when zooming
Paul B Mahol
onemda at gmail.com
Tue Jan 28 16:46:54 EET 2020
On 1/28/20, Robert Deibel <deibel.robert at googlemail.com> wrote:
> On 27.01.20 16:44, Paul B Mahol wrote:
>> On 1/27/20, Robert Deibel <deibel.robert at googlemail.com> wrote:
>>> - y = *dy = av_clipd(*dy, 0, FFMAX(in->height - h, 0));
>>> - var_values[VAR_Y] = *dy;
>>> - y &= ~((1 << s->desc->log2_chroma_h) - 1);
>>> -
>>> - out = ff_get_video_buffer(outlink, outlink->w, outlink->h);
>>> + out = ff_get_video_buffer(outlink, overscaled_w, overscaled_h);
>> This is wrong. outlink->w/h should be used always, otherwise outlink
>> w/h differs from frame w/h.
>>
> So how should I create a video buffer? I tried av_frame_alloc + setting
> width, height and format + av_frame_get_buffer, but this resulted in a
> heavy performance impact. Apart from the fact, that I can't get the
> correct data copied.
>
> Also, if it's not allowed to pass other w/h why is it even possible? Or
> is it only a problem if I use the outlink? Could I request a buffer from
> the inlink with the modified sizes?
Frame w/h should be exactly same as outlink w/h.
Otherwise output will not have always same w/h.
Why are you changing w/h at all?
>
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request at ffmpeg.org with subject "unsubscribe".
More information about the ffmpeg-devel
mailing list