[FFmpeg-devel] [Brainstorming] sound reproduction with a 3 voice soundchip

Michael Niedermayer michaelni
Mon Feb 28 12:58:20 CET 2011

On Mon, Feb 28, 2011 at 11:42:00AM +0100, Tobias Bindhammer wrote:
> After playing around with video codecs to enable video playback on a
> c64, it would be nice to have also sound for that. There would be some
> options to reproduce sound via the soudnchip, for e.g. by putting 4 bit
> samples at a high rate into the soundchip, however that will cost too
> many cpu cycles needed for video playback. So i did efforts with a FFT
> and waveformdetection upon the transformation. Target was, to make use
> of the three oscillators of the soundchip and just update their base
> parameters a few hundred times per second. The result so far was poor,
> but spoken words could be recognized. I am not too much into audio
> stuff, but maybe some of the audio wizards and gurus can give me some
> hints and ideas on how to get fair results (or completely make me drop
> this, by saying: no chance :-) )

If you dont care about encoding speed, some form of iterative minimization
of the difference seems like an interresting option.
"difference" here can be some sum of squared differences or more advanced
psyco acoustic thing. some FFT ignoring or downweighting phase could be tried

do until no more improvment can be achived
    for each set of parameters that you can optimally choose, do choose it

for example such a set could be frequency+volume+waveformtype
when you choose a frequency+waveform by bruteforce then volume can be
found by correlation.
i dont know what filters are available and how many bits their parameters have
nor if they can be found optimally quickly or require bruteforce. It might
or might not make sense to included them in some bruteforce search or maybe
there are faster ways to find some of these near optimally. Ive not really
thought about it

In the end its alot of trial and error to find the best algorithm i think

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

If you really think that XML is the answer, then you definitly missunderstood
the question -- Attila Kinali
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20110228/12316cbf/attachment.pgp>

More information about the ffmpeg-devel mailing list