From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id C9918435D6 for ; Sat, 18 Jun 2022 04:02:05 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id C1D3468B4D0; Sat, 18 Jun 2022 07:02:04 +0300 (EEST) Received: from mout-p-103.mailbox.org (mout-p-103.mailbox.org [80.241.56.161]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 43D3F68B36A for ; Sat, 18 Jun 2022 07:01:58 +0300 (EEST) Received: from smtp2.mailbox.org (smtp2.mailbox.org [IPv6:2001:67c:2050:b231:465::2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-p-103.mailbox.org (Postfix) with ESMTPS id 4LQ2Kc19fNz9sSj for ; Sat, 18 Jun 2022 06:01:56 +0200 (CEST) Message-ID: <5cb7569c-ca1a-b476-ea69-d00260591069@gyani.pro> Date: Sat, 18 Jun 2022 09:31:45 +0530 MIME-Version: 1.0 Content-Language: en-US To: ffmpeg-devel@ffmpeg.org References: <20220617054451.6127-1-ffmpeg@gyani.pro> From: Gyan Doshi In-Reply-To: <20220617054451.6127-1-ffmpeg@gyani.pro> X-Rspamd-Queue-Id: 4LQ2Kc19fNz9sSj Subject: Re: [FFmpeg-devel] [PATCH] avcodec/mfenc: set frame size for audio encoders. X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On 2022-06-17 11:14 am, Gyan Doshi wrote: > Default avctx->frame_size is 0 which leads to init failure for > audio MediaFoundation encoders. Plan to push tonight. > --- > libavcodec/mfenc.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/libavcodec/mfenc.c b/libavcodec/mfenc.c > index 13ed7b3e11..ff9ffe4827 100644 > --- a/libavcodec/mfenc.c > +++ b/libavcodec/mfenc.c > @@ -1066,6 +1066,9 @@ static int mf_init_encoder(AVCodecContext *avctx) > > c->main_subtype = *subtype; > > + if (c->is_audio && !avctx->frame_size) > + avctx->frame_size = 1024; > + > if ((ret = mf_create(avctx, &c->functions, &c->mft, avctx->codec, use_hw)) < 0) > return ret; > _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".