mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-03-25 04:19:05 +00:00
lavfi/showspectrum: fix outpicref initialization.
In 81f2549
, output pixel format was changed from rgb24 to planar yuv,
but the initialization was left unchanged. As a result, the chroma
planes were left uninitalized. This was not noticed since the current
ff_get_video_buffer() seems to be initializing the buffer. This won't be
the case anymore after the Evil Plan.
This commit is contained in:
parent
22cc8a103c
commit
ee0a8bcba1
@ -226,7 +226,9 @@ static int config_output(AVFilterLink *outlink)
|
||||
if (!outpicref)
|
||||
return AVERROR(ENOMEM);
|
||||
outlink->sample_aspect_ratio = (AVRational){1,1};
|
||||
memset(outpicref->data[0], 0, outlink->h * outpicref->linesize[0]);
|
||||
memset(outpicref->data[0], 0, outlink->h * outpicref->linesize[0]);
|
||||
memset(outpicref->data[1], 128, outlink->h * outpicref->linesize[1]);
|
||||
memset(outpicref->data[2], 128, outlink->h * outpicref->linesize[2]);
|
||||
}
|
||||
|
||||
if (showspectrum->xpos >= outlink->w)
|
||||
|
Loading…
Reference in New Issue
Block a user