RTP H.264 frames into mp4 file

Sep 15, 2014 at 1:40 PM

I am using Managed Media Aggregation in my C# App to stream a video in RTSP - https://net7mma.codeplex.com/.

I have a RtspServer on my LAN that sends me RTP Frames encoded in H.264 (Payload Type 96).
I am looking for a way to save those frames/packets into a video file (mp4 I guess, could be other formats).

From what I understand, I don't have to decode it in order to save it to a file, just put it in a suitable container.

this is the method that is raised for each RTP frame that I recieve:
void Client_RtpFrameChanged(object sender, Media.Rtp.RtpFrame frame)
    // save to mp4 file
any ideas? been searching for a while..