I have written a program where i get udp packet from a multicast address. Now i need to extract the mpegts from this packet. I am able to take the payload of the udp packet. Can some one help me to extract the mpeg header from the udp packet.
MpegTS is typically transported over UDP with RTP. Skip the RTP header. The rest (188*7 bytes) is the payload, 7 TS packets. Each packet should start with 0x47.
Update:
There are multiple packetizing layers each wrapping/chunking the sequence. The upper layers are quite nice, the bottom one (elementary stream) is codec dependent and quite messy.