[Live-devel] New, improved "RTSPClient" interface now available
Ross Finlayson
finlayson at live555.com
Sat May 29 17:46:45 PDT 2010
RTSPClient:
==========
I have installed a new version (2010.05.29) of the "LIVE555 Streaming
Media" code that adds the long-promised new 'asynchronous' (i.e.,
non-blocking) interface to the "RTSPClient" class.
Each operation that sends a RTSP command now takes a 'response
handler' function as parameter.
The operation will immediately (without blocking), but the
'response handler' function will get called later, when a response
arrives (or if an error occurs). This will make it practical to
open/receive multiple RTSP streams simultaneously, and/or perform
other operations concurrently with RTSP client operations.
For backwards compatibility, the old 'synchronous' interface still
remains, and is implemented using the new 'asynchronous' interface.
(Therefore, existing RTSP client applications should not need to be
modified - for now.) Note, however, that the old 'synchronous'
interface should not be used for new applications, and it will likely
be removed in a few months.) For now, the demo application
"openRTSP" still uses the old interface, but will be rewritten over
the next few weeks to use the new interface.
For details, see
http://www.live555.com/liveMedia/doxygen/html/RTSPClient_8hh-source.html
I have done a lot of testing with this new interface and
implementation, but if you find any problems, please let us know.
TaskScheduler:
==========
Unfortunately I have modified the "TaskScheduler" definition yet
again, because I felt it was getting too complicated. There's now
just one virtual function for setting/clearing socket handlers:
virtual void setBackgroundHandling(int socketNum, int conditionSet,
BackgroundHandlerProc* handlerProc, void*
clientData) = 0;
where "conditionSet" is a combination of the SOCKET_READABLE,
SOCKET_WRITABLE, and SOCKET_EXCEPTION flags. If you have your own
implementation of "TaskScheduler", then you will need to implement
this virtual function - and not the old "turnOn*" and "turnOff*"
functions. (For backwards compatibility, however, the existing
"turnOnBackgroundReadHandling()" and
"turnOffBackgroundReadHandling()" functions are retained, but are now
implemented using "setBackgroundHandling()".)
For details, see
http://www.live555.com/liveMedia/doxygen/html/UsageEnvironment_8hh-source.html
--
Ross Finlayson
Live Networks, Inc.
http://www.live555.com/
More information about the live-devel
mailing list