//fprintf( stderr, "mix: frame dest samples %d channels %d position %lld\n", samples_dest, channels_dest, mlt_properties_get_position( mlt_frame_properties( this ), "_position" ) );
mlt_frame_get_audio( that, &src, format, &frequency_src, &channels_src, &samples_src );
//fprintf( stderr, "mix: frame src samples %d channels %d\n", samples_src, channels_src );
-
+
+ int silent = mlt_properties_get_int( mlt_frame_properties( this ), "silent_audio" );
+ mlt_properties_set_int( mlt_frame_properties( this ), "silent_audio", 0 );
+ if ( silent )
+ memset( dest, 0, samples_dest * channels_dest * sizeof( int16_t ) );
+
+ silent = mlt_properties_get_int( mlt_frame_properties( that ), "silent_audio" );
+ mlt_properties_set_int( mlt_frame_properties( that ), "silent_audio", 0 );
+ if ( silent )
+ memset( src, 0, samples_src * channels_src * sizeof( int16_t ) );
+
if ( channels_src > 6 )
channels_src = 0;
if ( channels_dest > 6 )
mlt_properties_set_double( b_props, "audio.reverse", mlt_properties_get_double( properties, "reverse" ) );
}
-
+
+ // Ensure that the tractor knows this isn't test audio...
+ if ( mlt_properties_get_int( mlt_frame_properties( a_frame ), "test_audio" ) )
+ {
+ mlt_properties_set_int( mlt_frame_properties( a_frame ), "test_audio", 0 );
+ mlt_properties_set_int( mlt_frame_properties( a_frame ), "silent_audio", 1 );
+ }
+
// Backup the original get_audio (it's still needed)
mlt_properties_set_data( mlt_frame_properties( a_frame ), "mix.get_audio", a_frame->get_audio, 0, NULL, NULL );