Quoting James Almer (2022-06-07 13:39:55)
> >> diff --git a/libavutil/frame.h b/libavutil/frame.h
> >> index 33fac2054c..e5c10e2b66 100644
> >> --- a/libavutil/frame.h
> >> +++ b/libavutil/frame.h
> >> @@ -752,6 +752,19 @@ void av_frame_free(AVFrame **frame);
> >>*/
> >> int av_frame_ref(AVFr
On 6/7/2022 7:21 AM, Anton Khirnov wrote:
Quoting James Almer (2022-06-05 19:44:58)
+
+/* duplicate the frame data if it's not refcounted */
+if (!src->buf[0]) {
+for (int i = 0; i < FF_ARRAY_ELEMS(dst->buf); i++)
+av_buffer_unref(&dst->buf[i]);
+for (int i =
Quoting James Almer (2022-06-05 19:44:58)
> +
> +/* duplicate the frame data if it's not refcounted */
> +if (!src->buf[0]) {
> +for (int i = 0; i < FF_ARRAY_ELEMS(dst->buf); i++)
> +av_buffer_unref(&dst->buf[i]);
> +for (int i = 0; i < dst->nb_extended_buf; i++)