* change default multicast address

* fix timestamp calculation


git-svn-id: file:///home/lennart/svn/public/pulseaudio/trunk@715 fefdeb5f-60dc-0310-8127-8f9354f1896f
This commit is contained in:
Lennart Poettering 2006-04-15 15:26:42 +00:00
parent 71227de8b2
commit 1fec416db7
3 changed files with 9 additions and 8 deletions

View file

@ -35,7 +35,7 @@
#include "rtp.h"
pa_rtp_context* pa_rtp_context_init_send(pa_rtp_context *c, int fd, uint32_t ssrc, uint8_t payload) {
pa_rtp_context* pa_rtp_context_init_send(pa_rtp_context *c, int fd, uint32_t ssrc, uint8_t payload, size_t frame_size) {
assert(c);
assert(fd >= 0);
@ -44,7 +44,8 @@ pa_rtp_context* pa_rtp_context_init_send(pa_rtp_context *c, int fd, uint32_t ssr
c->timestamp = 0;
c->ssrc = ssrc ? ssrc : (uint32_t) (rand()*rand());
c->payload = payload & 127;
c->frame_size = frame_size;
return c;
}
@ -114,7 +115,7 @@ int pa_rtp_send(pa_rtp_context *c, size_t size, pa_memblockq *q) {
} else
k = 0;
c->timestamp += skip;
c->timestamp += skip/c->frame_size;
if (k < 0) {
if (errno != EAGAIN) /* If the queue is full, just ignore it */