ALLEGRO_VOICE *al_create_voice(unsigned int freq,
Introduced in 5.0.0

Creates a voice structure and allocates a voice from the digital sound driver. The passed frequency, sample format and channel configuration are used as a hint to what kind of data will be sent to the voice. However, the underlying sound driver is free to use non-matching values. For example it may be the native format of the sound hardware. If you attach a mixer to the voice, the mixer will convert from the mixer's format to the voice format and you do not have to care about this. If you access the voice directly, make sure to not rely on the parameters passed to this function, but query the returned voice for the actual settings.

See also: al_destroy_voice

Examples: ex_acodec, ex_acodec_multi, ex_kcm_direct, ex_mixer_chain, ex_mixer_pp, ex_stream_file

Most helpful discussions:

Other recent discussions: