Move frame count calculations for fast tracks

For fast tracks: move the default and minimum frame count calculations
from client to server.  If accepted, the default and minimum frame count
is the fast mixer (HAL) frame count.  If denied, the default and minimum
frame count is the same as it currently is for normal tracks.

For normal tracks: there is no change yet, preserve legacy behavior for
now but add a FIXME to change this later.

Bug fix: the test for buffer alignment matches channelCount was wrong.

Bug fix: check for 8-bit data in shared memory, which isn't supported.

Optimizations:
 - in set(), only call AudioSystem::getOutputSamplingRate() when needed
 - in createTrack_l(), only call AudioSystem::getSamplingRate() and
   AudioSystem::getFrameCount() when needed

Change-Id: I79d2fe507db1a8f7bb094c71da8a129951dbb82f
2 files changed