summaryrefslogtreecommitdiff
path: root/other/apidsl
diff options
context:
space:
mode:
authoriphydf <iphydf@users.noreply.github.com>2016-09-30 14:52:10 +0100
committeriphydf <iphydf@users.noreply.github.com>2016-10-01 11:17:57 +0100
commit6d2b85ed063aed723267ba1cd621743bd45bd004 (patch)
tree35b28926c2b2cfa90a8c6a16fa219ce271170737 /other/apidsl
parentc037100747a1a224160cb12defb600ddfe1ba927 (diff)
Minor documentation fixes.
- Fixed incorrect parameter names (documented name didn't match code name). - Removed `@return` from functions that return `void`. - Make sure every parameter is documented. This required moving the planes and strides documentation to the function docs.
Diffstat (limited to 'other/apidsl')
-rw-r--r--other/apidsl/tox.in.h50
-rw-r--r--other/apidsl/toxav.in.h29
2 files changed, 39 insertions, 40 deletions
diff --git a/other/apidsl/tox.in.h b/other/apidsl/tox.in.h
index 91cd0eb8..3cad8f4b 100644
--- a/other/apidsl/tox.in.h
+++ b/other/apidsl/tox.in.h
@@ -683,8 +683,8 @@ uint8_t[size] savedata {
683 /** 683 /**
684 * Store all information associated with the tox instance to a byte array. 684 * Store all information associated with the tox instance to a byte array.
685 * 685 *
686 * @param data A memory region large enough to store the tox instance data. 686 * @param savedata A memory region large enough to store the tox instance
687 * Call $size to find the number of bytes required. If this parameter 687 * data. Call $size to find the number of bytes required. If this parameter
688 * is NULL, this function has no effect. 688 * is NULL, this function has no effect.
689 */ 689 */
690 get(); 690 get();
@@ -965,8 +965,8 @@ inline namespace self {
965 * Call $size to find out how much memory to allocate for 965 * Call $size to find out how much memory to allocate for
966 * the result. 966 * the result.
967 * 967 *
968 * @param status A valid memory location large enough to hold the status message. 968 * @param status_message A valid memory location large enough to hold the
969 * If this parameter is NULL, the function has no effect. 969 * status message. If this parameter is NULL, the function has no effect.
970 */ 970 */
971 get(); 971 get();
972 } 972 }
@@ -976,7 +976,7 @@ inline namespace self {
976 /** 976 /**
977 * Set the client's user status. 977 * Set the client's user status.
978 * 978 *
979 * @param user_status One of the user statuses listed in the enumeration above. 979 * @param status One of the user statuses listed in the enumeration above.
980 */ 980 */
981 set(); 981 set();
982 982
@@ -1151,8 +1151,8 @@ inline namespace self {
1151 * 1151 *
1152 * Call $size to determine the number of elements to allocate. 1152 * Call $size to determine the number of elements to allocate.
1153 * 1153 *
1154 * @param list A memory region with enough space to hold the friend list. If 1154 * @param friend_list A memory region with enough space to hold the friend
1155 * this parameter is NULL, this function has no effect. 1155 * list. If this parameter is NULL, this function has no effect.
1156 */ 1156 */
1157 get(); 1157 get();
1158 } 1158 }
@@ -1532,9 +1532,9 @@ namespace friend {
1532 * @param message The message they sent along with the request. 1532 * @param message The message they sent along with the request.
1533 * @param length The size of the message byte array. 1533 * @param length The size of the message byte array.
1534 */ 1534 */
1535 typedef void(const uint8_t[PUBLIC_KEY_SIZE] public_key 1535 typedef void(const uint8_t[PUBLIC_KEY_SIZE] public_key,
1536 //, uint32_t time_delta 1536 // uint32_t time_delta,
1537 , const uint8_t[length <= MAX_MESSAGE_LENGTH] message); 1537 const uint8_t[length <= MAX_MESSAGE_LENGTH] message);
1538 } 1538 }
1539 1539
1540 1540
@@ -1550,9 +1550,9 @@ namespace friend {
1550 * 1550 *
1551 * @see ${event request} for more information on time_delta. 1551 * @see ${event request} for more information on time_delta.
1552 */ 1552 */
1553 typedef void(uint32_t friend_number 1553 typedef void(uint32_t friend_number,
1554 //, uint32_t time_delta 1554 // uint32_t time_delta,
1555 , MESSAGE_TYPE type, 1555 MESSAGE_TYPE type,
1556 const uint8_t[length <= MAX_MESSAGE_LENGTH] message); 1556 const uint8_t[length <= MAX_MESSAGE_LENGTH] message);
1557 } 1557 }
1558 1558
@@ -1752,18 +1752,18 @@ namespace file {
1752 NOT_FOUND, 1752 NOT_FOUND,
1753 } 1753 }
1754 1754
1755 /**
1756 * Copy the file id associated to the file transfer to a byte array.
1757 *
1758 * @param friend_number The friend number of the friend the file is being
1759 * transferred to or received from.
1760 * @param file_number The friend-specific identifier for the file transfer.
1761 * @param file_id A memory region of at least $FILE_ID_LENGTH bytes. If
1762 * this parameter is NULL, this function has no effect.
1763 *
1764 * @return true on success.
1765 */
1766 uint8_t[FILE_ID_LENGTH] file_id { 1755 uint8_t[FILE_ID_LENGTH] file_id {
1756 /**
1757 * Copy the file id associated to the file transfer to a byte array.
1758 *
1759 * @param friend_number The friend number of the friend the file is being
1760 * transferred to or received from.
1761 * @param file_number The friend-specific identifier for the file transfer.
1762 * @param file_id A memory region of at least $FILE_ID_LENGTH bytes. If
1763 * this parameter is NULL, this function has no effect.
1764 *
1765 * @return true on success.
1766 */
1767 get(uint32_t friend_number, uint32_t file_number) 1767 get(uint32_t friend_number, uint32_t file_number)
1768 with error for get; 1768 with error for get;
1769 } 1769 }
@@ -2371,8 +2371,6 @@ namespace conference {
2371 /** 2371 /**
2372 * Copy a list of valid conference IDs into the array chatlist. Determine how much space 2372 * Copy a list of valid conference IDs into the array chatlist. Determine how much space
2373 * to allocate for the array with the `$size` function. 2373 * to allocate for the array with the `$size` function.
2374 *
2375 * @return The number of elements copied to the array, or 0 if chatlist is set to NULL.
2376 */ 2374 */
2377 get(); 2375 get();
2378 } 2376 }
diff --git a/other/apidsl/toxav.in.h b/other/apidsl/toxav.in.h
index 07808eec..6e3e9c17 100644
--- a/other/apidsl/toxav.in.h
+++ b/other/apidsl/toxav.in.h
@@ -557,23 +557,24 @@ namespace video {
557 /** 557 /**
558 * The function type for the ${event receive_frame} callback. 558 * The function type for the ${event receive_frame} callback.
559 * 559 *
560 * The size of plane data is derived from width and height as documented
561 * below.
562 *
563 * Strides represent padding for each plane that may or may not be present.
564 * You must handle strides in your image processing code. Strides are
565 * negative if the image is bottom-up hence why you MUST abs() it when
566 * calculating plane buffer size.
567 *
560 * @param friend_number The friend number of the friend who sent a video frame. 568 * @param friend_number The friend number of the friend who sent a video frame.
561 * @param width Width of the frame in pixels. 569 * @param width Width of the frame in pixels.
562 * @param height Height of the frame in pixels. 570 * @param height Height of the frame in pixels.
563 * @param y 571 * @param y Luminosity plane. Size = MAX(width, abs(ystride)) * height.
564 * @param u 572 * @param u U chroma plane. Size = MAX(width/2, abs(ustride)) * (height/2).
565 * @param v Plane data. 573 * @param v V chroma plane. Size = MAX(width/2, abs(vstride)) * (height/2).
566 * The size of plane data is derived from width and height where 574 *
567 * Y = MAX(width, abs(ystride)) * height, 575 * @param ystride Luminosity plane stride.
568 * U = MAX(width/2, abs(ustride)) * (height/2) and 576 * @param ustride U chroma plane stride.
569 * V = MAX(width/2, abs(vstride)) * (height/2). 577 * @param vstride V chroma plane stride.
570 * @param ystride
571 * @param ustride
572 * @param vstride Strides data. Strides represent padding for each plane
573 * that may or may not be present. You must handle strides in
574 * your image processing code. Strides are negative if the
575 * image is bottom-up hence why you MUST abs() it when
576 * calculating plane buffer size.
577 */ 578 */
578 typedef void(uint32_t friend_number, uint16_t width, uint16_t height, 579 typedef void(uint32_t friend_number, uint16_t width, uint16_t height,
579 const uint8_t *y, const uint8_t *u, const uint8_t *v, 580 const uint8_t *y, const uint8_t *u, const uint8_t *v,