From: Laurent Aimar Date: Sun, 31 May 2009 00:00:28 +0000 (+0200) Subject: Added vout_GetSpu to retreive the spu_t object from the vout. X-Git-Tag: 1.1.0-ff~5673 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;h=fd584ea3aea2d53f08ff05b47ea393012531cb85;p=vlc Added vout_GetSpu to retreive the spu_t object from the vout. It will allow hiding vout_thread_t fields. --- diff --git a/include/vlc_vout.h b/include/vlc_vout.h index 4a706fcfd4..0d64ccbefb 100644 --- a/include/vlc_vout.h +++ b/include/vlc_vout.h @@ -310,6 +310,15 @@ VLC_EXPORT( void, vout_LinkPicture, ( vout_thread_t *, picture_t * VLC_EXPORT( void, vout_UnlinkPicture, ( vout_thread_t *, picture_t * ) ); VLC_EXPORT( void, vout_PlacePicture, ( const vout_thread_t *, unsigned int, unsigned int, unsigned int *, unsigned int *, unsigned int *, unsigned int * ) ); +/** + * Return the spu_t object associated to a vout_thread_t. + * + * The return object is valid only as long as the vout is. You must not + * release the spu_t object returned. + * It cannot return NULL so no need to check. + */ +VLC_EXPORT( spu_t *, vout_GetSpu, ( vout_thread_t * ) ); + void vout_IntfInit( vout_thread_t * ); VLC_EXPORT( void, vout_EnableFilter, ( vout_thread_t *, char *,bool , bool ) ); diff --git a/src/libvlccore.sym b/src/libvlccore.sym index 53eaee313e..48f0a321b5 100644 --- a/src/libvlccore.sym +++ b/src/libvlccore.sym @@ -542,6 +542,7 @@ vout_DestroyPicture vout_DisplayPicture vout_EnableFilter vout_GetSnapshot +vout_GetSpu vout_LinkPicture vout_OSDIcon __vout_OSDMessage diff --git a/src/video_output/video_output.c b/src/video_output/video_output.c index 7555d8345c..864ba003b4 100644 --- a/src/video_output/video_output.c +++ b/src/video_output/video_output.c @@ -800,6 +800,11 @@ void vout_DisplayTitle( vout_thread_t *p_vout, const char *psz_title ) vlc_mutex_unlock( &p_vout->change_lock ); } +spu_t *vout_GetSpu( vout_thread_t *p_vout ) +{ + return p_vout->p_spu; +} + /***************************************************************************** * InitThread: initialize video output thread *****************************************************************************