From 21f8db12c45bd56293262cd4abfb73cd9abec821 Mon Sep 17 00:00:00 2001 From: "Gregory Mullen (grayhatter)" Date: Sun, 11 Sep 2016 16:27:03 -0700 Subject: Make ToxAV stateless --- other/apidsl/tox.in.h | 4 ++++ other/apidsl/toxav.in.h | 12 ++++++------ 2 files changed, 10 insertions(+), 6 deletions(-) (limited to 'other/apidsl') diff --git a/other/apidsl/tox.in.h b/other/apidsl/tox.in.h index e062e41f..d14e48ba 100644 --- a/other/apidsl/tox.in.h +++ b/other/apidsl/tox.in.h @@ -1089,6 +1089,10 @@ namespace friend { * function, this client will appear offline to the friend and no communication * can occur between the two. * + * WARNING, calling ${friend.delete} while there's an active ToxAV call will + * result in undefined behavior. It's the client's responsibility to end all + * ToxAV calls before deleting a friend. + * * @param friend_number Friend number for the friend to be deleted. * * @return true on success. diff --git a/other/apidsl/toxav.in.h b/other/apidsl/toxav.in.h index 8a7d5358..67b670dc 100644 --- a/other/apidsl/toxav.in.h +++ b/other/apidsl/toxav.in.h @@ -216,7 +216,7 @@ const uint32_t iteration_interval(); * toxav_iteration_interval() milliseconds. It is best called in the separate * thread from tox_iterate. */ -void iterate(); +void iterate(any userdata); /******************************************************************************* @@ -269,7 +269,7 @@ bool call(uint32_t friend_number, uint32_t audio_bit_rate, uint32_t video_bit_ra INVALID_BIT_RATE, } -event call { +event call const { /** * The function type for the ${event call} callback. * @@ -359,7 +359,7 @@ bitmask FRIEND_CALL_STATE { ACCEPTING_V, } -event call_state { +event call_state const { /** * The function type for the ${event call_state} callback. * @@ -490,7 +490,7 @@ namespace bit_rate { FRIEND_NOT_IN_CALL, } - event status { + event status const { /** * The function type for the ${event status} callback. The event is triggered * when the network becomes too saturated for current bit rates at which @@ -601,7 +601,7 @@ namespace video { namespace audio { - event receive_frame { + event receive_frame const { /** * The function type for the ${event receive_frame} callback. The callback can be * called multiple times per single iteration depending on the amount of queued @@ -620,7 +620,7 @@ namespace audio { } namespace video { - event receive_frame { + event receive_frame const { /** * The function type for the ${event receive_frame} callback. * -- cgit v1.2.3