X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=include%2Fvlc_osd.h;h=d6df9440b0e71929cb494616147f9544b65dbb80;hb=d980183c56ac1c36cb184c7d32cdc74a41eacbd9;hp=baeaf3a81094f5bbe82564e242afc9e9188d3b3a;hpb=cae552ce563d1a880957656615acb23a609698f7;p=vlc diff --git a/include/vlc_osd.h b/include/vlc_osd.h index baeaf3a810..d6df9440b0 100644 --- a/include/vlc_osd.h +++ b/include/vlc_osd.h @@ -51,11 +51,11 @@ extern "C" { * The OSD menu core creates the OSD menu structure in memory. It parses a * configuration file that defines all elements that are part of the menu. The * core also handles all actions and menu structure updates on behalf of video - * subpicture filters. + * subpicture sources. * - * The file modules/video_filters/osdmenu.c implements a subpicture filter that + * The file modules/video_filters/osdmenu.c implements a subpicture source that * specifies the final information on positioning of the current state image. - * A subpicture filter is called each time a video picture has to be rendered, + * A subpicture source is called each time a video picture has to be rendered, * it also gives a start and end date to the subpicture. The subpicture can be * streamed if used inside a transcoding command. For example: * @@ -66,7 +66,7 @@ extern "C" { * An example for local usage of the OSD menu is: * * vlc dvdsimple:///dev/dvd --extraintf rc - * --sub-filter osdmenu + * --sub-source osdmenu * --osdmenu-file=share/osdmenu/dvd.cfg * * Each OSD menu element, called "action", defines a hotkey action. Each action @@ -170,7 +170,6 @@ struct osd_button_t osd_state_t *p_current_state; /*< pointer to current state image */ osd_state_t *p_states; /*< doubly linked list of states */ - picture_t *p_feedback; /*< feedback picture */ char *psz_name; /*< name of button */ @@ -195,7 +194,7 @@ struct osd_button_t * * The images that make up an OSD menu can be created in such away that * they contain all buttons in the same picture, with the selected one - * highlighted or being a concatenation of all the seperate images. The + * highlighted or being a concatenation of all the separate images. The * first case is the default. * * To change the default style the keyword 'style' should be set to 'concat'. @@ -265,7 +264,7 @@ struct osd_menu_t * functions. It creates the osd_menu object and holds a pointer to it * during its lifetime. */ -VLC_EXPORT( osd_menu_t *, osd_MenuCreate, ( vlc_object_t *, const char * ) ); +VLC_API osd_menu_t * osd_MenuCreate( vlc_object_t *, const char * ) VLC_USED; /** * Delete the osd_menu_t object @@ -274,7 +273,7 @@ VLC_EXPORT( osd_menu_t *, osd_MenuCreate, ( vlc_object_t *, const char * ) ); * memory for the osdmenu. After return of this function the pointer to * osd_menu_t* is invalid. */ -VLC_EXPORT( void, osd_MenuDelete, ( vlc_object_t *, osd_menu_t * ) ); +VLC_API void osd_MenuDelete( vlc_object_t *, osd_menu_t * ); #define osd_MenuCreate(object,file) osd_MenuCreate( VLC_OBJECT(object), file ) #define osd_MenuDelete(object,osd) osd_MenuDelete( VLC_OBJECT(object), osd ) @@ -282,15 +281,15 @@ VLC_EXPORT( void, osd_MenuDelete, ( vlc_object_t *, osd_menu_t * ) ); /** * Find OSD Menu button at position x,y */ -VLC_EXPORT( osd_button_t *, osd_ButtonFind, ( vlc_object_t *p_this, - int, int, int, int, int, int ) ); +VLC_API osd_button_t *osd_ButtonFind( vlc_object_t *p_this, + int, int, int, int, int, int ) VLC_USED; #define osd_ButtonFind(object,x,y,h,w,sh,sw) osd_ButtonFind(object,x,y,h,w,sh,sw) /** * Select the button provided as the new active button */ -VLC_EXPORT( void, osd_ButtonSelect, ( vlc_object_t *, osd_button_t *) ); +VLC_API void osd_ButtonSelect( vlc_object_t *, osd_button_t *); #define osd_ButtonSelect(object,button) osd_ButtonSelect(object,button) @@ -301,14 +300,14 @@ VLC_EXPORT( void, osd_ButtonSelect, ( vlc_object_t *, osd_button_t *) ); * Every change to the OSD menu will now be visible in the output. An output * can be a video output window or a stream (\see stream output) */ -VLC_EXPORT( void, osd_MenuShow, ( vlc_object_t * ) ); +VLC_API void osd_MenuShow( vlc_object_t * ); /** * Hide the OSD menu. * * Stop showing the OSD menu on the video output or mux it into the stream. */ -VLC_EXPORT( void, osd_MenuHide, ( vlc_object_t * ) ); +VLC_API void osd_MenuHide( vlc_object_t * ); /** * Activate the action of this OSD menu item. @@ -317,7 +316,7 @@ VLC_EXPORT( void, osd_MenuHide, ( vlc_object_t * ) ); * hotkey action to the hotkey interface. The hotkey that belongs to * the current highlighted OSD menu item will be used. */ -VLC_EXPORT( void, osd_MenuActivate, ( vlc_object_t * ) ); +VLC_API void osd_MenuActivate( vlc_object_t * ); #define osd_MenuShow(object) osd_MenuShow( VLC_OBJECT(object) ) #define osd_MenuHide(object) osd_MenuHide( VLC_OBJECT(object) ) @@ -330,7 +329,7 @@ VLC_EXPORT( void, osd_MenuActivate, ( vlc_object_t * ) ); * Note: The actual position on screen of the menu item is determined by * the OSD menu configuration file. */ -VLC_EXPORT( void, osd_MenuNext, ( vlc_object_t * ) ); +VLC_API void osd_MenuNext( vlc_object_t * ); /** * Previous OSD menu item @@ -339,7 +338,7 @@ VLC_EXPORT( void, osd_MenuNext, ( vlc_object_t * ) ); * Note: The actual position on screen of the menu item is determined by * the OSD menu configuration file. */ -VLC_EXPORT( void, osd_MenuPrev, ( vlc_object_t * ) ); +VLC_API void osd_MenuPrev( vlc_object_t * ); /** * OSD menu item above @@ -348,7 +347,7 @@ VLC_EXPORT( void, osd_MenuPrev, ( vlc_object_t * ) ); * Note: The actual position on screen of the menu item is determined by * the OSD menu configuration file. */ -VLC_EXPORT( void, osd_MenuUp, ( vlc_object_t * ) ); +VLC_API void osd_MenuUp( vlc_object_t * ); /** * OSD menu item below @@ -357,7 +356,7 @@ VLC_EXPORT( void, osd_MenuUp, ( vlc_object_t * ) ); * Note: The actual position on screen of the menu item is determined by * the OSD menu configuration file. */ -VLC_EXPORT( void, osd_MenuDown, ( vlc_object_t * ) ); +VLC_API void osd_MenuDown( vlc_object_t * ); #define osd_MenuNext(object) osd_MenuNext( VLC_OBJECT(object) ) #define osd_MenuPrev(object) osd_MenuPrev( VLC_OBJECT(object) ) @@ -370,7 +369,7 @@ VLC_EXPORT( void, osd_MenuDown, ( vlc_object_t * ) ); * Display the correct audio volume bitmap that corresponds to the * current Audio Volume setting. */ -VLC_EXPORT( void, osd_Volume, ( vlc_object_t * ) ); +VLC_API void osd_Volume( vlc_object_t * ); #define osd_Volume(object) osd_Volume( VLC_OBJECT(object) ) @@ -378,6 +377,7 @@ VLC_EXPORT( void, osd_Volume, ( vlc_object_t * ) ); * Retrieve a non modifyable pointer to the OSD Menu state * */ +VLC_USED static inline const osd_menu_state_t *osd_GetMenuState( osd_menu_t *p_osd ) { return( p_osd->p_state ); @@ -388,6 +388,7 @@ static inline const osd_menu_state_t *osd_GetMenuState( osd_menu_t *p_osd ) * * Returns 0 when no key has been pressed or the value of the key pressed. */ +VLC_USED static inline bool osd_GetKeyPressed( osd_menu_t *p_osd ) { return( p_osd->p_state->b_update ); @@ -442,9 +443,9 @@ static inline void osd_SetMenuUpdate( osd_menu_t *p_osd, bool b_value ) * object. The types are declared in the include file include/vlc_osd.h * @see vlc_osd.h */ -VLC_EXPORT( int, osd_ShowTextRelative, ( spu_t *, int, const char *, const text_style_t *, int, int, int, mtime_t ) ); -VLC_EXPORT( int, osd_ShowTextAbsolute, ( spu_t *, int, const char *, const text_style_t *, int, int, int, mtime_t, mtime_t ) ); -VLC_EXPORT( void, osd_Message, ( spu_t *, int, char *, ... ) LIBVLC_FORMAT( 3, 4 ) ); +VLC_API int osd_ShowTextRelative( spu_t *, int, const char *, const text_style_t *, int, int, int, mtime_t ); +VLC_API int osd_ShowTextAbsolute( spu_t *, int, const char *, const text_style_t *, int, int, int, mtime_t, mtime_t ); +VLC_API void osd_Message( spu_t *, int, char *, ... ) VLC_FORMAT( 3, 4 ); /** @} */