RTSP Video decoding (over wifi)

Hello,
Any code sample for RTSP stream processing (H264 or MJPEG) ie grab frames and give it for classification.

regards