[vlc-devel] [PATCH v3 2/3] display: use set_callbacks_display() to set the display module callbacks
Alexandre Janniaux
ajanni at videolabs.io
Tue Jul 9 15:30:55 CEST 2019
Hi, there is a leftover error in the commit message.
For this patchset, this would not be a warning but an error instead.
On Tue, Jul 09, 2019 at 03:19:11PM +0200, Steve Lhomme wrote:
> If the signature is different there will be a warning.
> ---
> modules/hw/mmal/vout.c | 2 +-
> modules/hw/vdpau/display.c | 2 +-
> modules/video_output/android/display.c | 4 ++--
> modules/video_output/caca.c | 2 +-
> modules/video_output/caopengllayer.m | 2 +-
> modules/video_output/decklink.cpp | 2 +-
> modules/video_output/fb.c | 2 +-
> modules/video_output/flaschen.c | 2 +-
> modules/video_output/ios.m | 2 +-
> modules/video_output/kms.c | 2 +-
> modules/video_output/kva.c | 2 +-
> modules/video_output/macosx.m | 2 +-
> modules/video_output/opengl/display.c | 4 ++--
> modules/video_output/splitter.c | 2 +-
> modules/video_output/vdummy.c | 4 ++--
> modules/video_output/vmem.c | 2 +-
> modules/video_output/vulkan/display.c | 5 +++--
> modules/video_output/wayland/shm.c | 2 +-
> modules/video_output/win32/direct3d11.c | 2 +-
> modules/video_output/win32/direct3d9.c | 2 +-
> modules/video_output/win32/glwin32.c | 2 +-
> modules/video_output/win32/wingdi.c | 2 +-
> modules/video_output/xcb/render.c | 4 ++--
> modules/video_output/xcb/x11.c | 2 +-
> modules/video_output/yuv.c | 4 ++--
> 25 files changed, 32 insertions(+), 31 deletions(-)
>
> diff --git a/modules/hw/mmal/vout.c b/modules/hw/mmal/vout.c
> index 8493d6ad647..3c5ceeb6816 100644
> --- a/modules/hw/mmal/vout.c
> +++ b/modules/hw/mmal/vout.c
> @@ -83,7 +83,7 @@ vlc_module_begin()
> MMAL_ADJUST_REFRESHRATE_LONGTEXT, false)
> add_bool(MMAL_NATIVE_INTERLACED, false, MMAL_NATIVE_INTERLACE_TEXT,
> MMAL_NATIVE_INTERLACE_LONGTEXT, false)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> vlc_module_end()
>
> struct dmx_region_t {
> diff --git a/modules/hw/vdpau/display.c b/modules/hw/vdpau/display.c
> index c5ebf6639f7..c1891ae713d 100644
> --- a/modules/hw/vdpau/display.c
> +++ b/modules/hw/vdpau/display.c
> @@ -47,7 +47,7 @@ vlc_module_begin()
> set_category(CAT_VIDEO)
> set_subcategory(SUBCAT_VIDEO_VOUT)
> set_capability("vout display", 0)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
>
> add_shortcut("vdpau")
> vlc_module_end()
> diff --git a/modules/video_output/android/display.c b/modules/video_output/android/display.c
> index 908eb6d06cf..63cbfc28493 100644
> --- a/modules/video_output/android/display.c
> +++ b/modules/video_output/android/display.c
> @@ -65,12 +65,12 @@ vlc_module_begin()
> set_capability("vout display", 260)
> add_shortcut("android-display")
> add_string(CFG_PREFIX "chroma", NULL, CHROMA_TEXT, CHROMA_LONGTEXT, true)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> add_submodule ()
> set_description("Android opaque video output")
> set_capability("vout display", 280)
> add_shortcut("android-opaque")
> - set_callbacks(OpenOpaque, Close)
> + set_callbacks_display(OpenOpaque, Close)
> vlc_module_end()
>
> /*****************************************************************************
> diff --git a/modules/video_output/caca.c b/modules/video_output/caca.c
> index b7d9040d37c..6d79c658142 100644
> --- a/modules/video_output/caca.c
> +++ b/modules/video_output/caca.c
> @@ -531,5 +531,5 @@ vlc_module_begin()
> set_subcategory(SUBCAT_VIDEO_VOUT)
> set_description(N_("Color ASCII art video output"))
> set_capability("vout display", 15)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> vlc_module_end()
> diff --git a/modules/video_output/caopengllayer.m b/modules/video_output/caopengllayer.m
> index f328657655d..8aac36ada9a 100644
> --- a/modules/video_output/caopengllayer.m
> +++ b/modules/video_output/caopengllayer.m
> @@ -56,7 +56,7 @@ vlc_module_begin()
> set_capability("vout display", 0)
> set_category(CAT_VIDEO)
> set_subcategory(SUBCAT_VIDEO_VOUT)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> vlc_module_end()
>
> static picture_pool_t *Pool (vout_display_t *vd, unsigned requested_count);
> diff --git a/modules/video_output/decklink.cpp b/modules/video_output/decklink.cpp
> index 5499d4dd08e..f28e3c772fe 100644
> --- a/modules/video_output/decklink.cpp
> +++ b/modules/video_output/decklink.cpp
> @@ -255,7 +255,7 @@ vlc_module_begin()
> set_category(CAT_VIDEO)
> set_subcategory(SUBCAT_VIDEO_VOUT)
> set_capability("vout display", 0)
> - set_callbacks (OpenVideo, CloseVideo)
> + set_callbacks_display (OpenVideo, CloseVideo)
> set_section(N_("DeckLink Video Options"), NULL)
> add_string(VIDEO_CFG_PREFIX "video-connection", "sdi",
> VIDEO_CONNECTION_TEXT, VIDEO_CONNECTION_LONGTEXT, true)
> diff --git a/modules/video_output/fb.c b/modules/video_output/fb.c
> index fff5ff31fd0..41cdcc9821f 100644
> --- a/modules/video_output/fb.c
> +++ b/modules/video_output/fb.c
> @@ -88,7 +88,7 @@ vlc_module_begin ()
> add_obsolete_bool("fb-hw-accel") /* since 4.0.0 */
> set_description(N_("GNU/Linux framebuffer video output"))
> set_capability("vout display", 30)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> vlc_module_end ()
>
> /*****************************************************************************
> diff --git a/modules/video_output/flaschen.c b/modules/video_output/flaschen.c
> index 15d6dd48b9f..20941e745ba 100644
> --- a/modules/video_output/flaschen.c
> +++ b/modules/video_output/flaschen.c
> @@ -62,7 +62,7 @@ vlc_module_begin ()
> set_shortname( N_("Flaschen") )
> set_description( N_("Flaschen-Taschen video output") )
> set_capability( "vout display", 0 )
> - set_callbacks( Open, Close )
> + set_callbacks_display( Open, Close )
> add_shortcut( "flaschen" )
>
> set_category( CAT_VIDEO )
> diff --git a/modules/video_output/ios.m b/modules/video_output/ios.m
> index d394e8a92a3..ce0b46681c5 100644
> --- a/modules/video_output/ios.m
> +++ b/modules/video_output/ios.m
> @@ -74,7 +74,7 @@ vlc_module_begin ()
> set_category(CAT_VIDEO)
> set_subcategory(SUBCAT_VIDEO_VOUT)
> set_capability("vout display", 300)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
>
> add_shortcut("vout_ios2", "vout_ios")
> add_glopts()
> diff --git a/modules/video_output/kms.c b/modules/video_output/kms.c
> index 3e0f02188fb..0d27d0d574a 100644
> --- a/modules/video_output/kms.c
> +++ b/modules/video_output/kms.c
> @@ -789,5 +789,5 @@ vlc_module_begin ()
> true)
> set_description("Linux kernel mode setting video output")
> set_capability("vout display", 30)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> vlc_module_end ()
> diff --git a/modules/video_output/kva.c b/modules/video_output/kva.c
> index 7900614019a..b59b8e2efcf 100644
> --- a/modules/video_output/kva.c
> +++ b/modules/video_output/kva.c
> @@ -72,7 +72,7 @@ vlc_module_begin ()
> set_description( N_("K Video Acceleration video output") )
> set_capability( "vout display", 100 )
> add_shortcut( "kva" )
> - set_callbacks( Open, Close )
> + set_callbacks_display( Open, Close )
> vlc_module_end ()
>
> /*****************************************************************************
> diff --git a/modules/video_output/macosx.m b/modules/video_output/macosx.m
> index de858793413..d69efbf1d00 100644
> --- a/modules/video_output/macosx.m
> +++ b/modules/video_output/macosx.m
> @@ -77,7 +77,7 @@ vlc_module_begin ()
> set_category (CAT_VIDEO)
> set_subcategory (SUBCAT_VIDEO_VOUT)
> set_capability ("vout display", 300)
> - set_callbacks (Open, Close)
> + set_callbacks_display (Open, Close)
> add_shortcut ("macosx", "vout_macosx")
> add_glopts ()
> vlc_module_end ()
> diff --git a/modules/video_output/opengl/display.c b/modules/video_output/opengl/display.c
> index 69e45e744d4..d99a1b6e6d7 100644
> --- a/modules/video_output/opengl/display.c
> +++ b/modules/video_output/opengl/display.c
> @@ -50,7 +50,7 @@ vlc_module_begin ()
> set_shortname (N_("OpenGL ES2"))
> set_description (N_("OpenGL for Embedded Systems 2 video output"))
> set_capability ("vout display", 265)
> - set_callbacks (Open, Close)
> + set_callbacks_display (Open, Close)
> add_shortcut ("opengles2", "gles2")
> add_module("gles2", "opengl es2", NULL, GLES2_TEXT, PROVIDER_LONGTEXT)
>
> @@ -63,7 +63,7 @@ vlc_module_begin ()
> set_category (CAT_VIDEO)
> set_subcategory (SUBCAT_VIDEO_VOUT)
> set_capability ("vout display", 270)
> - set_callbacks (Open, Close)
> + set_callbacks_display (Open, Close)
> add_shortcut ("opengl", "gl")
> add_module("gl", "opengl", NULL, GL_TEXT, PROVIDER_LONGTEXT)
> #endif
> diff --git a/modules/video_output/splitter.c b/modules/video_output/splitter.c
> index de7396788d9..89c54508201 100644
> --- a/modules/video_output/splitter.c
> +++ b/modules/video_output/splitter.c
> @@ -336,7 +336,7 @@ vlc_module_begin()
> set_category(CAT_VIDEO)
> set_subcategory(SUBCAT_VIDEO_VOUT)
> set_capability("vout display", 0)
> - set_callbacks(vlc_vidsplit_Open, vlc_vidsplit_Close)
> + set_callbacks_display(vlc_vidsplit_Open, vlc_vidsplit_Close)
> add_module("video-splitter", "video splitter", NULL,
> N_("Video splitter module"), N_("Video splitter module"))
> vlc_module_end()
> diff --git a/modules/video_output/vdummy.c b/modules/video_output/vdummy.c
> index a2ae8dad44b..1d6c1cfe395 100644
> --- a/modules/video_output/vdummy.c
> +++ b/modules/video_output/vdummy.c
> @@ -47,7 +47,7 @@ vlc_module_begin ()
> set_shortname( N_("Dummy") )
> set_description( N_("Dummy video output") )
> set_capability( "vout display", 0 )
> - set_callbacks( OpenDummy, NULL )
> + set_callbacks_display( OpenDummy, NULL )
> add_shortcut( "dummy" )
>
> set_category( CAT_VIDEO )
> @@ -58,7 +58,7 @@ vlc_module_begin ()
> set_description( N_("Statistics video output") )
> set_capability( "vout display", 0 )
> add_shortcut( "stats" )
> - set_callbacks( OpenStats, NULL )
> + set_callbacks_display( OpenStats, NULL )
> vlc_module_end ()
>
>
> diff --git a/modules/video_output/vmem.c b/modules/video_output/vmem.c
> index ee5e544656e..4506703ecfc 100644
> --- a/modules/video_output/vmem.c
> +++ b/modules/video_output/vmem.c
> @@ -75,7 +75,7 @@ vlc_module_begin()
> add_obsolete_string("vmem-unlock") /* obsoleted since 1.1.1 */
> add_obsolete_string("vmem-data") /* obsoleted since 1.1.1 */
>
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> vlc_module_end()
>
> /*****************************************************************************
> diff --git a/modules/video_output/vulkan/display.c b/modules/video_output/vulkan/display.c
> index 75416e4cded..1af573b1f1d 100644
> --- a/modules/video_output/vulkan/display.c
> +++ b/modules/video_output/vulkan/display.c
> @@ -386,12 +386,13 @@ static int Control(vout_display_t *vd, int query, va_list ap)
> #define DISABLE_DR_TEXT "Disable direct rendering / zero-copy upload"
> #define DISABLE_DR_LONGTEXT "Direct rendering is a technique where image data is uploaded via a mapped buffer instead of via memcpy. On some platforms this might be very slow (due to poor readback performance from mapped memory), in which cases this flag would help."
>
> -vlc_module_begin () set_shortname ("Vulkan")
> +vlc_module_begin ()
> + set_shortname ("Vulkan")
> set_description (N_("Vulkan video output"))
> set_category (CAT_VIDEO)
> set_subcategory (SUBCAT_VIDEO_VOUT)
> set_capability ("vout display", 0)
> - set_callbacks (Open, Close)
> + set_callbacks_display (Open, Close)
> add_shortcut ("vulkan", "vk")
> add_module ("vk", "vulkan", NULL, VK_TEXT, PROVIDER_LONGTEXT)
>
> diff --git a/modules/video_output/wayland/shm.c b/modules/video_output/wayland/shm.c
> index 699c8dc50c8..5ced9b206d2 100644
> --- a/modules/video_output/wayland/shm.c
> +++ b/modules/video_output/wayland/shm.c
> @@ -400,6 +400,6 @@ vlc_module_begin()
> set_category(CAT_VIDEO)
> set_subcategory(SUBCAT_VIDEO_VOUT)
> set_capability("vout display", 170)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> add_shortcut("wl")
> vlc_module_end()
> diff --git a/modules/video_output/win32/direct3d11.c b/modules/video_output/win32/direct3d11.c
> index f23cd048101..16752161045 100644
> --- a/modules/video_output/win32/direct3d11.c
> +++ b/modules/video_output/win32/direct3d11.c
> @@ -86,7 +86,7 @@ vlc_module_begin ()
>
> set_capability("vout display", 300)
> add_shortcut("direct3d11")
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> vlc_module_end ()
>
> struct vout_display_sys_t
> diff --git a/modules/video_output/win32/direct3d9.c b/modules/video_output/win32/direct3d9.c
> index 4fe32fbb6df..b30a22dee20 100644
> --- a/modules/video_output/win32/direct3d9.c
> +++ b/modules/video_output/win32/direct3d9.c
> @@ -115,7 +115,7 @@ vlc_module_begin ()
>
> set_capability("vout display", 280)
> add_shortcut("direct3d9", "direct3d")
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
>
> #ifdef HAVE_GL
> add_submodule()
> diff --git a/modules/video_output/win32/glwin32.c b/modules/video_output/win32/glwin32.c
> index a10a7407093..fce46d879cf 100644
> --- a/modules/video_output/win32/glwin32.c
> +++ b/modules/video_output/win32/glwin32.c
> @@ -51,7 +51,7 @@ vlc_module_begin()
> set_description(N_("OpenGL video output for Windows"))
> set_capability("vout display", 275)
> add_shortcut("glwin32", "opengl")
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> add_glopts()
> vlc_module_end()
>
> diff --git a/modules/video_output/win32/wingdi.c b/modules/video_output/win32/wingdi.c
> index 25308b92a7e..d5fbb565ef2 100644
> --- a/modules/video_output/win32/wingdi.c
> +++ b/modules/video_output/win32/wingdi.c
> @@ -52,7 +52,7 @@ vlc_module_begin ()
> set_shortname("GDI")
> set_description(N_("Windows GDI video output"))
> set_capability("vout display", 110)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> vlc_module_end ()
>
>
> diff --git a/modules/video_output/xcb/render.c b/modules/video_output/xcb/render.c
> index 93825a32d43..5a79bc37810 100644
> --- a/modules/video_output/xcb/render.c
> +++ b/modules/video_output/xcb/render.c
> @@ -516,7 +516,7 @@ FindPictScreen(const xcb_setup_t *setup, const xcb_screen_t *scr,
>
> /* Find an X11 visual for a RENDER picture format */
> static xcb_visualid_t
> -FindVisual(const xcb_setup_t *setup, const xcb_screen_t *scr,
> +FindVisual(const xcb_setup_t *setup, const xcb_screen_t *scr,
> const xcb_render_query_pict_formats_reply_t *r,
> xcb_render_pictformat_t fmt_id)
> {
> @@ -714,7 +714,7 @@ vlc_module_begin()
> set_category(CAT_VIDEO)
> set_subcategory(SUBCAT_VIDEO_VOUT)
> set_capability("vout display", 200)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> add_shortcut("x11-render", "xcb-render", "render")
> add_string("x11-render-filter", "good", N_("Scaling mode"),
> N_("Scaling mode"), true)
> diff --git a/modules/video_output/xcb/x11.c b/modules/video_output/xcb/x11.c
> index 379a83abc7c..4d4109bbd5d 100644
> --- a/modules/video_output/xcb/x11.c
> +++ b/modules/video_output/xcb/x11.c
> @@ -355,7 +355,7 @@ vlc_module_begin()
> set_category(CAT_VIDEO)
> set_subcategory(SUBCAT_VIDEO_VOUT)
> set_capability("vout display", 100)
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> add_shortcut("xcb-x11", "x11")
>
> add_obsolete_bool("x11-shm") /* obsoleted since 2.0.0 */
> diff --git a/modules/video_output/yuv.c b/modules/video_output/yuv.c
> index 790729ca96f..ba590227406 100644
> --- a/modules/video_output/yuv.c
> +++ b/modules/video_output/yuv.c
> @@ -67,7 +67,7 @@ vlc_module_begin()
> add_bool (CFG_PREFIX "yuv4mpeg2", false,
> YUV4MPEG2_TEXT, YUV4MPEG2_LONGTEXT, true)
>
> - set_callbacks(Open, Close)
> + set_callbacks_display(Open, Close)
> vlc_module_end()
>
> /*****************************************************************************
> @@ -212,7 +212,7 @@ static void Display(vout_display_t *vd, picture_t *picture)
> * the exact fourcc used. */
> header = "YUV4MPEG2";
> } else {
> - snprintf(buffer, sizeof(buffer), "%4.4s",
> + snprintf(buffer, sizeof(buffer), "%4.4s",
> (const char*)&fmt.i_chroma);
> header = buffer;
> }
> --
> 2.17.1
>
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel
More information about the vlc-devel
mailing list