On Tue, Jul 10, 2012 at 07:36:11PM +0200, Jordi Ortiz wrote: > > --- a/libavformat/rtsp.h > +++ b/libavformat/rtsp.h > @@ -529,6 +535,12 @@ int ff_rtsp_setup_input_streams(AVFormatContext *s, > RTSPMessageHeader *reply); > > /** > + * Parses RTSP commands (OPTIONS, PAUSE and TEARDOWN) during streaming on > + * listen mode.
Parse > --- a/libavformat/rtspdec.c > +++ b/libavformat/rtspdec.c > @@ -45,6 +65,512 @@ static int rtsp_read_close(AVFormatContext *s) > > +/** > + * Reads one line from rtsp listening socket until \r\n is found. Read > + * @return 0 if success, error code if unsuccessful. on success > +/** > + * Send RTSP RESPONSE messages. > + * > + * @param s RTSP socket context. > + * @param code RESPONSE code. > + * @param extracontent Extra information to be appended to the message. > + * @param seq RTSP sequence number to be used. > + * @return 0 if success, error code if unsuccessful. ditto > +/** > + * Check session_id header and send RESPONSE if sessions don't coincide. > + * > + * @param s RTSP socket context. > + * @param session_id stored. > + * @param request REQUEST message header where session_id to be check > + * is stored. > + * @return 0 if success, error code if unsuccessful. ditto > +/** > + * Reads REQUEST's headers and parses them into the RTSPMessageHeader > structure Read > + * @param s RTSP socket context. > + * @param request REQUEST message header where parsed data will be stored > + * @param method method to which the headers to be read belong. > + * @return 0 if success, error code if unsuccessful. on success > +/** > + * Reads ANNOUNCE REQUEST headers, reads and parses the SDP data and sends Read > + * REPONSE to the client > + * > + * @param s RTSP socket context. > + * @return 0 if success, error code if unsuccessful. on success > +/** > + * Reads OPTIONS REQUEST headers and sends REPONSE to the client Read > + * @param s RTSP socket context. > + * @return 0 if success, error code if unsuccessful. on success > +/** > + * Reads SETUP REQUEST headers, configures transport and sends REPONSE to > + * the client Read > + * @return 0 if success, error code if unsuccessful. on success > +/** > + * Reads RECORD REQUEST headers and sends REPONSE to the client. Read > + * @param s RTSP socket context. > + * @return 0 if success, error code if unsuccessful. on success > +/** > + * Parses first line of REQUEST and checks command with the state. Sends > + * RESPONSE to the client. Parse > +/** > + * Parses RTSPs REQUESTs during streaming and sends RESPONSE to the client. Parse > @@ -157,6 +683,73 @@ int ff_rtsp_setup_input_streams(AVFormatContext *s, > RTSPMessageHeader *reply) > > +/** > + * Starts RTSP in listen mode to receive a stream. Start Diego _______________________________________________ libav-devel mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-devel
