X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fmodules%2Fsdl%2Fconsumer_sdl.c;h=238bf2a7fa1cd38e853fd4e74bd6194a9e481e0c;hb=c287a51b7a4c2cc437256c178a5eb2e7775d34fa;hp=1d1e95965b5631ade68f2661486ea40ab8264ffb;hpb=23571c330fd1644833dcb73661ac987eda177200;p=mlt diff --git a/src/modules/sdl/consumer_sdl.c b/src/modules/sdl/consumer_sdl.c index 1d1e9596..238bf2a7 100644 --- a/src/modules/sdl/consumer_sdl.c +++ b/src/modules/sdl/consumer_sdl.c @@ -103,7 +103,7 @@ mlt_consumer consumer_sdl_init( char *arg ) mlt_properties_set( this->properties, "rescale", "nearest" ); // Default buffer for low latency - mlt_properties_set_int( this->properties, "buffer", 2 ); + mlt_properties_set_int( this->properties, "buffer", 1 ); // Default progressive true mlt_properties_set_int( this->properties, "progressive", 0 ); @@ -246,11 +246,9 @@ static int consumer_play_audio( consumer_sdl this, mlt_frame frame, int init_aud mlt_audio_format afmt = mlt_audio_pcm; // Set the preferred params of the test card signal - int channels = 2; - int frequency = 48000; + int channels = mlt_properties_get_int( properties, "channels" ); + int frequency = mlt_properties_get_int( properties, "frequency" ); 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++ );