The Apple TV apparently checks for (1) an AC3 track and (2) optical port or HDMI signal (e.g., from a receiver). If both are true, then the AC3 track is activated. If not, then the AAC track remains activated (which is the default). I sure wish Quicktime for the Mac could do this, but it doesn't.
If you're referring to alternative audio tracks that often accompany DVDs, then I don't know how you'd handle that.