Page 1 of 1
TStockAudioPlayer not responding to onlevel event

Posted:
February 9th, 2012, 3:59 pm
by mtocon
Hi, I have been confronted by adpcm files which are only 4 bit. They do not make the TStockAudioPlayer onlevel event activate when they are played. I am using an example like the simple wave audio player in the Delphi demos where the onlevel event increments the position of the progress bar. The files play just fine and are audible.
Is there a way to make the player more sensitive so that it will respond to the weaker files? Or is there a way to increment the progress bar without using the onlevel event?
Many thanks
Mick
Re: TStockAudioPlayer not responding to onlevel event

Posted:
February 12th, 2012, 6:01 pm
by Kambiz
Hi Mick,
Figuring audio level for 16 and 8 bits PCM format was very easy, it is way the other formats are not supported.
There is a function in waUtils that you can extend it for supporting other wave formats. I don't remember the exact name of the function, but by looking the source, it would be easy to find it out.
Re: TStockAudioPlayer not responding to onlevel event

Posted:
February 13th, 2012, 12:01 pm
by mtocon
Thanks Kambiz, when you say easy, I think you mean with your level of knowledge and not with mine. It still looks like a massive minefield of despair to me, could you give me a couple of pointers?
Mick
Re: TStockAudioPlayer not responding to onlevel event

Posted:
February 15th, 2012, 10:32 am
by Kambiz
I meant finding audio level for 8 and 16 bit PCM is easy. I have no idea about the 4 bit format.