groupchat_enable_av


Description:

[ Version ( since = "0.2.10" ) ]
public static int groupchat_enable_av (Tox tox, uint32 groupnumber, GroupchatAudioReceiveFrameCallback callback)

Enable A/V in a groupchat.

A/V must be enabled on a groupchat for audio to be sent to it and for received audio to be handled.

An A/V group created with toxav_add_av_groupchat or toxav_join_av_groupchat will start with A/V enabled.

An A/V group loaded from a savefile will start with A/V disabled.

Audio data callback format (same as the one for toxav_add_av_groupchat()): audio_callback(Tox *tox, uint32_t groupnumber, uint32_t peernumber, const int16_t *pcm, unsigned int samples, uint8_t channels, uint32_t sample_rate, void *userdata)

Note that total size of pcm in bytes is equal to (samples * channels * sizeof(int16_t)).

Returns:

0 on success.

-1 on failure.