[Live-devel] increase of buffer size

subrato roy roy.subrato at gmail.com
Thu Jun 15 04:20:49 PDT 2006


On 6/14/06, Ross Finlayson <finlayson at live555.com> wrote:
> At 04:32 AM 6/14/2006, you wrote:
> >Hello ,
> >
> >I am working with the framedSource::getNextFrame(). there is a need
> >for me to get as large a read as possible and fill it up in the fTo
> >bufer. Can someone tell me how to increase the buffer size for this.
>
> The buffer (and thus buffer size) is specified by the 'sink' object
> that's at the end of the chain - i.e., the object that you call
> "startPlaying()" on.
>
> For example, for "FileSink", there is a buffer size parameter.
>
> If your sink is a "RTPSink" subclass - i.e., for sending RTP packets
> - then you specify the buffer size by setting
> "OutPacketBuffer::maxSize" *before* you create the "RTPSink" object.
>
>
> 	Ross Finlayson

Hello All,

As instructed by you i changed the buffer size for the sink. But still
the buffer gets filled with 7 TS packets . looking at the code i think
i need to change the frame size to get more TS packets to fill this
bigger buffer completely. this is how i calculate number of TS packets
:

	fFrameSize += frameSize;
	unsigned const numTSPackets = fFrameSize/TRANSPORT_PACKET_SIZE;
	fFrameSize = numTSPackets*TRANSPORT_PACKET_SIZE;

in the function
afterGettingFrame(void* clientData, unsigned frameSize, ....)

to summarize my problem again :
    1)   i need this clientData (my buffer ) to be bigger and i think
i achieved this.
    2)   i need frameSize increased to actually allow me to have more
TS packets in this Bigger buffer.


Thanks for all your help
subrato


More information about the live-devel mailing list