I believe GStreamer can do this - just search "GStreamer RTSP" and you should come up with a few examples. GStreamer is quite complicated, but it is very powerful.