mirror of
https://github.com/irungentoo/toxcore.git
synced 2024-03-22 13:30:51 +08:00
Enable use of lower sample rates for group chats.
This commit is contained in:
parent
6bbb939855
commit
49f4583bc1
|
@ -496,8 +496,7 @@ int group_send_audio(Group_Chats *g_c, int groupnumber, const int16_t *pcm, unsi
|
|||
if (channels != 1 && channels != 2)
|
||||
return -1;
|
||||
|
||||
//TODO: allow different sample rates
|
||||
if (sample_rate != 48000)
|
||||
if (sample_rate != 8000 && sample_rate != 12000 && sample_rate != 16000 && sample_rate != 24000 && sample_rate != 48000)
|
||||
return -1;
|
||||
|
||||
if (!group_av->audio_encoder || group_av->audio_channels != channels || group_av->audio_sample_rate != sample_rate) {
|
||||
|
|
|
@ -421,8 +421,6 @@ int toxav_join_av_groupchat(Tox *tox, int32_t friendnumber, const uint8_t *data,
|
|||
* Valid sample rates are 8000, 12000, 16000, 24000, or 48000.
|
||||
*
|
||||
* Recommended values are: samples = 960, channels = 1, sample_rate = 48000
|
||||
*
|
||||
* TODO: currently the only supported sample rate is 48000.
|
||||
*/
|
||||
int toxav_group_send_audio(Tox *tox, int groupnumber, const int16_t *pcm, unsigned int samples, uint8_t channels,
|
||||
unsigned int sample_rate);
|
||||
|
|
Loading…
Reference in New Issue
Block a user