]> git.sesse.net Git - vlc/blobdiff - modules/access/jack.c
Assume liba52 is built as fixed-point if needed
[vlc] / modules / access / jack.c
index f40340ee8c87417bd3a6a8c4141d736ee84cf296..0ff2a818341380e8c34839f796786927c7da8161 100644 (file)
@@ -41,7 +41,6 @@
 #include <vlc_plugin.h>
 #include <vlc_input.h>
 #include <vlc_demux.h>
-#include <vlc_vout.h>
 #include <vlc_codecs.h>
 #include <vlc_url.h>
 #include <vlc_strings.h>
@@ -78,11 +77,11 @@ vlc_module_begin ()
      set_subcategory( SUBCAT_INPUT_ACCESS )
 
      add_integer( "jack-input-caching", DEFAULT_PTS_DELAY / 1000, NULL,
-         CACHING_TEXT, CACHING_LONGTEXT, true );
+         CACHING_TEXT, CACHING_LONGTEXT, true )
      add_bool( "jack-input-use-vlc-pace", false, NULL,
-         PACE_TEXT, PACE_LONGTEXT, true );
+         PACE_TEXT, PACE_LONGTEXT, true )
      add_bool( "jack-input-auto-connect", false, NULL,
-         AUTO_CONNECT_TEXT, AUTO_CONNECT_LONGTEXT, true );
+         AUTO_CONNECT_TEXT, AUTO_CONNECT_LONGTEXT, true )
 
      add_shortcut( "jack" )
      set_callbacks( Open, Close )
@@ -142,9 +141,8 @@ static int Open( vlc_object_t *p_this )
 
     /* Allocate structure */
     p_demux->p_sys = p_sys = calloc( 1, sizeof( demux_sys_t ) );
-    if( p_sys == NULL )
+    if( !p_sys )
         return VLC_ENOMEM;
-    memset( p_sys, 0, sizeof( demux_sys_t ) );
 
     /* Parse MRL */
     Parse( p_demux );
@@ -306,7 +304,7 @@ static int Open( vlc_object_t *p_this )
     p_sys->jack_sample_size = sizeof( jack_default_audio_sample_t );
 
     /* Define output format */
-    es_format_Init( &fmt, AUDIO_ES, VLC_FOURCC( 'f','l','3','2' ) );
+    es_format_Init( &fmt, AUDIO_ES, VLC_CODEC_FL32 );
     fmt.audio.i_channels =  p_sys->i_channels;
     fmt.audio.i_rate =  p_sys->jack_sample_rate;
     fmt.audio.i_bitspersample =  p_sys->jack_sample_size * 8;
@@ -464,6 +462,8 @@ static block_t *GrabJack( demux_t *p_demux )
 
     if( i_read < 100 ) /* avoid small read */
     {   /* vlc has too much free time on its hands? */
+#undef msleep
+#warning Hmm.... looks wrong
         msleep(1000);
         return NULL;
     }