[vlc-devel] [RFC 2/8] libvlc: rename libvlc_gl_resize_cb to libvlc_update_output_cb
Steve Lhomme
robux4 at ycbcr.xyz
Tue Nov 20 16:42:36 CET 2018
And rename the internal variable to "vout-cb-update-output"
---
include/vlc/libvlc_media_player.h | 6 +++---
lib/media_player.c | 6 +++---
modules/video_output/vgl.c | 2 +-
3 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/include/vlc/libvlc_media_player.h b/include/vlc/libvlc_media_player.h
index 987fd40c9d..72d3b787ad 100644
--- a/include/vlc/libvlc_media_player.h
+++ b/include/vlc/libvlc_media_player.h
@@ -449,7 +449,7 @@ typedef void (*libvlc_gl_cleanup_cb)(void* opaque);
* \return true on success
* \version LibVLC 4.0.0 or later
*/
-typedef bool (*libvlc_gl_resize_cb)(void* opaque, unsigned width, unsigned height);
+typedef bool (*libvlc_update_output_cb)(void* opaque, unsigned width, unsigned height);
/**
@@ -501,7 +501,7 @@ typedef enum libvlc_gl_engine_t {
* \param gl_engine the OpenGL engine to use
* \param setup_cb callback called to initialize user data
* \param cleanup_cb callback called to clean up user data
- * \param resize_cb callback called to get the size of the video
+ * \param update_output_cb callback called to get the size of the video
* \param swap_cb callback called after rendering a video frame (cannot be NULL)
* \param makeCurrent_cb callback called to enter/leave the opengl context (cannot be NULL)
* \param getProcAddress_cb opengl function loading callback (cannot be NULL)
@@ -513,7 +513,7 @@ void libvlc_video_set_opengl_callbacks( libvlc_media_player_t *mp,
libvlc_gl_engine_t gl_engine,
libvlc_gl_setup_cb setup_cb,
libvlc_gl_cleanup_cb cleanup_cb,
- libvlc_gl_resize_cb resize_cb,
+ libvlc_update_output_cb update_output_cb,
libvlc_gl_swap_cb swap_cb,
libvlc_gl_makeCurrent_cb makeCurrent_cb,
libvlc_gl_getProcAddress_cb getProcAddress_cb,
diff --git a/lib/media_player.c b/lib/media_player.c
index 9cb826934a..831a17f9f8 100644
--- a/lib/media_player.c
+++ b/lib/media_player.c
@@ -642,7 +642,7 @@ libvlc_media_player_new( libvlc_instance_t *instance )
var_Create( mp, "vgl-opaque", VLC_VAR_ADDRESS );
var_Create( mp, "vgl-setup-cb", VLC_VAR_ADDRESS );
var_Create( mp, "vgl-cleanup-cb", VLC_VAR_ADDRESS );
- var_Create( mp, "vgl-resize-cb", VLC_VAR_ADDRESS );
+ var_Create( mp, "vout-cb-update-output", VLC_VAR_ADDRESS );
var_Create( mp, "vgl-swap-cb", VLC_VAR_ADDRESS );
var_Create( mp, "vgl-get-proc-address-cb", VLC_VAR_ADDRESS );
var_Create( mp, "vgl-make-current-cb", VLC_VAR_ADDRESS );
@@ -1164,7 +1164,7 @@ void libvlc_video_set_opengl_callbacks( libvlc_media_player_t *mp,
libvlc_gl_engine_t gl_engine,
libvlc_gl_setup_cb setup_cb,
libvlc_gl_cleanup_cb cleanup_cb,
- libvlc_gl_resize_cb resize_cb,
+ libvlc_update_output_cb update_output_cb,
libvlc_gl_swap_cb swap_cb,
libvlc_gl_makeCurrent_cb makeCurrent_cb,
libvlc_gl_getProcAddress_cb getProcAddress_cb,
@@ -1191,7 +1191,7 @@ void libvlc_video_set_opengl_callbacks( libvlc_media_player_t *mp,
var_SetAddress( mp, "vgl-opaque", opaque );
var_SetAddress( mp, "vgl-setup-cb", setup_cb );
var_SetAddress( mp, "vgl-cleanup-cb", cleanup_cb );
- var_SetAddress( mp, "vgl-resize-cb", resize_cb );
+ var_SetAddress( mp, "vout-cb-update-output", update_output_cb );
var_SetAddress( mp, "vgl-swap-cb", swap_cb );
var_SetAddress( mp, "vgl-get-proc-address-cb", getProcAddress_cb );
var_SetAddress( mp, "vgl-make-current-cb", makeCurrent_cb );
diff --git a/modules/video_output/vgl.c b/modules/video_output/vgl.c
index e08ffa2916..023899ec2d 100644
--- a/modules/video_output/vgl.c
+++ b/modules/video_output/vgl.c
@@ -119,7 +119,7 @@ static int Open(vlc_object_t *object)
sys->opaque = var_InheritAddress(gl, "vgl-opaque");
sys->setupCb = var_InheritAddress(gl, "vgl-setup-cb");
sys->cleanupCb = var_InheritAddress(gl, "vgl-cleanup-cb");
- sys->resizeCb = var_InheritAddress(gl, "vgl-resize-cb");
+ sys->resizeCb = var_InheritAddress(gl, "vout-cb-update-output");
SET_CALLBACK_ADDR(sys->swapCb, "vgl-swap-cb");
SET_CALLBACK_ADDR(sys->makeCurrentCb, "vgl-make-current-cb");
SET_CALLBACK_ADDR(sys->getProcAddressCb, "vgl-get-proc-address-cb");
--
2.17.1
More information about the vlc-devel
mailing list