Wowza Community

Passing through audio and video to WebRTC without using Wowza Transcoder

Hi Guys.

I would like to be able to use my FFMPEG encoder to create a WebRTC suitable source stream to ingest into Wowza.

So far I have managed to get a udp SPTS with H264 and AAC working, where video would get passed through to WebRTC, but AAC would be dropped.

Additionally I have tried all sorts of unorthodox tests of replacing AAC with Opus, Vorbis streams within SPTS, which also didn’t work (no surprise there as these audio codecs are outside the SPTS spec).

Another test was to try and create a webM stream and push it via UDP, which failed and creating an interleaved RTP stream with VP8 and Vorbis/Opus which also failed as Wowza doesn’t take native RTP stream.

so, I am slightly out of options here, and would appreciate some pointers on what the flavour the live source should be of.

Thanks

Svyatko

I would also like to do this, the transcoding is killing the quality (for me). Are you using ffmpeg binary or some app with it built-in?

Hi Guys.

I would like to be able to use my FFMPEG encoder to create a WebRTC suitable source stream to ingest into Wowza.

So far I have managed to get a udp SPTS with H264 and AAC working, where video would get passed through to WebRTC, but AAC would be dropped.

Additionally I have tried all sorts of unorthodox tests of replacing AAC with Opus, Vorbis streams within SPTS, which also didn’t work (no surprise there as these audio codecs are outside the SPTS spec).

Another test was to try and create a webM stream and push it via UDP, which failed and creating an interleaved RTP stream with VP8 and Vorbis/Opus which also failed as Wowza doesn’t take native RTP stream.

so, I am slightly out of options here, and would appreciate some pointers on what the flavour the live source should be of.

Thanks

Svyatko

hello

regarding this codecs issue, is there any compatibility table available, about wowza transcoder capabilities.something like flash rtmp nellymosercan be transcoded to x,y, z, flash rtmp speex to a,b,c etc…? that would save time to lot of people i think:) for example i’mstuck since weeks trying to make webrtc from my flash based app, still cant achieve it…finally it might just be a codec issue…

thank you

Hi. We are using our own ffmpeg build. question still stands though, what do I present to Wowza as a source for WebRTC pass-through.

No ideas on how to pass non-WebRTC inputs to WebRTC clients without transcoding?

@ Wowza support guys.*Can you at least confirm that this is either supported/possible/on the roadmap etc. Any feedback would be appreciated.

Thanks

Svy

Hi Jason,

From your experience, can you tell me what application/device can create a valid ingest source for Wowza WebRTC?

As I have originally mentioned I am using FFMPEG, and push MPEGTS over UDP as a multicast. We all know H264 in SPTS will get passed through, but not the audio, which is usually AAC. Now we need to get audio to be passed through.

After a bit of a research, there is a draft for OPUS-in-TS, which in theory should work with FFMPEG, ,and should be passed-through by Wowza.

I have now created an MPEGTS multicast UDP stream which contains H264 video and Opus audio. See screenshot https://1drv.ms/i/s!Ar_ePfSDBV8x2NRsoF6Y39lQ1sSxyw

This stream is playable in latest stable VLC nightly, and Wowza seems to recognize the Opus audio within the MPEGTS stream, BUT my WebRTC play example continues playing just video, not the audio.*

[HTML]Date/Time

Event/Category

Comment

More Information

2017-01-13

16:55:34 (UTC)

play

webrtc (200)

x-ctx: test02.stream,x-vhost: defaultVHost,x-app: webrtc,x-appinst: definst,x-duration: 0.123,s-port: 80,s-uri: null,c-ip: 10.23.203.200,c-proto: webrtc,c-user-agent: known,c-client-id: 265302123,cs-bytes: 0,sc-bytes: 0,x-stream-id: 7,x-spos: 0,cs-stream-bytes: 0,sc-stream-bytes: 0,x-sname: test02.stream,x-suri: null,x-suri-stem: null,cs-uri-stem: null

2017-01-13

16:55:34 (UTC)

comment

server (200)

WebRTCRTPHandler.bind: port:4

x-duration: 2035.702

2017-01-13

16:55:34 (UTC)

comment

server (200)

WebRTCRTPHandler.bind: port:3

x-duration: 2035.702

2017-01-13

16:55:34 (UTC)

comment

server (200)

WebRTCDTLSHandlerThread.run: Handshake complete

x-duration: 2035.702

2017-01-13

16:55:34 (UTC)

comment

server (200)

WebSocketSession.destroy[1866914741]: source:client status:-1 description:Unknown

x-duration: 2035.65

2017-01-13

16:55:34 (UTC)

comment

server (200)

WebRTCCommands.sendResponse[test02.stream]: iceCandidate:candidate:0 1 UDP 50 10.23.205.210 6978 typ host generation 0

x-duration: 2035.601

  • (-)

2035.601 (-)

a=fmtp:97 level-asymmetry-allowed=1;packetization-mode=1;profile-level-id=42e01f

a=rtcp-fb:97 nack pli

a=rtcp-fb:97 nack

a=rtcp-fb:97 ccm fir

a=rtpmap:97 H264/90000

a=rtcp-mux

a=recvonly

a=mid:video

a=setup:active

a=fingerprint:sha-256 CD:68:1D:D6:72:D5:97:72:34:A1:CA:5D:68:EA:A6:E2:D9:E4:7A:59:ED:85:4D:7C:CB:96:E0:52:2E:D7:56:BA

a=ice-pwd:4gLRQyyNnIUDbTdM0XeJzsBG

a=ice-ufrag:XGHG

a=rtcp:9 IN IP4 0.0.0.0

c=IN IP4 0.0.0.0

m=video 9 RTP/SAVPF 97

