[FFmpeg-devel] [RFC][PATCH 2/2] lavfi/src_movie: Use movie_common_init instead individual wrappers
Stefano Sabatini
stefasab at gmail.com
Mon Jun 17 12:44:36 CEST 2013
On date Sunday 2013-06-16 22:02:14 +0200, Alexander Strasser encoded:
> Makes it easier to understand that there is no difference in init
> callback for movie and amovie. Also saves a few lines of code.
>
> Signed-off-by: Alexander Strasser <eclipse7 at gmx.net>
> ---
> libavfilter/src_movie.c | 14 ++------------
> 1 file changed, 2 insertions(+), 12 deletions(-)
>
> diff --git a/libavfilter/src_movie.c b/libavfilter/src_movie.c
> index f52d3a4..7d3ce78 100644
> --- a/libavfilter/src_movie.c
> +++ b/libavfilter/src_movie.c
> @@ -563,17 +563,12 @@ static int movie_request_frame(AVFilterLink *outlink)
>
> AVFILTER_DEFINE_CLASS(movie);
>
> -static av_cold int movie_init(AVFilterContext *ctx)
> -{
> - return movie_common_init(ctx);
> -}
> -
> AVFilter avfilter_avsrc_movie = {
> .name = "movie",
> .description = NULL_IF_CONFIG_SMALL("Read from a movie source."),
> .priv_size = sizeof(MovieContext),
> .priv_class = &movie_class,
> - .init = movie_init,
> + .init = movie_common_init,
> .uninit = movie_uninit,
> .query_formats = movie_query_formats,
>
> @@ -589,16 +584,11 @@ AVFilter avfilter_avsrc_movie = {
> #define amovie_options movie_options
> AVFILTER_DEFINE_CLASS(amovie);
>
> -static av_cold int amovie_init(AVFilterContext *ctx)
> -{
> - return movie_common_init(ctx);
> -}
> -
> AVFilter avfilter_avsrc_amovie = {
> .name = "amovie",
> .description = NULL_IF_CONFIG_SMALL("Read audio from a movie source."),
> .priv_size = sizeof(MovieContext),
> - .init = amovie_init,
> + .init = movie_common_init,
> .uninit = movie_uninit,
> .query_formats = movie_query_formats,
Looks nice, thanks.
More information about the ffmpeg-devel
mailing list