Allegro 5 api
#include <allegro5/allegro_audio.h> size_t al_get_channel_count(ALLEGRO_CHANNEL_CONF conf)
Return the number of channels for the given channel configuration, which is one of the values listed under ALLEGRO_CHANNEL_CONF(3alleg5).