[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Linphone-developers] question about rtp packets
From: |
Simon Morlat |
Subject: |
Re: [Linphone-developers] question about rtp packets |
Date: |
Thu, 23 Mar 2006 17:42:30 +0100 |
User-agent: |
KMail/1.9.1 |
Le Mardi 21 Mars 2006 09:27, meng hongling a écrit :
> I've solved this problem.thank you simon.
> not I can here sound from both side.but there is sound delay and the sound
> is discontinuous.
> you told me it my because the big block size(mine is 8192).but what should
> I do to solve this problem.and in the process,there are too many "Must
> catchup" Warnings.
The must catchup is happening because the streaming thread is waiting too much
time on the read() of that big block size on the sound device.
You can try making this read() non blocking, or try to reduce the blocksize by
whatever means.
Simon
>
> >From: Simon Morlat <address@hidden>
> >To: address@hidden
> >CC: "meng hongling" <address@hidden>
> >Subject: Re: [Linphone-developers] question about rtp packets
> >Date: Thu, 16 Mar 2006 22:40:55 +0100
> >
> >Le Jeudi 16 Mars 2006 14:13, meng hongling a �rit?
> >
> > > another more question
> > > Since my sound card only support stereo,I have to discard a half
>
> samples.
>
> > > so I edit osscard.c oss_card_read() function like this:
> > > char *buf;
> > > buf=(char *)malloc(2*bsize); ******here my board bsize=8192
> > > err2=read(obj->fd,buf,bsize*2);
> > > err=err2/2;
> > > char buffer[err];
> > > for (j=0;j<err;j=j+2)
> > > {
> > > buffer[j]=buf[2*j]; ******ample format is 16 bits so I have
>
> to
>
> > > discard 2 bytes in
> > > buffer[j+1]=buf[2*j+1]; ******every 4 bytes.
> > > }
> > > obj->readbuf=buffer;
> >
> >The variable buffer is on the stack. It is discarded when you go out of
>
> the
>
> >oss_card_read() function. You should copy the samples directly to
> >obj->readbuf, not replace it.
> >
> >Simon
>
> _________________________________________________________________
> 与联机的朋友进行交流,请使用 MSN Messenger: http://messenger.msn.com/cn
- Re: [Linphone-developers] oRTP, multiple RTP streams and silence suppression, Simon Morlat, 2006/03/08
- Message not available
- Message not available
- Message not available
- Re: [Linphone-developers] oRTP, multiple RTP streams and silence suppression, Mark Mickan, 2006/03/13
- [Linphone-developers] question about rtp packets, meng hongling, 2006/03/14
- RE: [Linphone-developers] question about rtp packets, meng hongling, 2006/03/16
- Re: [Linphone-developers] question about rtp packets, Simon Morlat, 2006/03/16
- Re: [Linphone-developers] question about rtp packets, meng hongling, 2006/03/21
- Re: [Linphone-developers] question about rtp packets,
Simon Morlat <=
- Re: [Linphone-developers] question about rtp packets, Simon Morlat, 2006/03/16
- Re: [Linphone-developers] oRTP, multiple RTP streams and silence suppression, Simon Morlat, 2006/03/16