]> git.sesse.net Git - mlt/commitdiff
Fix some compile warnings raised by clang.
authorDan Dennedy <dan@dennedy.org>
Wed, 8 May 2013 05:36:03 +0000 (22:36 -0700)
committerDan Dennedy <dan@dennedy.org>
Wed, 8 May 2013 05:36:03 +0000 (22:36 -0700)
src/modules/core/producer_melt.c
src/modules/rtaudio/RtAudio.cpp
src/modules/xine/deinterlace.c
src/modules/xml/producer_xml.c

index b3ba3a14710da58d331c44987c3c700d1584097d..afc8e4c22bcd06f878494d50a036d22449235e2f 100644 (file)
@@ -463,8 +463,8 @@ mlt_producer producer_melt_init( mlt_profile profile, mlt_service_type type, con
        track_service( field, playlist, ( mlt_destructor )mlt_playlist_close );
 
        // We must have a playlist to connect
-       if ( playlist && !mlt_properties_get_int( MLT_PLAYLIST_PROPERTIES( playlist ), "_melt_first" ) || 
-                 mlt_producer_get_playtime( MLT_PLAYLIST_PRODUCER( playlist ) ) > 0 )
+       if ( ( playlist && !mlt_properties_get_int( MLT_PLAYLIST_PROPERTIES( playlist ), "_melt_first" ) ) ||
+                  mlt_producer_get_playtime( MLT_PLAYLIST_PRODUCER( playlist ) ) > 0 )
                mlt_multitrack_connect( multitrack, MLT_PLAYLIST_PRODUCER( playlist ), track );
 
        mlt_producer prod = MLT_TRACTOR_PRODUCER( tractor );
index 422a78417b5a6eeaa008a37f9939f9fc4adc7ea8..94275e364aa3ab7e6f5e7d54d9265f1e4a9563df 100644 (file)
@@ -1076,7 +1076,7 @@ bool RtApiCore :: probeDeviceOpen( unsigned int device, StreamMode mode, unsigne
 \r
     // We'll try higher bit rates first and then work our way down.\r
     std::vector< std::pair<UInt32, UInt32>  > physicalFormats;\r
-    formatFlags = description.mFormatFlags | kLinearPCMFormatFlagIsFloat & ~kLinearPCMFormatFlagIsSignedInteger;\r
+    formatFlags = (description.mFormatFlags | kLinearPCMFormatFlagIsFloat) & ~kLinearPCMFormatFlagIsSignedInteger;\r
     physicalFormats.push_back( std::pair<Float32, UInt32>( 32, formatFlags ) );\r
     formatFlags = (description.mFormatFlags | kLinearPCMFormatFlagIsSignedInteger | kAudioFormatFlagIsPacked) & ~kLinearPCMFormatFlagIsFloat;\r
     physicalFormats.push_back( std::pair<Float32, UInt32>( 32, formatFlags ) );\r
index 89194abcad2c21e37858ad67c5cf957f4eb64da8..eddbb69132df023def8e183cfd24237d457e824c 100644 (file)
@@ -66,8 +66,8 @@ static void deinterlace_bob_yuv_mmx( uint8_t *pdst, uint8_t *psrc[],
   uint64_t qwEdgeDetect;
   uint64_t qwThreshold;
 
-  static mmx_t YMask = {ub:{0xff,0,0xff,0,0xff,0,0xff,0}};
-  static mmx_t Mask = {ub:{0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe}};
+  static mmx_t YMask = {.ub={0xff,0,0xff,0,0xff,0,0xff,0}};
+  static mmx_t Mask = {.ub={0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe}};
 
   qwEdgeDetect = EdgeDetect;
   qwEdgeDetect += (qwEdgeDetect << 48) + (qwEdgeDetect << 32) + (qwEdgeDetect << 16);
@@ -217,8 +217,8 @@ static int deinterlace_weave_yuv_mmx( uint8_t *pdst, uint8_t *psrc[],
   uint64_t qwTemporalTolerance;
   uint64_t qwThreshold;
 
-  static mmx_t YMask = {ub:{0xff,0,0xff,0,0xff,0,0xff,0}};
-  static mmx_t Mask = {ub:{0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe}};
+  static mmx_t YMask = {.ub={0xff,0,0xff,0,0xff,0,0xff,0}};
+  static mmx_t Mask = {.ub={0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe}};
 
 
   // Make sure we have all the data we need.
@@ -402,7 +402,7 @@ static int deinterlace_greedy_yuv_mmx( uint8_t *pdst, uint8_t *psrc[],
   uint8_t* pOddLines = psrc[0]+width;
   uint8_t* pPrevLines;
 
-  static mmx_t ShiftMask = {ub:{0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe}};
+  static mmx_t ShiftMask = {.ub={0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe}};
 
   int LineLength = width;
   int SourcePitch = width * 2;
@@ -566,7 +566,7 @@ static void deinterlace_onefield_yuv_mmx( uint8_t *pdst, uint8_t *psrc[],
 
   int n;
 
-  static mmx_t Mask = {ub:{0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe}};
+  static mmx_t Mask = {.ub={0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe,0xfe}};
 
   /*
    * copy first even line no matter what, and the first odd line if we're
index af82e45506351bf32822231f2257fc5dca0ddbc5..526e95c9df085edc553aa9f9d681c15538c7df2c 100644 (file)
@@ -154,7 +154,7 @@ static mlt_service context_pop_service( deserialise_context context, enum servic
 {
        mlt_service result = NULL;
        
-       if ( type ) *type = invalid_type;
+       if ( type ) *type = mlt_invalid_type;
        if ( context->stack_service_size > 0 )
        {
                result = context->stack_service[ -- context->stack_service_size ];
@@ -731,7 +731,7 @@ static void on_start_entry( deserialise_context context, const xmlChar *name, co
        if ( mlt_properties_get_data( temp, "producer", NULL ) != NULL )
        {
                mlt_playlist_clip_info info;
-               enum service_type parent_type = invalid_type;
+               enum service_type parent_type = mlt_invalid_type;
                mlt_service parent = context_pop_service( context, &parent_type );
                mlt_producer producer = mlt_properties_get_data( temp, "producer", NULL );
 
@@ -774,7 +774,7 @@ static void on_start_entry( deserialise_context context, const xmlChar *name, co
 static void on_end_entry( deserialise_context context, const xmlChar *name )
 {
        // Get the entry from the stack
-       enum service_type entry_type = invalid_type;
+       enum service_type entry_type = mlt_invalid_type;
        mlt_service entry = context_pop_service( context, &entry_type );
 
        if ( entry == NULL && entry_type != mlt_entry_type )
@@ -817,7 +817,7 @@ static void on_end_track( deserialise_context context, const xmlChar *name )
        if ( track != NULL && track_type == mlt_entry_type )
        {
                mlt_properties track_props = MLT_SERVICE_PROPERTIES( track );
-               enum service_type parent_type = invalid_type;
+               enum service_type parent_type = mlt_invalid_type;
                mlt_service parent = context_pop_service( context, &parent_type );
                mlt_multitrack multitrack = NULL;
 
@@ -903,7 +903,7 @@ static void on_end_filter( deserialise_context context, const xmlChar *name )
        mlt_service service = context_pop_service( context, &type );
        mlt_properties properties = MLT_SERVICE_PROPERTIES( service );
 
-       enum service_type parent_type = invalid_type;
+       enum service_type parent_type = mlt_invalid_type;
        mlt_service parent = context_pop_service( context, &parent_type );
 
        if ( service != NULL && type == mlt_dummy_filter_type )
@@ -993,7 +993,7 @@ static void on_end_transition( deserialise_context context, const xmlChar *name
        mlt_service service = context_pop_service( context, &type );
        mlt_properties properties = MLT_SERVICE_PROPERTIES( service );
 
-       enum service_type parent_type = invalid_type;
+       enum service_type parent_type = mlt_invalid_type;
        mlt_service parent = context_pop_service( context, &parent_type );
 
        if ( service != NULL && type == mlt_dummy_transition_type )