Difference between revisions of "GstWebRTC - Audio Examples - x86"
Jcaballero (talk | contribs) (Created page with "{{GstWebRTC Page| GstWebRTC Basics| GstWebRTC Pipelines| This page presents some audio examples of GstWe...") |
m |
||
(38 intermediate revisions by 5 users not shown) | |||
Line 1: | Line 1: | ||
− | {{GstWebRTC | + | {{GstWebRTC/Head|previous=OpenWebRTC Signaler Examples - x86|next=Video Examples - x86|keywords=GstRrWebRTC Examples,WebRTC Examples,GstRrWebRTC GStreamer pipelines,WebRTC GStreamer pipelines,OpenWebRTC signaler,OpenWebRTC Examples,WebRTC Audio Example, WebRTC GStreamer Audio pipelines,GstRrWebRTC GStreamer Audio pipelines,signaling}} |
− | |||
− | |||
− | This page presents some audio examples | + | This page presents some GstRrWebRTC audio examples on '''x86 platform''' using OpenWebRTC. |
+ | <br> | ||
+ | <br> | ||
+ | |||
+ | {{GStreamer debug}} | ||
==Opus== | ==Opus== | ||
− | ===Unidirectional=== | + | ===Unidirectional Elements=== |
− | + | ====Example==== | |
+ | In this example we use rrwebrtcbin to send an audio stream. | ||
+ | =====Send pipeline===== | ||
The following pipeline will send periodic ticks: | The following pipeline will send periodic ticks: | ||
<syntaxhighlight lang='bash'> | <syntaxhighlight lang='bash'> | ||
− | gst-launch-1.0 | + | gst-launch-1.0 rrwebrtcbin start-call=true signaler=GstOwrSignaler \ |
+ | signaler::server_url=https://webrtc.ridgerun.com:8443 \ | ||
signaler::session_id=1234ridgerun name=web audiotestsrc is-live=true wave=8 ! audioconvert ! audioresample \ | signaler::session_id=1234ridgerun name=web audiotestsrc is-live=true wave=8 ! audioconvert ! audioresample \ | ||
− | ! queue ! opusenc ! rtpopuspay ! web. | + | ! queue ! opusenc ! rtpopuspay ! web.audio_sink |
</syntaxhighlight> | </syntaxhighlight> | ||
− | + | =====Receive pipeline===== | |
The following pipeline will receive the periodic ticks: | The following pipeline will receive the periodic ticks: | ||
<syntaxhighlight lang='bash'> | <syntaxhighlight lang='bash'> | ||
− | gst-launch-1.0 | + | gst-launch-1.0 rrwebrtcbin start-call=false signaler=GstOwrSignaler \ |
− | signaler::session_id=1234ridgerun name=web web. | + | signaler::server_url=https://webrtc.ridgerun.com:8443 \ |
+ | signaler::session_id=1234ridgerun name=web web.audio_src ! rtpopusdepay ! opusdec ! audioconvert ! \ | ||
alsasink async=false | alsasink async=false | ||
</syntaxhighlight> | </syntaxhighlight> | ||
Line 27: | Line 33: | ||
<br /><br /> | <br /><br /> | ||
− | ===Bidirectional=== | + | ===Bidirectional Element=== |
− | + | ====Example==== | |
+ | In this example we use two rrwebrtcbin elements, each sends an audio stream and receives each other audio stream. | ||
+ | |||
+ | =====Send-Receive Pipeline===== | ||
The following pipeline will send a white noise audio stream and receive the ticks audio stream sent by the next pipeline. This pipeline starts the call. | The following pipeline will send a white noise audio stream and receive the ticks audio stream sent by the next pipeline. This pipeline starts the call. | ||
<syntaxhighlight lang='bash'> | <syntaxhighlight lang='bash'> | ||
− | gst-launch-1.0 | + | gst-launch-1.0 rrwebrtcbin start-call=true signaler=GstOwrSignaler \ |
+ | signaler::server_url=https://webrtc.ridgerun.com:8443 \ | ||
signaler::session_id=1234ridgerun name=web audiotestsrc is-live=true wave=5 ! audioconvert ! \ | signaler::session_id=1234ridgerun name=web audiotestsrc is-live=true wave=5 ! audioconvert ! \ | ||
audioresample ! queue ! opusenc ! rtpopuspay ! web.audio_sink web.audio_src ! rtpopusdepay ! \ | audioresample ! queue ! opusenc ! rtpopuspay ! web.audio_sink web.audio_src ! rtpopusdepay ! \ | ||
Line 38: | Line 48: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
+ | =====Send-Receive Pipeline===== | ||
The following pipeline will send ticks audio stream and receive the white noise audio stream sent by the previous pipeline. This pipeline joins the call. | The following pipeline will send ticks audio stream and receive the white noise audio stream sent by the previous pipeline. This pipeline joins the call. | ||
<syntaxhighlight lang='bash'> | <syntaxhighlight lang='bash'> | ||
− | gst-launch-1.0 | + | gst-launch-1.0 rrwebrtcbin start-call=false signaler=GstOwrSignaler \ |
+ | signaler::server_url=https://webrtc.ridgerun.com:8443 \ | ||
signaler::session_id=1234ridgerun name=web audiotestsrc is-live=true wave=8 ! audioconvert ! \ | signaler::session_id=1234ridgerun name=web audiotestsrc is-live=true wave=8 ! audioconvert ! \ | ||
audioresample ! queue ! opusenc ! rtpopuspay ! web.audio_sink web.audio_src ! rtpopusdepay ! \ | audioresample ! queue ! opusenc ! rtpopuspay ! web.audio_sink web.audio_src ! rtpopusdepay ! \ | ||
Line 48: | Line 60: | ||
When executing the two previous pipelines, you should be able to listen the ticks and the white noise. | When executing the two previous pipelines, you should be able to listen the ticks and the white noise. | ||
− | + | {{GstWebRTC/Foot|previous=OpenWebRTC Signaler Examples - x86|next=Video Examples - x86}} | |
− | }} |
Latest revision as of 12:58, 13 April 2020
![]() |
GstWebRTC | ||||||||
---|---|---|---|---|---|---|---|---|
![]() | ||||||||
WebRTC Fundamentals | ||||||||
GstWebRTC Basics | ||||||||
|
||||||||
Evaluating GstWebRTC | ||||||||
Getting the code | ||||||||
Building GstWebRTC | ||||||||
Examples | ||||||||
|
||||||||
MCU Demo Application | ||||||||
Contact Us |
This page presents some GstRrWebRTC audio examples on x86 platform using OpenWebRTC.
|
Contents
Opus
Unidirectional Elements
Example
In this example we use rrwebrtcbin to send an audio stream.
Send pipeline
The following pipeline will send periodic ticks:
gst-launch-1.0 rrwebrtcbin start-call=true signaler=GstOwrSignaler \
signaler::server_url=https://webrtc.ridgerun.com:8443 \
signaler::session_id=1234ridgerun name=web audiotestsrc is-live=true wave=8 ! audioconvert ! audioresample \
! queue ! opusenc ! rtpopuspay ! web.audio_sink
Receive pipeline
The following pipeline will receive the periodic ticks:
gst-launch-1.0 rrwebrtcbin start-call=false signaler=GstOwrSignaler \
signaler::server_url=https://webrtc.ridgerun.com:8443 \
signaler::session_id=1234ridgerun name=web web.audio_src ! rtpopusdepay ! opusdec ! audioconvert ! \
alsasink async=false
When executing the two previous pipelines, you should be able to listen the ticks in the receiving computer.
Bidirectional Element
Example
In this example we use two rrwebrtcbin elements, each sends an audio stream and receives each other audio stream.
Send-Receive Pipeline
The following pipeline will send a white noise audio stream and receive the ticks audio stream sent by the next pipeline. This pipeline starts the call.
gst-launch-1.0 rrwebrtcbin start-call=true signaler=GstOwrSignaler \
signaler::server_url=https://webrtc.ridgerun.com:8443 \
signaler::session_id=1234ridgerun name=web audiotestsrc is-live=true wave=5 ! audioconvert ! \
audioresample ! queue ! opusenc ! rtpopuspay ! web.audio_sink web.audio_src ! rtpopusdepay ! \
opusdec ! audioconvert ! alsasink sync=false async=false
Send-Receive Pipeline
The following pipeline will send ticks audio stream and receive the white noise audio stream sent by the previous pipeline. This pipeline joins the call.
gst-launch-1.0 rrwebrtcbin start-call=false signaler=GstOwrSignaler \
signaler::server_url=https://webrtc.ridgerun.com:8443 \
signaler::session_id=1234ridgerun name=web audiotestsrc is-live=true wave=8 ! audioconvert ! \
audioresample ! queue ! opusenc ! rtpopuspay ! web.audio_sink web.audio_src ! rtpopusdepay ! \
opusdec ! audioconvert ! alsasink sync=false async=false
When executing the two previous pipelines, you should be able to listen the ticks and the white noise.