liburtc
Small footprint WebRTC stack for embedded devices
urtc.h
Go to the documentation of this file.
1 
47 #ifndef _URTC_H
48 #define _URTC_H
49 
50 #ifdef __cplusplus
51 extern "C" {
52 #endif
53 
60 typedef struct peerconn urtc_peerconn_t;
61 
76 typedef int (urtc_on_ice_candidate)(const char *cand, void *arg);
77 
90 typedef void (urtc_force_idr)();
91 
92 
111 urtc_peerconn_t * urtc_peerconn_create(const char *stun[]);
112 
120 
136 int urtc_add_ice_candidate(urtc_peerconn_t *pc, const char *cand);
137 
155 int urtc_create_answer(urtc_peerconn_t *pc, char **answer);
156 
174 int urtc_create_offer(urtc_peerconn_t *pc, char **offer);
175 
192 int urtc_set_local_description(urtc_peerconn_t *pc, const char *desc);
193 
210 int urtc_set_remote_description(urtc_peerconn_t *pc, const char *desc);
211 
218 
219 #ifdef __cplusplus
220 }
221 #endif
222 
223 #endif /* _URTC_H */
void urtc_peerconn_destroy(urtc_peerconn_t *pc)
Tears down peer connection, closing and freeing all resources.
int urtc_create_offer(urtc_peerconn_t *pc, char **offer)
Creates a local description for an offering peer connection.
void() urtc_force_idr()
(callback) Called to request that video encoder immediately generate an IDR
Definition: urtc.h:90
urtc_peerconn_t * urtc_peerconn_create(const char *stun[])
Create a new peer connection.
int urtc_set_local_description(urtc_peerconn_t *pc, const char *desc)
Sets local description for peer connection.
int() urtc_on_ice_candidate(const char *cand, void *arg)
(callback) Called for each new local ICE candidate discovered
Definition: urtc.h:76
int urtc_set_remote_description(urtc_peerconn_t *pc, const char *desc)
Sets remote description.
int urtc_add_ice_candidate(urtc_peerconn_t *pc, const char *cand)
Adds received remote ICE candidate to peer connection.
struct peerconn urtc_peerconn_t
Opque peer connection structure.
Definition: urtc.h:60
int urtc_create_answer(urtc_peerconn_t *pc, char **answer)
Creates local description for an answering peer connection.
int urtc_set_on_ice_candidate(urtc_peerconn_t *pc, urtc_on_ice_candidate *cb)
Sets onIceCandidate callback function.