]> git.sesse.net Git - vlc/commitdiff
module_need wants pointers and boolean so give NULL and false instead of 0.
authorRémi Duraffort <ivoire@videolan.org>
Sat, 13 Dec 2008 16:05:14 +0000 (17:05 +0100)
committerRémi Duraffort <ivoire@videolan.org>
Sat, 13 Dec 2008 16:05:14 +0000 (17:05 +0100)
28 files changed:
modules/access/screen/screen.c
modules/access/vcdx/demux.c
modules/gui/fbosd.c
modules/gui/macosx/playlistinfo.m
modules/gui/qt4/components/info_panels.cpp
modules/gui/skins2/src/dialogs.cpp
modules/stream_out/mosaic_bridge.c
modules/stream_out/transcode.c
modules/video_filter/blendbench.c
modules/video_filter/logo.c
modules/video_filter/opencv_wrapper.c
modules/video_output/opengl.c
modules/visualization/galaktos/plugin.c
src/audio_output/filters.c
src/audio_output/mixer.c
src/audio_output/output.c
src/input/decoder.c
src/input/demux.c
src/input/input.c
src/input/meta.c
src/input/vlm.c
src/libvlc.c
src/misc/image.c
src/misc/xml.c
src/network/tls.c
src/video_output/video_output.c
src/video_output/vout_intf.c
src/video_output/vout_subpictures.c

