## WaveAudio and aiff format

Please post bug reports, feature requests, or any question regarding the DELPHI AREA projects here.

### WaveAudio and aiff format

Hello,

I need to load uncompressed Apple AIFF into TWave. It seems that there are no principal obstacles for this -- both formats are identical and differ by only vendor. Is it possible to have such a feature in your WaveAudio package, or I need a converter?
stfine
Active Member

Posts: 12
Joined: August 1st, 2006, 7:00 am

### Re: WaveAudio and aiff format

Kambiz

Kambiz

Posts: 2428
Joined: March 7th, 2003, 7:10 pm

### Re: WaveAudio and aiff format

Apple AIFF
44100Hz, 16-bit, Stereo
Time 0:0.456
Attachments
Clap.zip
stfine
Active Member

Posts: 12
Joined: August 1st, 2006, 7:00 am

### Re: WaveAudio and aiff format

The sound data of AIFF is apparently similar to WAVE, but format of chunks are different.

An external converter is needed.
Kambiz

Kambiz

Posts: 2428
Joined: March 7th, 2003, 7:10 pm

### Re: WaveAudio and aiff format

It would be veeery convenient to extend your Wave Audio package to handle aiff files too. At least, load them into TWave using, say LoadFromAIFFile().

I found something useful
http://www.koders.com/delphi/fid06EBE95 ... 8FC2F.aspx
stfine
Active Member

Posts: 12
Joined: August 1st, 2006, 7:00 am

### Re: WaveAudio and aiff format

That is a good idea, thanks.

But instead of LoadFromAIFF method, I think it is better to define a converter stream class. Something line ZLib streams of DecompressorStream and CompressorStream.

Code: Select all
Stream := TAIFFReader.Create(AFileName);Wave.LoadFromStream(Stream);Stream.Free;

It's just an idea. Maybe it is not as easy as I think.
Kambiz

Kambiz

Posts: 2428
Joined: March 7th, 2003, 7:10 pm

### Re: WaveAudio and aiff format

I don't understand the purpose of TWaveStreamAdapter, TWaveStreamConverter, etc. What are they for?

Whenever solution you have in mind, I'm eager to assist you and participate, because I really need it.
stfine
Active Member

Posts: 12
Joined: August 1st, 2006, 7:00 am

### Re: WaveAudio and aiff format

TWaveStreamConverter is a TWaveStreamAdapter that allows on the fly conversion of wave files from one format to other.

Did you study the readme file? Also, you can find some information regarding these classes in the forum.

The bad thing is that currently I don't have time to work on AIFF conversion, sorry. I will try to include AIFF support on the next release of the package but I have no idea when it will be done.
Kambiz

Kambiz