turboladen/rtp — pull request #3 by turboladen (2012-11-19 09:47:39+00:00)
Title: Receiver cleanup & added ability to inspect packets on the fly

The old way of just stashing data to a file and waiting until capturing is done to inspect the received data isn't very handy/intuitive. These changes let you pass a block to RTP::Receiver#start and inspect every packet.

In order to do this and assure that the data listener can do its job well, I moved the RTP packet parsing and writing/yielding to another thread; now one thread focuses on reading and putting data into a buffer (a Queue in this case) and the other thread focuses on parsing the packets and either writing them to the capture file or handing them over to the block.

In addition, I cleaned up the API and tweaked a few other things.