index b66a10da5f8eef75a9abc24fda1c2283a3efa68f..3b423a8508c4dfb871a0838e84ecb006de938e3f 100644 (file)
@@ -349,7 +349,7 @@ void RenderCursor( demux_t *p_demux, int i_x, int i_y,
             p_sys->p_blend->fmt_in.video = p_sys->p_mouse->format;
             p_sys->p_blend->fmt_out = p_sys->fmt;
             p_sys->p_blend->p_module =
-                module_need( p_sys->p_blend, "video blending", 0, 0 );
+                module_need( p_sys->p_blend, "video blending", NULL, false );
             if( !p_sys->p_blend->p_module )
             {
                 msg_Err( p_demux, "Could not load video blending module" );
index b89d55b08c84aeb554ac408f3e1ae12cb59d3e43..ada66b3e3bb4ec776f71242e8c73b8b3234f0a84 100644 (file)
@@ -95,7 +95,7 @@ int VCDInit ( vlc_object_t *p_this )
     }
 
     p_input->p_private = (void*)&p_demux->mpeg;
-    p_demux->p_module = module_need( p_input, "mpeg-system", NULL, 0 );
+    p_demux->p_module = module_need( p_input, "mpeg-system", NULL, false );
     if( p_demux->p_module == NULL )
     {
         free( p_input->p_demux_data );
index c91a1f203934fc996c0e218b51df16578a73b025..f64b4b1253f334cbecca2545dc4c598d334ff878 100644 (file)
@@ -547,7 +547,7 @@ static int OpenBlending( intf_thread_t *p_intf )
                 VLC_FOURCC('Y','U','V','A');
 
     p_intf->p_sys->p_blend->p_module =
-        module_need( p_intf->p_sys->p_blend, "video blending", 0, 0 );
+        module_need( p_intf->p_sys->p_blend, "video blending", NULL, false );
 
     if( !p_intf->p_sys->p_blend->p_module )
         return VLC_EGENERIC;
@@ -596,7 +596,7 @@ static int OpenTextRenderer( intf_thread_t *p_intf )
     if( !p_intf->p_sys->p_text->p_module )
     {
         p_intf->p_sys->p_text->p_module =
-            module_need( p_intf->p_sys->p_text, "text renderer", 0, 0 );
+            module_need( p_intf->p_sys->p_text, "text renderer", NULL, false );
     }
     free( psz_modulename );
 
index 1c61ab8438ea63fa162724f6d8db0524254d4909..8822305883cfb6149367d127904f5ac66b7abde1 100644 (file)
@@ -405,7 +405,7 @@ static VLCInfo *_o_sharedInstance = nil;
     PL_LOCK;
     p_playlist->p_private = &p_export;
 
-    module_t *p_mod = module_need( p_playlist, "meta writer", NULL, 0 );
+    module_t *p_mod = module_need( p_playlist, "meta writer", NULL, false );
     if( p_mod )
         module_unneed( p_playlist, p_mod );
     PL_UNLOCK;
index b46e36869dd10a3bba6154f4ad163bc1b6d9f490..664e7d87b0e679b8944e5d73c14125701510f2d3 100644 (file)
@@ -272,7 +272,7 @@ void MetaPanel::saveMeta()
     PL_LOCK;
     p_playlist->p_private = &p_export;
 
-    module_t *p_mod = module_need( p_playlist, "meta writer", NULL, 0 );
+    module_t *p_mod = module_need( p_playlist, "meta writer", NULL, false );
     if( p_mod )
         module_unneed( p_playlist, p_mod );
     PL_UNLOCK;
index f8df188e0f33c4258a4ff7196b14d49b3aab76e8..cbaa7385c3d157806d89b3c9b72216fdaea725de 100644 (file)
@@ -163,7 +163,7 @@ bool Dialogs::init()
     if( m_pProvider == NULL )
         return false;
 
-    m_pModule = module_need( m_pProvider, "dialogs provider", NULL, 0 );
+    m_pModule = module_need( m_pProvider, "dialogs provider", NULL, false );
     if( m_pModule == NULL )
     {
         msg_Err( getIntf(), "no suitable dialogs provider found (hint: compile the qt4 plugin, and make sure it is loaded properly)" );
index 6d18e07d2e3ddf5cc9f42034975b47b62d44a02d..aa11d6a0e3c7e01ab4c9264f260e2f14ab630d9f 100644 (file)
@@ -354,7 +354,7 @@ static sout_stream_id_t * Add( sout_stream_t *p_stream, es_format_t *p_fmt )
     //p_sys->p_decoder->p_cfg = p_sys->p_video_cfg;
 
     p_sys->p_decoder->p_module =
-        module_need( p_sys->p_decoder, "decoder", "$codec", 0 );
+        module_need( p_sys->p_decoder, "decoder", "$codec", false );
 
     if( !p_sys->p_decoder->p_module || !p_sys->p_decoder->pf_decode_video )
     {
index 2b8cbdbf9f92000f365f0c4106798c07d14dfdec..d9846953ba07af97852a4449eef93f642a405479 100644 (file)
@@ -1077,7 +1077,7 @@ static int transcode_audio_new( sout_stream_t *p_stream,
     /* id->p_decoder->p_cfg = p_sys->p_audio_cfg; */
 
     id->p_decoder->p_module =
-        module_need( id->p_decoder, "decoder", "$codec", 0 );
+        module_need( id->p_decoder, "decoder", "$codec", false );
     if( !id->p_decoder->p_module )
     {
         msg_Err( p_stream, "cannot find audio decoder" );
@@ -1467,7 +1467,7 @@ static int transcode_video_new( sout_stream_t *p_stream, sout_stream_id_t *id )
     /* id->p_decoder->p_cfg = p_sys->p_video_cfg; */
 
     id->p_decoder->p_module =
-        module_need( id->p_decoder, "decoder", "$codec", 0 );
+        module_need( id->p_decoder, "decoder", "$codec", false );
 
     if( !id->p_decoder->p_module )
     {
@@ -2279,7 +2279,7 @@ static int transcode_spu_new( sout_stream_t *p_stream, sout_stream_id_t *id )
     /* id->p_decoder->p_cfg = p_sys->p_spu_cfg; */
 
     id->p_decoder->p_module =
-        module_need( id->p_decoder, "decoder", "$codec", 0 );
+        module_need( id->p_decoder, "decoder", "$codec", false );
 
     if( !id->p_decoder->p_module )
     {
index 2e7194c45dbb2bfd4c04227df1df75edd0de6f75..8495221d9ffb929e346cfba22d6098b28690b076 100644 (file)
@@ -228,7 +228,7 @@ static picture_t *Filter( filter_t *p_filter, picture_t *p_pic )
     vlc_object_attach( p_blend, p_filter );
     p_blend->fmt_out.video = p_sys->p_base_image->format;
     p_blend->fmt_in.video = p_sys->p_blend_image->format;
-    p_blend->p_module = module_need( p_blend, "video blending", 0, 0 );
+    p_blend->p_module = module_need( p_blend, "video blending", NULL, false );
     if( !p_blend->p_module )
     {
         picture_Release( p_pic );
index ec42a4b590575eb12989e995e4cb604a4eb44d0d..941ca223e8be487e04d6905277c74bf7662216f4 100644 (file)
@@ -411,7 +411,7 @@ static int Init( vout_thread_t *p_vout )
             p_vout->output.i_height;
 
     p_sys->p_blend->p_module =
-        module_need( p_sys->p_blend, "video blending", 0, 0 );
+        module_need( p_sys->p_blend, "video blending", NULL, false );
     if( !p_sys->p_blend->p_module )
     {
         msg_Err( p_vout, "can't open blending filter, aborting" );
index d3080f6c11e71908f4972759d06d3b180fe626df..b90a86727f5da3330d8a8b35ca0244c38b021848 100644 (file)
@@ -334,7 +334,7 @@ static int Init( vout_thread_t *p_vout )
 
     if (p_vout->p_sys->psz_inner_name)
         p_sys->p_opencv->p_module =
-            module_need( p_sys->p_opencv, p_sys->psz_inner_name, 0, 0 );
+            module_need( p_sys->p_opencv, p_sys->psz_inner_name, NULL, false );
 
     if( !p_sys->p_opencv->p_module )
     {
index a36315057d5b5af4720fd83d3fb894b324d69d95..065069ac2d1d60198cc824ef117f07bca2796c61 100644 (file)
@@ -295,7 +295,7 @@ static int CreateVout( vlc_object_t *p_this )
                       psz ? psz : "default" );
 
     p_sys->p_vout->p_module =
-        module_need( p_sys->p_vout, "opengl provider", psz, 0 );
+        module_need( p_sys->p_vout, "opengl provider", psz, false );
     free( psz );
     if( p_sys->p_vout->p_module == NULL )
     {
index 30b30aab022c992045561387ef3993de486ba0da..94b75a3aa17f339d3f5b4eebbbf72783a6b11fef 100644 (file)
@@ -226,7 +226,7 @@ static void* Thread( vlc_object_t *p_this )
     p_thread->p_opengl->fmt_render = p_thread->p_opengl->fmt_in;
 
     p_thread->p_module =
-        module_need( p_thread->p_opengl, "opengl provider", NULL, 0 );
+        module_need( p_thread->p_opengl, "opengl provider", NULL, false );
     if( p_thread->p_module == NULL )
     {
         msg_Err( p_thread, "unable to initialize OpenGL" );
index 9ffb5f14af0d6a91e33b019068218f15f4b07dc7..4cd202b32d10b3b20d43e0c110e818d1c96ee673 100644 (file)
@@ -58,7 +58,7 @@ static aout_filter_t * FindFilter( aout_instance_t * p_aout,
     memcpy( &p_filter->input, p_input_format, sizeof(audio_sample_format_t) );
     memcpy( &p_filter->output, p_output_format,
             sizeof(audio_sample_format_t) );
-    p_filter->p_module = module_need( p_filter, "audio filter", NULL, 0 );
+    p_filter->p_module = module_need( p_filter, "audio filter", NULL, false );
     if ( p_filter->p_module == NULL )
     {
         vlc_object_detach( p_filter );
index f2c149bb3b0f0dd4afbfabf72019647fa28c63b1..4f1f9b64899a5d0c2989ab2d2a2b14ba09e6d83b 100644 (file)
@@ -43,7 +43,7 @@
  *****************************************************************************/
 int aout_MixerNew( aout_instance_t * p_aout )
 {
-    p_aout->mixer.p_module = module_need( p_aout, "audio mixer", NULL, 0 );
+    p_aout->mixer.p_module = module_need( p_aout, "audio mixer", NULL, false );
     if ( p_aout->mixer.p_module == NULL )
     {
         msg_Err( p_aout, "no suitable audio mixer" );
index 41494d2ae03aa44128434b8a22d52613a73a70cd..0b0ebfa5071636bb13377e61d7746d10c12ec049 100644 (file)
@@ -54,7 +54,7 @@ int aout_OutputNew( aout_instance_t * p_aout,
     aout_lock_output_fifo( p_aout );
 
     /* Find the best output plug-in. */
-    p_aout->output.p_module = module_need( p_aout, "audio output", "$aout", 0);
+    p_aout->output.p_module = module_need( p_aout, "audio output", "$aout", false );
     if ( p_aout->output.p_module == NULL )
     {
         msg_Err( p_aout, "no suitable audio output module" );
index 4b4adf5babfcf902239634e5e37f5dc106a25ca4..789a724cf1c36a5b78e8f170f57358c3e6fb252f 100644 (file)
@@ -755,9 +755,9 @@ static decoder_t * CreateDecoder( input_thread_t *p_input,
 
     /* Find a suitable decoder/packetizer module */
     if( i_object_type == VLC_OBJECT_DECODER )
-        p_dec->p_module = module_need( p_dec, "decoder", "$codec", 0 );
+        p_dec->p_module = module_need( p_dec, "decoder", "$codec", false );
     else
-        p_dec->p_module = module_need( p_dec, "packetizer", "$packetizer", 0 );
+        p_dec->p_module = module_need( p_dec, "packetizer", "$packetizer", false );
 
     /* Check if decoder requires already packetized data */
     if( i_object_type == VLC_OBJECT_DECODER &&
@@ -777,7 +777,7 @@ static decoder_t * CreateDecoder( input_thread_t *p_input,
 
             p_dec->p_owner->p_packetizer->p_module =
                 module_need( p_dec->p_owner->p_packetizer,
-                             "packetizer", "$packetizer", 0 );
+                             "packetizer", "$packetizer", false );
 
             if( !p_dec->p_owner->p_packetizer->p_module )
             {
index be926c8bbaf7c3404cf4cc6752e314d708843f3b..026ad4b2d55d320dd38243d470c69f01cad00398 100644 (file)
@@ -315,7 +315,7 @@ decoder_t *demux_PacketizerNew( demux_t *p_demux, es_format_t *p_fmt, const char
     p_packetizer->fmt_in = *p_fmt;
     es_format_Init( &p_packetizer->fmt_out, UNKNOWN_ES, 0 );
 
-    p_packetizer->p_module = module_need( p_packetizer, "packetizer", NULL, 0 );
+    p_packetizer->p_module = module_need( p_packetizer, "packetizer", NULL, false );
     if( !p_packetizer->p_module )
     {
         es_format_Clean( p_fmt );
index 04069740a10f81f89cab5b5b1354a08642d119a4..8c6d25a6beeeabcb9a705a45e296c5a6a5fa1139 100644 (file)
@@ -2677,7 +2677,7 @@ static void InputSourceMeta( input_thread_t *p_input,
     if( !p_demux_meta )
         return;
 
-    module_t *p_id3 = module_need( p_demux, "meta reader", NULL, 0 );
+    module_t *p_id3 = module_need( p_demux, "meta reader", NULL, false );
     if( p_id3 )
     {
         if( p_demux_meta->p_meta )
index 2123f997c59c3a23174bde1e3c28d2d280a3ea5f..a0863992b3720d0a952e47720fe70b2f1c608187 100644 (file)
@@ -165,7 +165,7 @@ int input_ArtFind( playlist_t *p_playlist, input_item_t *p_item )
     }
     free( psz_title );
 
-    p_module = module_need( p_playlist, "art finder", 0, false );
+    p_module = module_need( p_playlist, "art finder", NULL, false );
 
     if( p_module )
         i_ret = 1;
index e9d53adb3a77355f037b2aa23db447b1fe2405ef..dd249619a437cc3df4dd05bc68b2a79237c47461 100644 (file)
@@ -608,7 +608,7 @@ static int vlm_ControlMediaAdd( vlm_t *p_vlm, vlm_media_t *p_cfg, int64_t *p_id
         p_vlm->p_vod = vlc_custom_create( VLC_OBJECT(p_vlm), sizeof( vod_t ),
                                           VLC_OBJECT_GENERIC, "vod server" );
         vlc_object_attach( p_vlm->p_vod, p_vlm );
-        p_vlm->p_vod->p_module = module_need( p_vlm->p_vod, "vod server", 0, 0 );
+        p_vlm->p_vod->p_module = module_need( p_vlm->p_vod, "vod server", NULL, false );
         if( !p_vlm->p_vod->p_module )
         {
             msg_Err( p_vlm, "cannot find vod server" );
index f085509183143e89062601670ec92be13863aa2d..45fa3a0e5e1a0d08030bce4439d4e5af6793f1d8 100644 (file)
@@ -788,7 +788,7 @@ int libvlc_InternalInit( libvlc_int_t *p_libvlc, int i_argc,
     /*
      * Choose the best memcpy module
      */
-    priv->p_memcpy_module = module_need( p_libvlc, "memcpy", "$memcpy", 0 );
+    priv->p_memcpy_module = module_need( p_libvlc, "memcpy", "$memcpy", false );
 
     priv->b_stats = config_GetInt( p_libvlc, "stats" ) > 0;
     priv->i_timers = 0;
index dc9efc517af8dd363fcee14ba5a4303771a686c2..e50bdc9ed281cf1b2b4828f756db2268e58a6987 100644 (file)
@@ -621,7 +621,7 @@ static decoder_t *CreateDecoder( vlc_object_t *p_this, video_format_t *fmt )
     vlc_object_attach( p_dec, p_this );
 
     /* Find a suitable decoder module */
-    p_dec->p_module = module_need( p_dec, "decoder", "$codec", 0 );
+    p_dec->p_module = module_need( p_dec, "decoder", "$codec", false );
     if( !p_dec->p_module )
     {
         msg_Err( p_dec, "no suitable decoder module for fourcc `%4.4s'.\n"
@@ -703,7 +703,7 @@ static encoder_t *CreateEncoder( vlc_object_t *p_this, video_format_t *fmt_in,
     vlc_object_attach( p_enc, p_this );
 
     /* Find a suitable decoder module */
-    p_enc->p_module = module_need( p_enc, "encoder", 0, 0 );
+    p_enc->p_module = module_need( p_enc, "encoder", NULL, false );
     if( !p_enc->p_module )
     {
         msg_Err( p_enc, "no suitable encoder module for fourcc `%4.4s'.\n"
@@ -752,7 +752,7 @@ static filter_t *CreateFilter( vlc_object_t *p_this, es_format_t *p_fmt_in,
     p_filter->fmt_out.i_codec = p_fmt_out->i_chroma;
     p_filter->fmt_out.video = *p_fmt_out;
     p_filter->p_module = module_need( p_filter, "video filter2",
-                                      psz_module, 0 );
+                                      psz_module, false );
 
     if( !p_filter->p_module )
     {
index ba6b75c3da608f1513b21c608a343eb180879ad9..e5c73ab671f7c7afa8d149c18702e793c05e1755 100644 (file)
@@ -43,7 +43,7 @@ xml_t *__xml_Create( vlc_object_t *p_this )
                                "xml" );
     vlc_object_attach( p_xml, p_this );
 
-    p_xml->p_module = module_need( p_xml, "xml", 0, 0 );
+    p_xml->p_module = module_need( p_xml, "xml", NULL, false );
     if( !p_xml->p_module )
     {
         vlc_object_detach( p_xml );
index 7f81e4772ca189fa8a7c5d3ba54c098796872128..b3ca2fe680caa1909b25ed8d0011d4073f4f0b84 100644 (file)
@@ -69,7 +69,7 @@ tls_ServerCreate (vlc_object_t *obj, const char *cert_path,
         var_SetString (srv, "tls-x509-key", key_path);
     }
 
-    srv->p_module = module_need (srv, "tls server", 0, 0);
+    srv->p_module = module_need (srv, "tls server", NULL, false );
     if (srv->p_module == NULL)
     {
         msg_Err (srv, "TLS server plugin not available");
@@ -185,7 +185,7 @@ tls_ClientCreate (vlc_object_t *obj, int fd, const char *psz_hostname)
     else
         msg_Dbg (cl, "requested anonymous server");
 
-    cl->p_module = module_need (cl, "tls client", 0, 0);
+    cl->p_module = module_need (cl, "tls client", NULL, false );
     if (cl->p_module == NULL)
     {
         msg_Err (cl, "TLS client plugin not available");
index 8d5b2542ea547246786fdd0319e31b2ca287b933..42bfa9003ac86911266c7bb8953e838948794859 100644 (file)
@@ -1450,7 +1450,7 @@ static int ChromaCreate( vout_thread_t *p_vout )
     VideoFormatImportRgb( &p_chroma->fmt_in.video, &p_vout->render );
     VideoFormatImportRgb( &p_chroma->fmt_out.video, &p_vout->output );
 
-    p_chroma->p_module = module_need( p_chroma, "video filter2", NULL, 0 );
+    p_chroma->p_module = module_need( p_chroma, "video filter2", NULL, false );
 
     if( p_chroma->p_module == NULL )
     {
index ccba33e5b17c077e825eba65818ec3a0bdc525dd..7b3e6c6107eedd823b48541a04b91830fa1228bc 100644 (file)
@@ -116,7 +116,7 @@ void *vout_RequestWindow( vout_thread_t *p_vout,
     wnd->pos_y = *pi_y_hint;
     vlc_object_attach (wnd, p_vout);
 
-    wnd->module = module_need (wnd, "vout_window", 0, 0);
+    wnd->module = module_need (wnd, "vout_window", NULL, false);
     if (wnd->module == NULL)
     {
         msg_Dbg (wnd, "no window provider available");
index eab29bcc823b50d85dfb67549295594e29f5b273..d20d4e04543ff3ffbf0337d83cb631ec8fa32bf3 100644 (file)
@@ -949,7 +949,7 @@ static void SpuRenderUpdateBlend( spu_t *p_spu, int i_out_width, int i_out_heigh
 
     /* */
     if( !p_blend->p_module )
-        p_blend->p_module = module_need( p_blend, "video blending", 0, 0 );
+        p_blend->p_module = module_need( p_blend, "video blending", NULL, false );
 }
 static void SpuRenderCreateAndLoadText( spu_t *p_spu )
 {
@@ -1021,7 +1021,7 @@ static filter_t *CreateAndLoadScale( vlc_object_t *p_obj,
     p_scale->pf_vout_buffer_del = spu_del_video_buffer;
 
     vlc_object_attach( p_scale, p_obj );
-    p_scale->p_module = module_need( p_scale, "video filter2", 0, 0 );
+    p_scale->p_module = module_need( p_scale, "video filter2", NULL, false );
 
     return p_scale;
 }