Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(toxav): fix docs of toxav.h #2754

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 16 additions & 15 deletions toxav/toxav.h
Original file line number Diff line number Diff line change
Expand Up @@ -246,9 +246,9 @@ typedef enum Toxav_Err_Call {
* receiving are both enabled by default.
*
* @param friend_number The friend number of the friend that should be called.
* @param audio_bit_rate Audio bit rate in Kb/sec. Set this to 0 to disable
* @param audio_bit_rate Audio bit rate in kbit/sec. Set this to 0 to disable
iphydf marked this conversation as resolved.
Show resolved Hide resolved
* audio sending.
* @param video_bit_rate Video bit rate in Kb/sec. Set this to 0 to disable
* @param video_bit_rate Video bit rate in Mbit/sec. Set this to 0 to disable
nurupo marked this conversation as resolved.
Show resolved Hide resolved
* video sending.
*/
bool toxav_call(ToxAV *av, uint32_t friend_number, uint32_t audio_bit_rate, uint32_t video_bit_rate,
Expand Down Expand Up @@ -315,9 +315,9 @@ typedef enum Toxav_Err_Answer {
* enabled by default.
*
* @param friend_number The friend number of the friend that is calling.
* @param audio_bit_rate Audio bit rate in Kb/sec. Set this to 0 to disable
* @param audio_bit_rate Audio bit rate in kbit/sec. Set this to 0 to disable
* audio sending.
* @param video_bit_rate Video bit rate in Kb/sec. Set this to 0 to disable
* @param video_bit_rate Video bit rate in Mbit/sec. Set this to 0 to disable
* video sending.
*/
bool toxav_answer(ToxAV *av, uint32_t friend_number, uint32_t audio_bit_rate, uint32_t video_bit_rate,
Expand Down Expand Up @@ -597,11 +597,11 @@ bool toxav_audio_send_frame(ToxAV *av, uint32_t friend_number, const int16_t pcm
uint8_t channels, uint32_t sampling_rate, Toxav_Err_Send_Frame *error);

/**
* Set the bit rate to be used in subsequent video frames.
* Set the bit rate to be used in subsequent audio frames.
*
* @param friend_number The friend number of the friend for which to set the
* bit rate.
* @param bit_rate The new audio bit rate in Kb/sec. Set to 0 to disable.
* @param bit_rate The new audio bit rate in kbit/sec. Set to 0 to disable.
*
* @return true on success.
*/
Expand All @@ -614,7 +614,7 @@ bool toxav_audio_set_bit_rate(ToxAV *av, uint32_t friend_number, uint32_t bit_ra
*
* @param friend_number The friend number of the friend for which to set the
* bit rate.
* @param audio_bit_rate Suggested maximum audio bit rate in Kb/sec.
* @param audio_bit_rate Suggested maximum audio bit rate in kbit/sec.
*/
typedef void toxav_audio_bit_rate_cb(ToxAV *av, uint32_t friend_number, uint32_t audio_bit_rate, void *user_data);

Expand All @@ -627,9 +627,10 @@ void toxav_callback_audio_bit_rate(ToxAV *av, toxav_audio_bit_rate_cb *callback,
/**
* Send a video frame to a friend.
*
* Y - plane should be of size: `height * width`
* U - plane should be of size: `(height/2) * (width/2)`
* V - plane should be of size: `(height/2) * (width/2)`
* The video frame needs to be planar YUV420.
* Y - plane should be of size: `width * height`
* U - plane should be of size: `(width/2) * (height/2)`
* V - plane should be of size: `(width/2) * (height/2)`
*
* @param friend_number The friend number of the friend to which to send a video
* frame.
Expand All @@ -641,17 +642,17 @@ void toxav_callback_audio_bit_rate(ToxAV *av, toxav_audio_bit_rate_cb *callback,
*/
bool toxav_video_send_frame(
ToxAV *av, uint32_t friend_number, uint16_t width, uint16_t height,
const uint8_t y[/*! height * width */],
const uint8_t u[/*! height/2 * width/2 */],
const uint8_t v[/*! height/2 * width/2 */],
const uint8_t y[/*! width * height */],
const uint8_t u[/*! width/2 * height/2 */],
const uint8_t v[/*! width/2 * height/2 */],
Toxav_Err_Send_Frame *error);

/**
* Set the bit rate to be used in subsequent video frames.
*
* @param friend_number The friend number of the friend for which to set the
* bit rate.
* @param bit_rate The new video bit rate in Kb/sec. Set to 0 to disable.
* @param bit_rate The new video bit rate in Mbit/sec. Set to 0 to disable.
*
* @return true on success.
*/
Expand All @@ -664,7 +665,7 @@ bool toxav_video_set_bit_rate(ToxAV *av, uint32_t friend_number, uint32_t bit_ra
*
* @param friend_number The friend number of the friend for which to set the
* bit rate.
* @param video_bit_rate Suggested maximum video bit rate in Kb/sec.
* @param video_bit_rate Suggested maximum video bit rate in Mbit/sec.
*/
typedef void toxav_video_bit_rate_cb(ToxAV *av, uint32_t friend_number, uint32_t video_bit_rate, void *user_data);

Expand Down
Loading