From 78de355e24edb893c6614bbde04d9ffb958260fc Mon Sep 17 00:00:00 2001 From: Thomas Guillem Date: Tue, 11 Apr 2017 15:15:26 +0200 Subject: [PATCH 13/15] build: rename exported symbols by module This is quite ugly and temporary. Ideally we should rename symbols in binaries like the Android script do. --- modules/codec/ttml/ttml.c | 2 +- modules/codec/ttml/ttml.h | 4 ++-- modules/demux/avformat/avformat.c | 4 ++-- modules/demux/avformat/avformat.h | 8 ++++---- modules/demux/avformat/demux.c | 16 ++++++++-------- modules/demux/avformat/mux.c | 4 ++-- modules/demux/ttml.c | 6 +++--- modules/video_filter/deinterlace/deinterlace.c | 10 +++++----- modules/video_filter/deinterlace/deinterlace.h | 18 +++++++++--------- 9 files changed, 36 insertions(+), 36 deletions(-) diff --git a/modules/codec/ttml/ttml.c b/modules/codec/ttml/ttml.c index 24b1050d5a..9b0abbbf26 100644 --- a/modules/codec/ttml/ttml.c +++ b/modules/codec/ttml/ttml.c @@ -54,7 +54,7 @@ vlc_module_begin () set_capability( "demux", 3 ) set_category( CAT_INPUT ) set_subcategory( SUBCAT_INPUT_DEMUX ) - set_callbacks( OpenDemux, CloseDemux ) + set_callbacks( OpenDemux__ttml, CloseDemux__ttml ) add_shortcut( "ttml" ) vlc_module_end () diff --git a/modules/codec/ttml/ttml.h b/modules/codec/ttml/ttml.h index 51f41126f9..5781a92a34 100644 --- a/modules/codec/ttml/ttml.h +++ b/modules/codec/ttml/ttml.h @@ -18,8 +18,8 @@ * Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA. *****************************************************************************/ -int OpenDemux( vlc_object_t* p_this ); -void CloseDemux( demux_t* p_demux ); +int OpenDemux__ttml( vlc_object_t* p_this ); +void CloseDemux__ttml( demux_t* p_demux ); int OpenDecoder ( vlc_object_t * ); void CloseDecoder ( vlc_object_t * ); diff --git a/modules/demux/avformat/avformat.c b/modules/demux/avformat/avformat.c index 28c5a7df76..29cd5b144f 100644 --- a/modules/demux/avformat/avformat.c +++ b/modules/demux/avformat/avformat.c @@ -41,7 +41,7 @@ vlc_module_begin () set_description( N_("Avformat demuxer" ) ) set_shortname( N_("Avformat") ) set_capability( "demux", 2 ) - set_callbacks( OpenDemux, CloseDemux ) + set_callbacks( OpenDemux__avformat, CloseDemux__avformat ) set_section( N_("Demuxer"), NULL ) add_string( "avformat-format", NULL, FORMAT_TEXT, FORMAT_LONGTEXT, true ) add_obsolete_string("ffmpeg-format") /* removed since 2.1.0 */ @@ -57,7 +57,7 @@ vlc_module_begin () add_string( "sout-avformat-mux", NULL, MUX_TEXT, MUX_LONGTEXT, true ) add_obsolete_string("ffmpeg-mux") /* removed since 2.1.0 */ add_string( "sout-avformat-options", NULL, AV_OPTIONS_TEXT, AV_OPTIONS_LONGTEXT, true ) - set_callbacks( OpenMux, CloseMux ) + set_callbacks( OpenMux__avformat, CloseMux__avformat ) #endif #ifndef MERGE_FFMPEG vlc_module_end () diff --git a/modules/demux/avformat/avformat.h b/modules/demux/avformat/avformat.h index 5105dd1efd..7c97fc842a 100644 --- a/modules/demux/avformat/avformat.h +++ b/modules/demux/avformat/avformat.h @@ -25,12 +25,12 @@ void LibavcodecCallback( void *p_opaque, int i_level, const char *psz_format, va_list va ); /* Demux module */ -int OpenDemux ( vlc_object_t * ); -void CloseDemux( vlc_object_t * ); +int OpenDemux__avformat ( vlc_object_t * ); +void CloseDemux__avformat( vlc_object_t * ); /* Mux module */ -int OpenMux ( vlc_object_t * ); -void CloseMux( vlc_object_t * ); +int OpenMux__avformat ( vlc_object_t * ); +void CloseMux__avformat( vlc_object_t * ); #define MUX_TEXT N_("Avformat mux") #define MUX_LONGTEXT N_("Force use of a specific avformat muxer.") diff --git a/modules/demux/avformat/demux.c b/modules/demux/avformat/demux.c index 2f3b907410..7c1a1a5319 100644 --- a/modules/demux/avformat/demux.c +++ b/modules/demux/avformat/demux.c @@ -148,7 +148,7 @@ static void get_rotation(es_format_t *fmt, AVStream *s) } } -int OpenDemux( vlc_object_t *p_this ) +int OpenDemux__avformat( vlc_object_t *p_this ) { demux_t *p_demux = (demux_t*)p_this; demux_sys_t *p_sys; @@ -288,7 +288,7 @@ int OpenDemux( vlc_object_t *p_this ) if( !p_io_buffer ) { free( psz_url ); - CloseDemux( p_this ); + CloseDemux__avformat( p_this ); return VLC_ENOMEM; } @@ -297,7 +297,7 @@ int OpenDemux( vlc_object_t *p_this ) { av_free( p_io_buffer ); free( psz_url ); - CloseDemux( p_this ); + CloseDemux__avformat( p_this ); return VLC_ENOMEM; } @@ -307,7 +307,7 @@ int OpenDemux( vlc_object_t *p_this ) { av_free( p_io_buffer ); free( psz_url ); - CloseDemux( p_this ); + CloseDemux__avformat( p_this ); return VLC_ENOMEM; } @@ -322,7 +322,7 @@ int OpenDemux( vlc_object_t *p_this ) av_free( pb ); p_sys->ic = NULL; free( psz_url ); - CloseDemux( p_this ); + CloseDemux__avformat( p_this ); return VLC_EGENERIC; } free( psz_url ); @@ -357,13 +357,13 @@ int OpenDemux( vlc_object_t *p_this ) if( !nb_streams ) { msg_Err( p_demux, "No streams found"); - CloseDemux( p_this ); + CloseDemux__avformat( p_this ); return VLC_EGENERIC; } p_sys->tracks = calloc( nb_streams, sizeof(*p_sys->tracks) ); if( !p_sys->tracks ) { - CloseDemux( p_this ); + CloseDemux__avformat( p_this ); return VLC_ENOMEM; } @@ -690,7 +690,7 @@ int OpenDemux( vlc_object_t *p_this ) /***************************************************************************** * Close *****************************************************************************/ -void CloseDemux( vlc_object_t *p_this ) +void CloseDemux__avformat( vlc_object_t *p_this ) { demux_t *p_demux = (demux_t*)p_this; demux_sys_t *p_sys = p_demux->p_sys; diff --git a/modules/demux/avformat/mux.c b/modules/demux/avformat/mux.c index 1c01253184..b256f3d2d5 100644 --- a/modules/demux/avformat/mux.c +++ b/modules/demux/avformat/mux.c @@ -84,7 +84,7 @@ static int IOWriteTyped(void *opaque, uint8_t *buf, int buf_size, /***************************************************************************** * Open *****************************************************************************/ -int OpenMux( vlc_object_t *p_this ) +int OpenMux__avformat( vlc_object_t *p_this ) { AVOutputFormat *file_oformat; sout_mux_t *p_mux = (sout_mux_t*)p_this; @@ -163,7 +163,7 @@ int OpenMux( vlc_object_t *p_this ) /***************************************************************************** * Close *****************************************************************************/ -void CloseMux( vlc_object_t *p_this ) +void CloseMux__avformat( vlc_object_t *p_this ) { sout_mux_t *p_mux = (sout_mux_t*)p_this; sout_mux_sys_t *p_sys = p_mux->p_sys; diff --git a/modules/demux/ttml.c b/modules/demux/ttml.c index a22cbb6a79..b4de0dd009 100644 --- a/modules/demux/ttml.c +++ b/modules/demux/ttml.c @@ -391,7 +391,7 @@ static int Demux( demux_t* p_demux ) return VLC_DEMUXER_SUCCESS; } -int OpenDemux( vlc_object_t* p_this ) +int OpenDemux__ttml( vlc_object_t* p_this ) { demux_t *p_demux = (demux_t*)p_this; demux_sys_t *p_sys; @@ -530,12 +530,12 @@ int OpenDemux( vlc_object_t* p_this ) return VLC_SUCCESS; error: - CloseDemux( p_demux ); + CloseDemux__ttml( p_demux ); return VLC_EGENERIC; } -void CloseDemux( demux_t* p_demux ) +void CloseDemux__ttml( demux_t* p_demux ) { demux_sys_t* p_sys = p_demux->p_sys; diff --git a/modules/video_filter/deinterlace/deinterlace.c b/modules/video_filter/deinterlace/deinterlace.c index 1397aed9b8..31103f3631 100644 --- a/modules/video_filter/deinterlace/deinterlace.c +++ b/modules/video_filter/deinterlace/deinterlace.c @@ -113,7 +113,7 @@ vlc_module_begin () change_integer_list( phosphor_dimmer_list, phosphor_dimmer_list_text ) change_safe () add_shortcut( "deinterlace" ) - set_callbacks( Open, Close ) + set_callbacks( Open__deinterlace, Close ) vlc_module_end () /***************************************************************************** @@ -124,7 +124,7 @@ vlc_module_end () * Available config options for the deinterlacer module. * * Note that also algorithm-specific options must be listed here, - * and reading logic for them implemented in Open(). + * and reading logic for them implemented in Open__deinterlace(). */ static const char *const ppsz_filter_options[] = { "mode", "phosphor-chroma", "phosphor-dimmer", @@ -239,7 +239,7 @@ static void GetOutputFormat( filter_t *p_filter, * video filter functions *****************************************************************************/ -/* This is the filter function. See Open(). */ +/* This is the filter function. See Open__deinterlace(). */ picture_t *Deinterlace( filter_t *p_filter, picture_t *p_pic ) { return DoDeinterlacing( p_filter, &p_filter->p_sys->context, p_pic ); @@ -273,10 +273,10 @@ int Mouse( filter_t *p_filter, /***************************************************************************** - * Open + * Open__deinterlace *****************************************************************************/ -int Open( vlc_object_t *p_this ) +int Open__deinterlace( vlc_object_t *p_this ) { filter_t *p_filter = (filter_t*)p_this; filter_sys_t *p_sys; diff --git a/modules/video_filter/deinterlace/deinterlace.h b/modules/video_filter/deinterlace/deinterlace.h index ecc26e0d60..0c71cda6d2 100644 --- a/modules/video_filter/deinterlace/deinterlace.h +++ b/modules/video_filter/deinterlace/deinterlace.h @@ -92,7 +92,7 @@ struct filter_sys_t /** * Top-level filtering method. * - * Open() sets this up as the processing method (pf_video_filter) + * Open__deinterlace() sets this up as the processing method (pf_video_filter) * in the filter structure. * * Note that there is no guarantee that the returned picture directly @@ -126,7 +126,7 @@ struct filter_sys_t * @param p_filter The filter instance. * @param p_pic The latest input picture. * @return Deinterlaced picture(s). Linked list of picture_t's or NULL. - * @see Open() + * @see Open__deinterlace() * @see filter_t * @see filter_sys_t */ @@ -142,7 +142,7 @@ picture_t *Deinterlace( filter_t *p_filter, picture_t *p_pic ); * wants to convert the output to a format different * from the input. See SetFilterMethod(). * - * Open() is atomic: if an error occurs, the state of p_this + * Open__deinterlace() is atomic: if an error occurs, the state of p_this * is left as it was before the call to this function. * * @param p_this The filter instance as vlc_object_t. @@ -153,17 +153,17 @@ picture_t *Deinterlace( filter_t *p_filter, picture_t *p_pic ); * @see IsChromaSupported() * @see SetFilterMethod() */ -int Open( vlc_object_t *p_this ); +int Open__deinterlace( vlc_object_t *p_this ); /** * Resets the filter state, including resetting all algorithm-specific state * and discarding all histories, but does not stop the filter. * - * Open() sets this up as the flush method (pf_flush) + * Open__deinterlace() sets this up as the flush method (pf_flush) * in the filter structure. * * @param p_filter The filter instance. - * @see Open() + * @see Open__deinterlace() * @see filter_t * @see filter_sys_t * @see metadata_history_t @@ -175,7 +175,7 @@ void Flush( filter_t *p_filter ); /** * Mouse callback for the deinterlace filter. * - * Open() sets this up as the mouse callback method (pf_video_mouse) + * Open__deinterlace() sets this up as the mouse callback method (pf_video_mouse) * in the filter structure. * * Currently, this handles the scaling of the y coordinate for algorithms @@ -187,7 +187,7 @@ void Flush( filter_t *p_filter ); * @param[in] p_new Latest mouse position data. * @return VLC error code; currently always VLC_SUCCESS. * @retval VLC_SUCCESS All ok. - * @see Open() + * @see Open__deinterlace() * @see filter_t * @see vlc_mouse_t */ @@ -238,7 +238,7 @@ void Close( vlc_object_t *p_this ); * but the new value will only take effect upon the next call to Deinterlace() * (i.e. at the next incoming frame). * - * The first-ever frame that arrives to the filter after Open() is always + * The first-ever frame that arrives to the filter after Open__deinterlace() is always * handled as having i_frame_offset = 0. For the second and all subsequent * frames, each algorithm is responsible for setting the offset correctly. * (The default is 0, so if that is correct, there's no need to do anything.) -- 2.14.2