summaryrefslogtreecommitdiff
path: root/src/lrtp.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lrtp.h')
-rw-r--r--src/lrtp.h23
1 files changed, 11 insertions, 12 deletions
diff --git a/src/lrtp.h b/src/lrtp.h
index ce6b0e2..d4abbc1 100644
--- a/src/lrtp.h
+++ b/src/lrtp.h
@@ -56,15 +56,13 @@ struct lrtp_t *lrtp_init(const char *key, unsigned int ssrc);
EXPORT
void lrtp_close(struct lrtp_t *lrtp);
-struct lrtp_profile_t;
-
/**
- * @param ...
+ * @return 0 on success, 1 on error.
*/
EXPORT
-struct lrtp_profile_t *lrtp_create_profile(struct lrtp_t *lrtp,
- lrtp_profile_id_t profile_id,
- unsigned int csrc, ...);
+int lrtp_create_profile(struct lrtp_t *lrtp,
+ lrtp_profile_id_t profile_id,
+ unsigned int csrc, ...);
EXPORT
void lrtp_destroy_profile(struct lrtp_t *lrtp, unsigned int csrc);
@@ -75,7 +73,7 @@ typedef enum {
PACK_BUFFER_TOO_SMALL = 1001, // Packet buffer needs to be bigger.
PACK_UNKNOWN_PROFILE = 1002, // Illegal profile id
PACK_MISSING_PROFILE = 1003, // Profile pointer NULL or not valid.
-} lrtp_pack_status_t;
+} lrtp_pack_status_t;f
/**
* Enqueue a media frame for the packetiser.
@@ -83,15 +81,16 @@ typedef enum {
* @param framedate The frame data that needs encapsulation.
* @param framesize The size in bytes of the frame data.
* @return 0 on success, or a negative error code on error.
- * NOTE: The frame pointer cannot be freed or overwritten until all frame data
- * has been handled by lrtp_pack(). Either call lrtp_pack() until it returns 0
- * after each call to lrtp_enqueue_frame or use the
+ * WARNING: The frame pointer cannot be freed or overwritten until all frame
+ * data has been handled by lrtp_pack(). Either call lrtp_pack() until it
+ * returns 0 after each call to lrtp_enqueue_frame or use the
* OPTION_SET_PROCESS_FINISHED_HANDLER option to set a process finished handler.
* See lrtp_profiles.h for further details.
*/
EXPORT
-int lrtp_enqueue_frame(struct lrtp_profile_t *profile,
- const char *framedate, size_t framesize);
+int lrtp_enqueue_frame(struct lrtp_t *lrtp, unsigned int csrc,
+ const char *framedate, size_t framesize,
+ unsigned long int timestamp);
/**
* Handle frame data from the frame queue and create at most a single sRTP