[vlc-devel] Axis timeout problems

Kevin Jonkers, SittyWeb Internet Solutions kevin.jonkers at sittyweb.nl
Wed Oct 31 10:52:55 CET 2007


Hi all,

I'm experimenting with VLC and Axis webcams for quite some time now,  
and have found the following recently. Up until 0.8.6c, I could play  
and transcode the mpeg4 stream of an Axis camera nicely if I set the  
rtsp timeout in the cam to 0. With the latest nightly, this is not the  
case anymore.
I found the problem was in these lines:

/* Retrieve the timeout value and set up a timeout prevention thread */
         p_sys->i_timeout = p_sys->rtsp->sessionTimeoutParameter();
         if( p_sys->i_timeout <= 0 )
             p_sys->i_timeout = 60; /* default value from RFC2326 */
         if( !p_sys->p_timeout )
         {
         ....

So I changed it to:

/* Retrieve the timeout value and set up a timeout prevention thread */
#if LIVEMEDIA_LIBRARY_VERSION_INT >= 1138089600
         p_sys->i_timeout = p_sys->rtsp->sessionTimeoutParameter();
#endif
         //if( p_sys->i_timeout <= 0 )
         //    p_sys->i_timeout = 60; /* default value from RFC2326 */
         //if( !p_sys->p_timeout )
         if( p_sys->i_timeout > 0 && !p_sys->p_timeout )
         {
         ...

The problem is that if I set the camera timeout to 0, vlc will the set  
it to 60 (in the new code from the nightly). The major problem is then  
in the timeout prevention function. This function sends a  
"GET_PARAMETER" request to the camera. Unfortunately, Axis RTSP is not  
really compliant to the standard and does not understand this request.  
Therefore, at the first timeout prevention, the cam does not  
understand the request and the connection fails.

I guess the best solution would be another way of implementing the  
timeout thread, though the quick fix I wrote also seems to work.

Can I get any comments from the dev's on this? Of course, I'm also  
very interested in other Axis users' comments!

Cheers!



More information about the vlc-devel mailing list