# RTMP to RTSP streaming results in very choppy, "out of order" video

**URL:** <https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351>\
**Category:** Wowza Streaming Engine\
**Created:** [May 10, 2011, 2:37pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351 "2011-05-10T14:37:44Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Justin\_Woods](https://avatars.discourse-cdn.com/v4/letter/j/b5a626/32.png) [@Justin\_Woods](https://community.wowza.com/u/Justin_Woods)\
**Post date:** [May 10, 2011, 2:37pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/1 "2011-05-10T14:37:44Z")

</div>

Hi,

I’m an EC2 customer. Have been using Wowza to chunk our Akamai RTMP streams into Apple HLS. We are very happy with it. It has been working just perfectly!

Today I want to setup Wowza to restream the RTMP stream to RTSP so that our viewers who use Linux will have an easier experience playing the streams.

I set up RTSP restreaming according to these articles:

[https://www.wowza.com/docs/how-to-re-stream-video-from-an-ip-camera-rtsp-rtp-re-streaming](https://www.wowza.com/docs/how-to-re-stream-video-from-an-ip-camera-rtsp-rtp-re-streaming)

[https://www.wowza.com/docs/how-to-set-up-live-streaming-using-an-rtmp-based-encoder](https://www.wowza.com/docs/how-to-set-up-live-streaming-using-an-rtmp-based-encoder)

It _almost_ works.

Playing the following URL in VLC results in very choppy video.

rtsp://live.hopetv.org:1935/live/HopeChannelNorthAmerica\_1.stream

It seems like 1- or 2-second bursts of video are arriving in a random order.

What am I doing wrong?

Justin

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [May 11, 2011, 2:37pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/2 "2011-05-11T14:37:26Z")

</div>

What would this do for linux clients? The way to re-stream rtmp is with StreamType liverepeater-edge, but I don’t think you need this. If all was working I would continue as you were before.

Richard

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [May 11, 2011, 2:48pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/3 "2011-05-11T14:48:57Z")

</div>

That should have no effect.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [July 26, 2011, 7:48am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/4 "2011-07-26T07:48:01Z")

</div>

What is the problem you are having? With Wowza Server 2.2.4.01 it should work great!

[https://www.wowza.com/docs/wowza-streaming-engine-software-updates](https://www.wowza.com/docs/wowza-streaming-engine-software-updates)

I see your stream. You might try turning off B-frames or reduce them to 1 B-frame (in a row). There are problems with streams that have more than 1 B-frame in a row.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [July 26, 2011, 11:47am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/5 "2011-07-26T11:47:05Z")

</div>

What encoder are you using? I do not see any B-frames but I do see the encoder sending chunks in big blasts rather then smoothly. You might try adding a sort buffer. This should smooth out playback. See this post #1:

[https://www.wowza.com/docs/troubleshoot-live-streaming](https://www.wowza.com/docs/troubleshoot-live-streaming)

I would use the following values to start with:

```auto
<Property>
	<Name>sortPackets</Name>
	<Value>true</Value>
	<Type>Boolean</Type>
</Property>
<Property>
	<Name>sortBufferSize</Name>
	<Value>1500</Value>
	<Type>Integer</Type>
</Property>

```

See if that helps.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [July 27, 2011, 12:33pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/6 "2011-07-27T12:33:29Z")

</div>

I looked at the stream using a private tool that I developed. I tried your RTSP stream in QuickTime on Windows and it played fine:

rtsp://ec2-204-236-155-15.us-west-1.compute.amazonaws.com:1935/live/HopeChannelNorthAmerica\_1.stream

Hmm, strange. So something about the stream is a problem for VLC.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [August 10, 2011, 6:43am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/7 "2011-08-10T06:43:55Z")

</div>

I am seeing the video stream dropping in and out. It looks like the encoder is dropping large groups of frames. What is the connection between the encoder and the Wowza Server? It almost is acting like FMLE is dropping frames because the connection between Wowza Server and the encoder is not good.

What does the stream look like when played over RTMP. It looks like your server is currently blocking RTMP connections so there is no way for us to look.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [August 10, 2011, 6:48am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/8 "2011-08-10T06:48:51Z")

</div>

BTW, the stream I am looking at is not Baseline it is Main level 4.0:

```auto
INFO server comment - LiveStreamPacketizerCupertino.handlePacket[rtplive/_definst_/rattle.stream][avc1.77.40]: H.264 (Video may not be playable on old
er iPhone and iPod touch devices where Baseline/Level 3.0 or lower is required) Video info: {H264CodecConfigInfo: profile: "Main", level: 4.0, frameSi
ze: 640x360, displaySize: 640x360, PAR: 1:1, crop: l:0 r:0 t:0 b:4, frameRate: 25.0}

```

I am analyzing this stream:

rtsp://www.popler.tv:8080/publishlive/Ratte84

If there is some other stream we should be looking at let us know but this stream is Main profile level 4.0.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [August 10, 2011, 6:49am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/9 "2011-08-10T06:49:04Z")

</div>

BTW, the stream I am looking at is not Baseline it is Main level 4.0:

```auto
INFO server comment - LiveStreamPacketizerCupertino.handlePacket[rtplive/_definst_/rattle.stream][avc1.77.40]: H.264 (Video may not be playable on old
er iPhone and iPod touch devices where Baseline/Level 3.0 or lower is required) Video info: {H264CodecConfigInfo: profile: "Main", level: 4.0, frameSi
ze: 640x360, displaySize: 640x360, PAR: 1:1, crop: l:0 r:0 t:0 b:4, frameRate: 25.0}

```

I am analyzing this stream:

rtsp://www.popler.tv:8080/publishlive/Ratte84

If there is some other stream we should be looking at let us know but this stream is Main profile level 4.0.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [August 10, 2011, 5:21pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/10 "2011-08-10T17:21:38Z")

</div>

I tried your stream again. The stream at:

rtsp://www.popler.tv:8080/publishlive/Ratte84

and it is still Main profile level 4.0 with B-frames.

```auto
INFO server comment - LiveStreamPacketizerCupertino.handlePacket[rtplive/_definst_/rattle.stream][avc1.77.40]: H.264 (Video may not be playable on older iPhone and iPod touch devices where Baseline/Level 3.0 or lower is required) Video info: {H264CodecConfigInfo: profile: "Main", level: 4.0, frameSize: 640x360, displaySize: 640x360, PAR: 1:1, crop: l:0 r:0 t:0 b:4, frameRate: 30.0}

```

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [August 11, 2011, 5:30am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/11 "2011-08-11T05:30:28Z")

</div>

The bandwidth looks pretty bad.

I can really explain why VLC plays the stream back so poorly. It could be bandwidth related. The stream plays back perfectly in QuickTime. This points to a player issue. If you turn on the debug info in VLC (add -vvv to command line) and open debug window it shows a ton of audio and video late messages. This indicates something is going wrong with delivery.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [August 11, 2011, 5:30am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/12 "2011-08-11T05:30:43Z")

</div>

The bandwidth looks pretty bad.

I can really explain why VLC plays the stream back so poorly. It could be bandwidth related. The stream plays back perfectly in QuickTime. This points to a player issue. If you turn on the debug info in VLC (add -vvv to command line) and open debug window it shows a ton of audio and video late messages. This indicates something is going wrong with delivery.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [August 11, 2011, 10:59am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/13 "2011-08-11T10:59:33Z")

</div>

I think so. I have seen many streams play fine in VLC. I have also seen many streams play poorly.

You might try different encoding params. It also might help to try AAC audio at 48KHz or 44.1KHz.

I also tried your RTSP stream using mplayer. I used the command line on Windows:

```auto
mplayer -rtsp-stream-over-tcp rtsp://www.popler.tv:8080/publishlive/piotrgg

```

The stream played well.

Charlie

---

<div class="post-metadata">

**Author:** ![Charlie\_Good](https://sea2.discourse-cdn.com/flex002/user_avatar/community.wowza.com/charlie_good/32/383_2.png) [@Charlie\_Good](https://community.wowza.com/u/Charlie_Good)\
**Post date:** [August 11, 2011, 10:59am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/14 "2011-08-11T10:59:48Z")

</div>

I think so. I have seen many streams play fine in VLC. I have also seen many streams play poorly.

You might try different encoding params. It also might help to try AAC audio at 48KHz or 44.1KHz.

I also tried your RTSP stream using mplayer. I used the command line on Windows:

```auto
mplayer -rtsp-stream-over-tcp rtsp://www.popler.tv:8080/publishlive/piotrgg

```

The stream played well.

Charlie

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [May 11, 2011, 3:47pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/15 "2011-05-11T15:47:00Z")

</div>

You want RTSP output, which will work as you were configured, re-streaming is not necessary. Just make sure the Application.xml /RTP /Authentication /PlayMethod is set to “none”

If this works in Wowza Flash example:

rtmp://[wowza-address]:1935/[app-name]

Stream: [stream-name]

Then this will work in RTSP client:

rtsp://[wowza-address]:1935/[app-name]/[stream-name]

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [May 11, 2011, 4:08pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/16 "2011-05-11T16:08:16Z")

</div>

It just works. Any supported input can be output on RTSP. You can test with VLC.

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [May 11, 2011, 4:17pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/17 "2011-05-11T16:17:14Z")

</div>

That is the symptom of bitrate vs bandwidth. The only solution for rtsp is use lower bitrate stream. There is not a way to do multi-bitrate streaming over rtsp.

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [May 11, 2011, 4:34pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/18 "2011-05-11T16:34:37Z")

</div>

It is pretty awful in Flash too, tho worse in VLC. Try this:

[https://www.wowza.com/docs/how-to-turn-on-an-rtp-jitter-buffer-and-packet-loss-logging-rtp-and-mpeg-ts](https://www.wowza.com/docs/how-to-turn-on-an-rtp-jitter-buffer-and-packet-loss-logging-rtp-and-mpeg-ts))

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [May 11, 2011, 5:38pm UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/19 "2011-05-11T17:38:00Z")

</div>

I would be careful not to leave a trail of configuration changes that don’t help and might hurt. Test with Wowza sample.mp4.

This might help some in VLC:

[https://www.wowza.com/docs/how-to-configure-vlc-media-player-for-rtsp-rtp-playback-rtsp-rtp-interleaved-and-tuning](https://www.wowza.com/docs/how-to-configure-vlc-media-player-for-rtsp-rtp-playback-rtsp-rtp-interleaved-and-tuning))

I think you should re-encode that video. Take a look at these encoding suggestions:

[https://www.wowza.com/docs/how-to-encode-video-on-demand-content](https://www.wowza.com/docs/how-to-encode-video-on-demand-content)

Richard

---

<div class="post-metadata">

**Author:** ![Richard\_Lanham](https://avatars.discourse-cdn.com/v4/letter/r/c68b51/32.png) [@Richard\_Lanham](https://community.wowza.com/u/Richard_Lanham)\
**Post date:** [August 10, 2011, 11:42am UTC](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351/20 "2011-08-10T11:42:20Z")

</div>

It plays well for me in VLC and Flash, no choppiness. That is a symptom of bitrate greater than bandwidth between a client and Wowza. You can use the BWCheck example to see what bandwidth is at a client. (remember this has nothing to do with bandwidth at the server or a client’s ISP speed, it is the bandwidth between client and server including all hops in between, bandwidth that fluctuates constantly.

I would not use the lowlatency stream type, which is makes the server work a little harder and is best for very low bitrate streams, as in chat applications. The solution in this case is to reduce the bitrate.

btw, I do not hear sound but VLC says there is an audio track and data is flowing. So I assume there just isn’t audio in range of the camera’s mic.

Richard

[Next page](https://community.wowza.com/t/rtmp-to-rtsp-streaming-results-in-very-choppy-out-of-order-video/36351.md?page=2)
