[vlc-devel] [PATCH 07/18] libvlc: merge direct3d_update_output_cb update into update_output_cb
Steve Lhomme
robux4 at ycbcr.xyz
Tue Feb 4 16:26:02 CET 2020
There are doing the same thing.
---
include/vlc/libvlc_media_player.h | 35 +++++++++----------------
lib/media_player.c | 2 +-
modules/video_output/win32/direct3d11.c | 2 +-
modules/video_output/win32/direct3d9.c | 2 +-
4 files changed, 16 insertions(+), 25 deletions(-)
diff --git a/include/vlc/libvlc_media_player.h b/include/vlc/libvlc_media_player.h
index 5ab62c5953c..89010bb70ad 100644
--- a/include/vlc/libvlc_media_player.h
+++ b/include/vlc/libvlc_media_player.h
@@ -546,12 +546,22 @@ typedef struct
} libvlc_video_output_cfg_t;
/**
- * Callback prototype called on video size changes
+ * Callback prototype called on video size changes.
+ * Update the rendering output setup.
*
- * \param opaque private pointer passed to the @a libvlc_video_set_output_callbacks() [IN]
+ * \param opaque private pointer passed to the @a libvlc_video_set_output_callbacks() or
+ * @a libvlc_video_direct3d_device_setup_cb() [IN]
* \param cfg configuration of the video that will be rendered [IN]
* \param output configuration describing with how the rendering is setup [OUT]
* \version LibVLC 4.0.0 or later
+ *
+ * \note the configuration device for Direct3D9 is the IDirect3DDevice9 that VLC
+ * uses to render. The host must set a Render target and call Present()
+ * when it needs the drawing from VLC to be done. This object is not valid
+ * anymore after Cleanup is called.
+ *
+ * Tone mapping, range and color conversion will be done depending on the values
+ * set in the output structure.
*/
typedef bool (*libvlc_video_update_output_cb)(void* opaque, const libvlc_video_render_cfg_t *cfg,
libvlc_video_output_cfg_t *output );
@@ -727,25 +737,6 @@ typedef void( *libvlc_video_direct3d_set_resize_cb )( void *opaque,
void (*report_size_change)(void *report_opaque, unsigned width, unsigned height),
void *report_opaque );
-/** Update the rendering output setup.
- *
- * \param opaque private pointer set on the opaque parameter of @a libvlc_video_direct3d_device_setup_cb() [IN]
- * \param cfg configuration of the video that will be rendered [IN]
- * \param output configuration describing with how the rendering is setup [OUT]
- * \version LibVLC 4.0.0 or later
- *
- * \note the configuration device for Direct3D9 is the IDirect3DDevice9 that VLC
- * uses to render. The host must set a Render target and call Present()
- * when it needs the drawing from VLC to be done. This object is not valid
- * anymore after Cleanup is called.
- *
- * Tone mapping, range and color conversion will be done depending on the values
- * set in the output structure.
- */
-typedef bool( *libvlc_video_direct3d_update_output_cb )( void *opaque,
- const libvlc_video_render_cfg_t *cfg,
- libvlc_video_output_cfg_t *output );
-
/** Tell the host the rendering for the given plane is about to start
*
* \param opaque private pointer set on the opaque parameter of @a libvlc_video_direct3d_device_setup_cb() [IN]
@@ -794,7 +785,7 @@ bool libvlc_video_direct3d_set_callbacks( libvlc_media_player_t *mp,
libvlc_video_direct3d_device_setup_cb setup_cb,
libvlc_video_direct3d_device_cleanup_cb cleanup_cb,
libvlc_video_direct3d_set_resize_cb resize_cb,
- libvlc_video_direct3d_update_output_cb update_output_cb,
+ libvlc_video_update_output_cb update_output_cb,
libvlc_video_swap_cb swap_cb,
libvlc_video_makeCurrent_cb makeCurrent_cb,
libvlc_video_direct3d_select_plane_cb select_plane_cb,
diff --git a/lib/media_player.c b/lib/media_player.c
index e2e52354ce8..d93813f7598 100644
--- a/lib/media_player.c
+++ b/lib/media_player.c
@@ -1077,7 +1077,7 @@ bool libvlc_video_direct3d_set_callbacks(libvlc_media_player_t *mp,
libvlc_video_direct3d_device_setup_cb setup_cb,
libvlc_video_direct3d_device_cleanup_cb cleanup_cb,
libvlc_video_direct3d_set_resize_cb resize_cb,
- libvlc_video_direct3d_update_output_cb update_output_cb,
+ libvlc_video_update_output_cb update_output_cb,
libvlc_video_swap_cb swap_cb,
libvlc_video_makeCurrent_cb makeCurrent_cb,
libvlc_video_direct3d_select_plane_cb select_plane_cb,
diff --git a/modules/video_output/win32/direct3d11.c b/modules/video_output/win32/direct3d11.c
index 8d2583fecb5..0bac728b1e8 100644
--- a/modules/video_output/win32/direct3d11.c
+++ b/modules/video_output/win32/direct3d11.c
@@ -119,7 +119,7 @@ struct vout_display_sys_t
/* outside rendering */
void *outside_opaque;
- libvlc_video_direct3d_update_output_cb updateOutputCb;
+ libvlc_video_update_output_cb updateOutputCb;
libvlc_video_swap_cb swapCb;
libvlc_video_makeCurrent_cb startEndRenderingCb;
libvlc_video_direct3d_select_plane_cb selectPlaneCb;
diff --git a/modules/video_output/win32/direct3d9.c b/modules/video_output/win32/direct3d9.c
index 87e072688f2..eea97deee9c 100644
--- a/modules/video_output/win32/direct3d9.c
+++ b/modules/video_output/win32/direct3d9.c
@@ -171,7 +171,7 @@ struct vout_display_sys_t
/* outside rendering */
void *outside_opaque;
- libvlc_video_direct3d_update_output_cb updateOutputCb;
+ libvlc_video_update_output_cb updateOutputCb;
libvlc_video_swap_cb swapCb;
libvlc_video_makeCurrent_cb startEndRenderingCb;
};
--
2.17.1
More information about the vlc-devel
mailing list