From: Paul B Mahol <onemda@gmail.com>
To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
Subject: Re: [FFmpeg-devel] [PATCH 1/2] avcodec: add null encoders
Date: Tue, 15 Mar 2022 09:53:39 +0100
Message-ID: <CAPYw7P6nDiVwZFrNz+z83gcKAA9r1wUpAXKvj0nqjMrZ4KKAeg@mail.gmail.com> (raw)
In-Reply-To: <164733404216.19727.13997273471475705829@lain.red.khirnov.net>
On Tue, Mar 15, 2022 at 9:47 AM Anton Khirnov <anton@khirnov.net> wrote:
> Quoting Paul B Mahol (2022-03-14 12:56:01)
> > +static int null_encoder(AVCodecContext *avctx, AVPacket *pkt,
> > + const AVFrame *frame, int *got_packet)
> > +{
> > + int ret;
> > +
> > + pkt->pts = frame->pts;
> > + if (avctx->codec_type == AVMEDIA_TYPE_AUDIO)
> > + pkt->duration = ff_samples_to_time_base(avctx,
> frame->nb_samples);
> > + pkt->flags |= AV_PKT_FLAG_KEY;
> > + if ((ret = ff_alloc_packet(avctx, pkt, 1)) < 0)
> > + return ret;
> > + *got_packet = 1;
>
> Why return packets at all? Wouldn't it be simpler to just never return
> any data?
>
But than there is no progress report at all.
>
> --
> Anton Khirnov
> _______________________________________________
> 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".
>
_______________________________________________
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".
prev parent reply other threads:[~2022-03-15 8:51 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-14 11:56 Paul B Mahol
2022-03-14 11:56 ` [FFmpeg-devel] [PATCH 2/2] avformat/nullenc: use null encoders instead Paul B Mahol
2022-03-14 12:12 ` [FFmpeg-devel] [PATCH 1/2] avcodec: add null encoders James Almer
2022-03-14 12:17 ` Paul B Mahol
2022-03-14 12:17 ` James Almer
2022-03-14 12:31 ` Paul B Mahol
2022-03-15 8:47 ` Anton Khirnov
2022-03-15 8:53 ` Paul B Mahol [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAPYw7P6nDiVwZFrNz+z83gcKAA9r1wUpAXKvj0nqjMrZ4KKAeg@mail.gmail.com \
--to=onemda@gmail.com \
--cc=ffmpeg-devel@ffmpeg.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git