I'm making an application that gets a socket multicast. This multicast is forwarded to a mpeg decoder card with 1 meg buffer on it.

The problem is the buffer, it gets overflowed. because the mpeg stream sometimes have alot of data in it, and sometimes not.
You can say that the mpeg stream is not synchronous with nr of bytes read from the mpeg file.

Therefore I need a memorybuffer on several megabytes.

I thought on memorystream.

But I can't figure out how to write to the same stream, and then read from it. any ideas ?


----------------------------------
Please visit http://www.betstakes.com