DSS forwards data provided by live555

Source: Internet
Author: User
1. Reflect function of DSS

Darwin can receive and forward RTP data. This feature is described in the official document "reflect ".
Using VLC, you can easily demonstrate this function by running the following command:

vlc -vvv test.mp4 --sout "#dst=rtp{dst=,port-audio=20000,port-video=20002,ttl=127,name=CHANNEL,sdp=file:///f:/channel.sdp}"

Run the preceding command to generate an SDP description file channel. SDP. VLC will send the RTP packet to the specified port of the specified destination IP address. To ensure that the command is correct, check whether there is an error message in the VLC menu "tool"> "message". Normally, you can see the generated SDP information in the "message" window. Change the channel. copy SDP to the directory where the DSS media file is located on the target PC. Then, use VLC to directly open the channel. SDP can play the video. If you use mplayer, you cannot open it directly *. the SDP file should use the command "mplayer SDP: // channel. SDP ". Start DSS and run "rtsp: // <DSS
Ip>/channel. SDP "to connect to DSS.
In this way, you need to manually copy the SDP file to DSS. There is also an "automatic" method, which requires an RTSP client and implements the "announce" command. "Announce" can carry SDP information. After receiving the command, DSS can automatically create SDP files in the movies directory.

2. live555 provides DSS with data

Live555 supports the "announce" command to provide data to DSS and provides a testmpeg4videotodarwin sample program to test this function. Run the test. m4e (m4e file can then download the http://www.live555.com/liveMedia/public/m4e/ idea to the testmpeg4videotodarwin.exe directory, start the command line and enter:

$ ./testMPEG4VideoToDarwin.exe streaming...Beginning to read from file...Play this stream (from the Darwin Streaming Server) using the URL:        rtsp:// reading from fileBeginning to read from file...

Now open the movies directory of DSS and you will find that a file named test. SDP is automatically generated. Use VLC to open rtsp: // <DSS ip>/test. SDP to play back the file.

3. DSS permission Control

In my test environment, dssand testmpeg4videotodarwin.exe are on the same PC and the address is used. If you use a local IP address or send data to DSS on another PC, an error is prompted:

$ ./testMPEG4VideoToDarwin.exe streaming...Beginning to read from file...injector->setDestination() failed: 401 Unauthorized

The prompt message is obvious, which is related to permissions. Create a text file "qtaccess" in the movies directory. The content is as follows:

<Limit WRITE>require any-user</Limit>require any-user

After saving, restart the DSS service and test again.

$ ./testMPEG4VideoToDarwin.exe streaming...Beginning to read from file...Play this stream (from the Darwin Streaming Server) using the URL:        rtsp://

The above permission configuration allows any user to log on, or does not provide the user name and password. By default, when the address is used, all permissions are available. For more information about DSS permission control, see http://manuals.info.apple.com/en/quicktimestreamingsrvradminguide.htm.
4. RTSP command Interaction

The interaction process of the RTSP command captured by Wireshark is as follows:


If other PCs cannot connect to the DSS server, disable the firewall and try again. This problem occurs in my win7 by default.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.