[MPlayer-dev-eng] [PATCH] ao_dart

KO Myung-Hun komh at chollian.net
Wed Feb 25 19:29:53 CET 2009


Hi/2.

Reimar Döffinger wrote:
> On Tue, Feb 24, 2009 at 12:15:16AM +0900, KO Myung-Hun wrote:
>   
>> +#define OUTBURST_SAMPLES    512
>> +#define DART_SAMPLES        (OUTBURST_SAMPLES << 2)
>> +
>> +#define CHUNK_SIZE  ao_data.outburst
>>     
>
>
>   
>> +    // one more chunk, nBytesPerSample * OUTBURST_SAMPLES
>> +    m_nBufSize = nBytesPerSample * ((nDartSamples << 2) + OUTBURST_SAMPLES);
>>     
>
>
>   
>> +    ao_data.outburst    = nBytesPerSample * OUTBURST_SAMPLES;
>>     
>
> This is rather confusing. Make sure that m_nBufSize is always a multiple
> of CHUNK_SIZE, otherwise you risk getting really, really bad performance
> (because the buffer write position is not aligned, even writes of a
> single chunk will have to be split in two at the end of the FIFO etc. -
> I don't know how to reproduce it anymore, but for ao_sdl the speed
> difference was significant).
>   

Ok. I think I fixed.

And modified uninit() and dart_audio_callback() to wait for DART to be 
stopped.

-- 
KO Myung-Hun

Using Mozilla SeaMonkey 1.1.14
Under OS/2 Warp 4 for Korean with FixPak #15
On AMD ThunderBird 1 GHz with 512 MB RAM

Korean OS/2 User Community : http://www.ecomstation.co.kr


-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: dart.diff
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20090226/65398a1f/attachment.asc>


More information about the MPlayer-dev-eng mailing list