Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
From: Stefano Sabatini <stefasab@gmail.com>
To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
Subject: Re: [FFmpeg-devel] [PATCH] fftools/ffprobe: print exported stream AVOptions
Date: Sun, 7 May 2023 23:20:50 +0200
Message-ID: <20230507212050.GA4348@mariano> (raw)
In-Reply-To: <20230505231856.29607-1-jamrial@gmail.com>

On date Friday 2023-05-05 20:18:56 -0300, James Almer wrote:
> Similar to the decoder AVOptions above.

Please briefly specify the use case in the log.

> Signed-off-by: James Almer <jamrial@gmail.com>
> ---
>  fftools/ffprobe.c             | 12 ++++++++++++
>  tests/ref/fate/flv-demux      |  4 ++--
>  tests/ref/fate/ts-demux       |  6 +++---
>  tests/ref/fate/ts-opus-demux  |  2 +-
>  tests/ref/fate/ts-small-demux |  2 +-
>  5 files changed, 19 insertions(+), 7 deletions(-)
> 
> diff --git a/fftools/ffprobe.c b/fftools/ffprobe.c
> index 43bf10db54..9599b3b1b2 100644
> --- a/fftools/ffprobe.c
> +++ b/fftools/ffprobe.c
> @@ -3127,6 +3127,18 @@ static int show_stream(WriterContext *w, AVFormatContext *fmt_ctx, int stream_id
>          }
>      }
>  
> +    if (fmt_ctx->iformat->priv_class && show_private_data) {
> +        const AVOption *opt = NULL;
> +        while (opt = av_opt_next(fmt_ctx->priv_data, opt)) {
> +            uint8_t *str;
> +            if (!(opt->flags & AV_OPT_FLAG_EXPORT)) continue;
> +            if (av_opt_get(fmt_ctx->priv_data, opt->name, 0, &str) >= 0) {
> +                print_str(opt->name, str);
> +                av_free(str);
> +            }
> +        }
> +    }

maybe factorize with the other similar code?

[...]

LGTM otherwise.
_______________________________________________
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".

  reply	other threads:[~2023-05-07 21:21 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-05 23:18 James Almer
2023-05-07 21:20 ` Stefano Sabatini [this message]
2023-05-07 22:30   ` James Almer
2023-05-07 22:51     ` Stefano Sabatini
2023-05-08 14:10       ` James Almer

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=20230507212050.GA4348@mariano \
    --to=stefasab@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