a=msid-semantic: WMS

a=group:BUNDLE video

t=0 0

s=-

o=- 8368360515071137021 2 IN IP4 127.0.0.1

2017-01-13

16:55:34 (UTC)

comment

server (200)

WebRTCCommands.getOffer[test02.stream]: offer:v=0

2017-01-13

16:55:34 (UTC)

create

webrtc (200)

x-vhost: defaultVHost,x-app: webrtc,x-appinst: definst,x-duration: 0.002,s-port: 80,s-uri: null,c-ip: 10.23.203.200,c-proto: webrtc,c-user-agent: known,c-client-id: 265302123,cs-bytes: 0,sc-bytes: 0,x-stream-id: 7,x-spos: 0,cs-stream-bytes: 0,sc-stream-bytes: 0,x-sname: test02.stream,x-suri: null,x-suri-stem: null,cs-uri-stem: null

2017-01-13

16:55:34 (UTC)

comment

server (200)

WebRTCCommands.getOffer[test02.stream]: WebRTC play successful: video:H264

x-duration: 2035.583

2017-01-13

16:55:34 (UTC)

comment

server (200)

WebRTCCommands.getOffer[test02.stream]: Many web browser only support H.264 baseline profile when streamed over WebRTC, playback may not work: profile:Main

x-duration: 2035.581

2017-01-13

16:55:34 (UTC)

comment

server (200)

WebSocketSession.create[1866914741]

x-duration: 2035.568[/HTML]

Any ideas what’s happening here, as I am essentially sending valid audio and video that doesn’t need transcoding.

FYI, I am using latest Wowza Streaming Engine 4.6.0.01

Best regards

Svyatko

Hi,

There’s a table in the transcoding article that you can reference.

Regards,

Jason Hilton

Technical Support Engineer

Wowza Media Systems

Hi,

Yes that’s correct. I’ve just tested this with my WebRTC application and a RTMP based encoder publishing H.264 video. The video then played without transcoding.

If you’re getting different results, please open a ticket with our support team and link to this thread for reference. Include a ZIP file containing the [Wowza-Install]/conf/ directory and latest log files for analysis.

Regards,

Jason Hilton

Technical Support Engineer

Wowza Media Systems

No ideas on how to pass non-WebRTC inputs to WebRTC clients without transcoding?

this is important for applications where the source is Flash or other h264 encoders (like a Teradek or FFMPEG) and you want low latency (without flash as the playback engine).

Just to verify what you are saying, an h264 baseline ‘video only’ stream published by FFMPEG via RTMP would be viewable via WebRTC without transcoding? This is assuming the browser is able to play h264 streams (Firefox and Chrome (version 52 and above)). Is this correct?

thanks for the followup I’ll give it a try.

Hello all,

Chrome, Mozilla Firefox and Microsoft Edge do not support AAC audio over WebRTC. Streams with AAC audio will play as video only.

Wowza Streaming Engine’s WebRTC implementation supports the following codecs:

Video: VP8, VP9, H.264

Audio: Opus, Vorbis, PCMU, PCMA

Not all browsers support all codecs. It is best to use VP8 video with either Opus or Vorbis audio.

The dependency on Wowza Transcoder with WebRTC is determined by the inbound and outputbound format/protocol/codec.

If the source stream is 100% compatible with Wowza Streaming Engine’s WebRTC implementation then the Transcoder is not required.

Regards,

Alex

@ Wowza Support guys, - any feedback would be appreciated.

Thanks

Svyatko

I’ve been successfully playing streams from FFMPEG over WebRTC through Wowza.

For testing I’m using a local mp4 that is h264 and AAC. I use ffmpeg to push that to Wowza via RTSP/RTP. ffmpeg ends up transcoding the video from h264 high profile to baseline profile and then audio from AAC to opus. The command I’m using looks like this:

ffmpeg -re -i ./big-buck-bunny.mp4 -acodec opus -vcodec libx264 -vprofile baseline -f rtsp rtsp:///rtsp-to-webrtc/my-stream

Does something like that work for you?

Thanks a lot for that, I will give it a go to see what Wowza says on it. I didn’t try going RTSP way, but will certainly do.

I am not massively thrilled though about the use of RTSP on a large scale and would prefer MPEG-TS and multicast, that is if Wowza could add the support for TSs with Opus audio, like VLC did in the latest builds.

@ Wowza Support again - can we get a confirmation on

  1. Is the MPEG-TS with Opus audio supported ?

  2. If not supported, can it be ? and when should we expect it ?

Thanks

svyatko*

I’ve been successfully playing streams from FFMPEG over WebRTC through Wowza.

For testing I’m using a local mp4 that is h264 and AAC. I use ffmpeg to push that to Wowza via RTSP/RTP. ffmpeg ends up transcoding the video from h264 high profile to baseline profile and then audio from AAC to opus. The command I’m using looks like this:

ffmpeg -re -i ./big-buck-bunny.mp4 -acodec opus -vcodec libx264 -vprofile baseline -f rtsp rtsp:///rtsp-to-webrtc/my-stream

Does something like that work for you?

We have similar problems with Wowza WebRTC from browser and Wowza recording.

H.264 is the only video codec supported by Wowza WebRTC, Wowza recorder and modern Chrome&FireFox with WebRTC.

Opus is the only working modern streaming audio codec with good quality supported by Wowza WebRTC and modern Chrome&FireFox with WebRTC.

That’s why for now we ended up with force h.264 video and opus audio from Wowza WebRTC side and use Wowza Transcoder audio-only with video pass-trough and record transcoded stream. Audio-only transcoding CPU usage is acceptable in our case.

HI!

Did you manage to find out solution for OPUS audio codec?
Can you stream audio OPUS and wowza webrtc plays it out?