A (175)

(Tuis.) #1

458 CHAPTER 12: Digital Audio: Providing Aural Feedback for UI Designs Using SoundPool


The buttonaudio.m4a file size is 47KB, representing a 21% data footprint reduction. To figure this
out, 47 divided by 219 is 0.2146, which is 21% of the original uncompressed file size. 100% minus
21% equals the 79% file size reduction. Now that we’ve seen that our M4A AAC file size is the most
impressive thus far, let’s see if the more specialized AMR-NB (Narrow Band) data compression
codec will give us any further data footprint improvements over MPEG4 AAC. Even though the
MPEG-4 AMR-NB codec and format was designed and optimized specifically for voice applications,
there may be some other applications, such as certain short-burst sound effects, which might obtain
good if not great results using this codec. Let’s find out!


As you know by now, any codec is simply a complex mathematical equation implemented as
software and does not discriminate, so the only way to really find out what codec will give you the
best result with any given asset is to run the original uncompressed audio data through the codec
and see what happens. Let’s do that next; then we will be finished comparing audio codecs which
are supported in Android, and are also available in Audacity.


Exporting Narrow Band Format: AMR audio files


Follow the usual File ➤ Export work process to invoke the Audacity Export File dialog and select
the AMR (narrow band) Files (FFmpeg) option from the Save as type: drop-down menu selector.
Notice that the files you installed in the beginning of this section of the chapter have been added to
the bottom portion of the menu.


As usual, let’s name the file buttonaudio (which will be named buttonaudio.amr by the Exporter, after
you click on the Save button) in the CH12 directory (or whatever your digital audio assets folder is
called), and then click on the Options button to open the Specify AMR-NB Options dialog, shown
in the middle of Figure 12-13. I chose to use the 12.20 kbps Bit Rate setting to get the maximum
quality result that is possible with this codec.


Figure 12-12. Export an M4A AAC audio file named buttonaudio.m4a using the maximum quality setting of 500

Free download pdf