Apple has this Technical Q&A QA1534 which talks about how to create .CAF files from .AIF files using "afconvert" utility.
If you searched on the net you can also find lots of info about converting MP3/WAV to CAF files.
However I couldn't find much information about how to reduce the .CAF file size. I think you play around either the bit rate or the sample rate, however that would more or less impact the music/sound quality.
Later I found this discussion about OpenAL file formats in Apple Support Communities which talks about "IMA4" compression - which is something I never heard before.
I did a few simple experiments as below, converting same WAV file to CAF using different sample rate and "LEI16", "IMA4" data format:
afconvert -f caff -d LEI16@44100 -c 1 correct01.wav correct01_44100.caf
afconvert -f caff -d LEI16@128000 -c 1 correct01.wav correct01_128000.caf
afconvert -f caff -d 'ima4' -c 1 correct01.wav correct01_ima4.caf
afconvert -f caff -d 'ima4@44100' -c 1 correct01.wav correct01_ima4_44100.caf
afconvert -f caff -d 'ima4@128000' -c 1 correct01.wav correct01_ima4_128000.caf
The result file size is as below:
With same 44100 sample rate, using IMA4 compression reduced the file size from 313 KB to 86 KB, about 73% smaller! With the 12800 sample rate, the result is also similar. Don't know what's the default sample rate when using "-d 'ima4'", without the parameter, the result file of 19KB is the smallest.
I guess for small, short sound effect files, should be ok with lower sample rate as it dramatically reduced the file size, but for looping or more important music, you might want to play around with the numbers a bit to get the best balance/result.
Hope you find this information helpful. And if you are aware of any better/other compression or whatever method to further reduce file size (hopefully without loosing too much sound quality?) please let me know!!
Thanks for the comment by a reader, I have corrected the mistake in the article.
You can get further info from this link from Ray Wenderlich as below: