Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
From: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
To: ffmpeg-devel@ffmpeg.org
Subject: Re: [FFmpeg-devel] [PATCH] lswr: take const AVChannelLayout* in swr_alloc_set_opts2()
Date: Sat, 6 Aug 2022 13:50:37 +0200
Message-ID: <DB6PR0101MB22140B96C7CEE4C49267D8F38F619@DB6PR0101MB2214.eurprd01.prod.exchangelabs.com> (raw)
In-Reply-To: <20220805210039.4158-1-rcombs@rcombs.me>

rcombs:
> This is fully backwards-compatible in both ABI and API,
> so it's only a minor bump.

It is not fully backwards-compatible API-wise: If you use a function
pointer for swr_alloc_set_opts2 by hardcoding its type, you will get
warnings now (or even errors depending upon your -Werror; it is an error
by default for C++). Given that I do not know about other language
bindings I have so far refrained from applying
https://patchwork.ffmpeg.org/project/ffmpeg/patch/AS1PR01MB95649A21F5F9A45D40E6AC1D8F1F9@AS1PR01MB9564.eurprd01.prod.exchangelabs.com/
This does not mean that I block your patch; to the contrary: If it
breaks nothing, I will apply the above patch after a month or so.

- Andreas

> ---
>  libswresample/swresample.c | 4 ++--
>  libswresample/swresample.h | 4 ++--
>  libswresample/version.h    | 2 +-
>  3 files changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/libswresample/swresample.c b/libswresample/swresample.c
> index 9b77ef65bf..123ac65693 100644
> --- a/libswresample/swresample.c
> +++ b/libswresample/swresample.c
> @@ -83,8 +83,8 @@ FF_ENABLE_DEPRECATION_WARNINGS
>  #endif
>  
>  int swr_alloc_set_opts2(struct SwrContext **ps,
> -                        AVChannelLayout *out_ch_layout, enum AVSampleFormat out_sample_fmt, int out_sample_rate,
> -                        AVChannelLayout *in_ch_layout, enum AVSampleFormat  in_sample_fmt, int  in_sample_rate,
> +                        const AVChannelLayout *out_ch_layout, enum AVSampleFormat out_sample_fmt, int out_sample_rate,
> +                        const AVChannelLayout *in_ch_layout, enum AVSampleFormat  in_sample_fmt, int  in_sample_rate,
>                          int log_offset, void *log_ctx) {
>      struct SwrContext *s = *ps;
>      int ret;
> diff --git a/libswresample/swresample.h b/libswresample/swresample.h
> index 26d42fab8d..980be65783 100644
> --- a/libswresample/swresample.h
> +++ b/libswresample/swresample.h
> @@ -286,8 +286,8 @@ struct SwrContext *swr_alloc_set_opts(struct SwrContext *s,
>   *         On error, the Swr context is freed and *ps set to NULL.
>   */
>  int swr_alloc_set_opts2(struct SwrContext **ps,
> -                        AVChannelLayout *out_ch_layout, enum AVSampleFormat out_sample_fmt, int out_sample_rate,
> -                        AVChannelLayout *in_ch_layout, enum AVSampleFormat  in_sample_fmt, int  in_sample_rate,
> +                        const AVChannelLayout *out_ch_layout, enum AVSampleFormat out_sample_fmt, int out_sample_rate,
> +                        const AVChannelLayout *in_ch_layout, enum AVSampleFormat  in_sample_fmt, int  in_sample_rate,
>                          int log_offset, void *log_ctx);
>  /**
>   * @}
> diff --git a/libswresample/version.h b/libswresample/version.h
> index 66bac2fa9b..4b9952d914 100644
> --- a/libswresample/version.h
> +++ b/libswresample/version.h
> @@ -30,7 +30,7 @@
>  
>  #include "version_major.h"
>  
> -#define LIBSWRESAMPLE_VERSION_MINOR   8
> +#define LIBSWRESAMPLE_VERSION_MINOR   9
>  #define LIBSWRESAMPLE_VERSION_MICRO 100
>  
>  #define LIBSWRESAMPLE_VERSION_INT  AV_VERSION_INT(LIBSWRESAMPLE_VERSION_MAJOR, \

_______________________________________________
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:[~2022-08-06 11:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-05 21:00 rcombs
2022-08-06 11:50 ` Andreas Rheinhardt [this message]
2022-08-06 13:15 ` Anton Khirnov
2022-08-06 13:19   ` Anton Khirnov

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=DB6PR0101MB22140B96C7CEE4C49267D8F38F619@DB6PR0101MB2214.eurprd01.prod.exchangelabs.com \
    --to=andreas.rheinhardt@outlook.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