Re-stream an Adobe Media Server stream that supports H.264 and AAC through the Wowza Streaming Engine™ media server software MediaCaster feature. Use this tutorial to set up an application named live to stream live content to Apple iOS devices and RTSP/RTP-based players.
Configure an application in XML
Start by setting up an application for live streaming and configuring Application.xml.
- Create application folder [install-dir]/applications/live.
- Create configuration folder [install-dir]/conf/live and copy [install-dir]/conf/Application.xml to this new folder.
- Edit the newly copied Application.xml file and make the following changes (some of these settings may already be present):
- Set the Streams/StreamType property to:
<StreamType>live</StreamType>
- Set the HTTPStreamers property to:
<HTTPStreamers>cupertinostreaming</HTTPStreamers>
- Set the Streams/LiveStreamPacketizers property to:
<LiveStreamPacketizers>cupertinostreamingpacketizer</LiveStreamPacketizers>
- Set the RTP/Authentication/PlayMethod property to:
<PlayMethod>none</PlayMethod>
- Add the following property to the MediaCaster/Properties container (be sure to get the correct <Properties> container, there are several in the Application.xml file):
<Property> <Name>callFCSubscribe</Name> <Value>true</Value> <Type>Boolean</Type> </Property>
- Set the Streams/StreamType property to:
Publish the stream using a .stream file in Wowza Streaming Engine Manager
Next, create a .stream file in Wowza Streaming Engine Manager to publish your stream to Wowza Streaming Engine using the MediaCaster (re-streaming) feature.
- Create the .stream file:
- In the Server contents panel, click Stream Files, and then click Add Stream File.
Note: You can also start the procedure to create a .stream file in the Applications contents panel for the live application.
- In the Add Stream File dialog box, enter a name for the new stream file and enter a Stream URI. The URI should be the full RTMP URL of the stream that you want to re-stream, for example, rtmp://cp12345.live.edgefcs.net/live/myStream@2440.
- Click Add.
- In the Server contents panel, click Stream Files, and then click Add Stream File.
- Start the stream:
- In the Server contents panel, click Stream Files, and then click the Connect icon for the stream file you created in step 1.
- In the Connect a Stream File dialog box, select live in Application Name and liverepeater in MediaCaster Type, and then click OK.
- In the Server contents panel, click Stream Files, and then click the Connect icon for the stream file you created in step 1.
Playback
Apple iOS device (Cupertino/Apple HLS)
Enter the following URL into the Safari web browser:
http://[address]:1935/live/rtmp.stream/playlist.m3u8
RTSP/RTP player
Enter the following URL into the RTSP/RTP player:rtsp://[address]:1935/live/rtmp.stream
Troubleshooting
RTSP/RTP
To stream to RTSP/RTP, be sure that UDP ports 0 to 65535 are open and properly mapped to the server running Wowza Streaming Engine. For more information, see Troubleshoot RTSP/RTP playback from Wowza Streaming Engine.
Common problems with .stream files
Many text editors will append a .txt filename extension to the rtmp.stream filename. This will result in an error message similar to the following:To fix this, go to the [install-dir]/content folder and remove the .txt filename extension from the file.
Property to force output to MPEG-TS (set-top box)
When streaming out using RTSP/RTP, you can force the output to MPEG-TS, which is required by many set-top boxes. For more information, see Generate and control MPEG-TS output for set-top boxes in Wowza Streaming Engine.Property to change AAC packetization method
Wowza Streaming Engine can use the mpeg4-generic and mp4a-latm (3gpp) packetization methods to output AAC audio. The default packetization method is mpeg4-generic.Wowza Streaming Engine Manager configuration
To switch to mp4a-latm (3gpp), do the following:- In Wowza Streaming Engine Manager, click the Applications tab and then click the name of your live application (such as live) in the contents panel.
- On the live application page Properties tab, click Custom in the Quick Links bar or scroll to the bottom of the page.
Note: Access to the Properties tab is limited to administrators with advanced permissions. For more information, see Manage credentials.
- In the Custom area, click Edit.
- Click Add Custom Property, specify the following settings in the Add Custom Property dialog box, and then click Add:
- Path: Select /Root/Application/RTP.
- Name: Enter audioPacketizerAAC.
- Type: Select String.
- Value: Enter com.wowza.wms.rtp.packetizer.RTPPacketizerMPEG4LATM.
- Path: Select /Root/Application/RTP.
- Click Save, and then restart the live application to apply the changes.
XML configuration
To switch to mp4a-latm (3gpp):- Use a text editor to open the [install-dir]/conf/[application]/Application.xml file for your live application and add the following property to the RTP/Properties container. Be sure to add the property to the correct <Properties> container in Application.xml as there are several such containers in the file.
<Property> <Name>audioPacketizerAAC</Name> <Value>com.wowza.wms.rtp.packetizer.RTPPacketizerMPEG4LATM</Value> </Property>
- Restart Wowza Streaming Engine to apply the changes.