Lines Matching refs:sender

25 rtp_sendto(rtp_sender_t sender, const void* msg, int len) {  in rtp_sendto()  argument
31 strncpy(sender->message.body, msg, len); in rtp_sendto()
34 sender->message.header.seq = ntohs(sender->message.header.seq) + 1; in rtp_sendto()
35 sender->message.header.seq = htons(sender->message.header.seq); in rtp_sendto()
36 sender->message.header.ts = ntohl(sender->message.header.ts) + 1; in rtp_sendto()
37 sender->message.header.ts = htonl(sender->message.header.ts); in rtp_sendto()
40 stat = srtp_protect(sender->srtp_ctx, &sender->message.header, &pkt_len); in rtp_sendto()
48 srtp_print_packet(&sender->message.header, pkt_len); in rtp_sendto()
50 octets_sent = sendto(sender->socket, (void*)&sender->message, in rtp_sendto()
51 pkt_len, 0, (struct sockaddr *)&sender->addr, in rtp_sendto()
102 rtp_sender_init(rtp_sender_t sender, in rtp_sender_init() argument
108 sender->message.header.ssrc = htonl(ssrc); in rtp_sender_init()
109 sender->message.header.ts = 0; in rtp_sender_init()
110 sender->message.header.seq = (uint16_t) rand(); in rtp_sender_init()
111 sender->message.header.m = 0; in rtp_sender_init()
112 sender->message.header.pt = 0x1; in rtp_sender_init()
113 sender->message.header.version = 2; in rtp_sender_init()
114 sender->message.header.p = 0; in rtp_sender_init()
115 sender->message.header.x = 0; in rtp_sender_init()
116 sender->message.header.cc = 0; in rtp_sender_init()
119 sender->socket = socket; in rtp_sender_init()
120 sender->addr = addr; in rtp_sender_init()
150 rtp_sender_init_srtp(rtp_sender_t sender, const srtp_policy_t *policy) { in rtp_sender_init_srtp() argument
151 return srtp_create(&sender->srtp_ctx, policy); in rtp_sender_init_srtp()
155 rtp_receiver_init_srtp(rtp_receiver_t sender, const srtp_policy_t *policy) { in rtp_receiver_init_srtp() argument
156 return srtp_create(&sender->srtp_ctx, policy); in rtp_receiver_init_srtp()