audio_format: allow up to 8 channels

audio_valid_sample_format() verifies the number of channels.  Let's
just say up to 8 channels is allowed (which is possible with some
consumer sound chips).  I don't know if there are bigger cards, and
since I cannot test it, I'll limit it to 8 for now.
This commit is contained in:
Max Kellermann 2009-03-02 15:43:45 +01:00
parent a1561252d0
commit 8c0bce0b94

View File

@ -68,7 +68,7 @@ audio_valid_sample_format(unsigned bits)
static inline bool
audio_valid_channel_count(unsigned channels)
{
return channels == 1 || channels == 2;
return channels >= 1 && channels <= 8;
}
/**