// Default fps
mlt_properties_set_double( this->properties, "fps", 25 );
+ // Default scaler (for now we'll use nearest)
+ mlt_properties_set( this->properties, "rescale", "nearest" );
+
// process actual param
if ( arg == NULL || !strcmp( arg, "PAL" ) )
{
int channels = 2;
int frequency = 48000;
static int counter = 0;
+ if ( mlt_properties_get_int( properties, "frequency" ) != 0 )
+ frequency = mlt_properties_get_int( properties, "frequency" );
+
int samples = mlt_sample_calculator( mlt_properties_get_double( this->properties, "fps" ), frequency, counter++ );
int16_t *pcm;
while ( bytes > ( sizeof( this->audio_buffer) - this->audio_avail ) )
pthread_cond_wait( &this->audio_cond, &this->audio_mutex );
mlt_properties properties = mlt_frame_properties( frame );
- if ( mlt_properties_get_double( properties, "speed" ) == 1 )
+ if ( mlt_properties_get_double( properties, "_speed" ) == 1 )
memcpy( &this->audio_buffer[ this->audio_avail ], pcm, bytes );
else
memset( &this->audio_buffer[ this->audio_avail ], 0, bytes );
}
this->queue[ this->count ++ ] = frame;
+ if ( mlt_properties_get( properties, "rescale" ) != NULL )
+ mlt_properties_set( mlt_frame_properties( frame ), "rescale.interp", mlt_properties_get( properties, "rescale" ) );
+
if ( this->playing )
{
// We're working on the oldest frame now