Pure Go implementation of the WebRTC API
Go to file
Pion 5dfbe0808d Update CI configs to v0.6.6
Update lint scripts and CI configs.
2022-02-07 14:43:24 -05:00
.github Update CI configs to v0.6.6 2022-02-07 14:43:24 -05:00
e2e Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
examples Add StandardJS workflow 2022-02-05 22:20:52 -05:00
internal Improved h264 fmtp line parsing 2021-07-30 13:23:07 -04:00
pkg Fix media WriteRTP with empty RTP packet 2021-10-27 10:03:11 -04:00
test-wasm Add StandardJS workflow 2022-02-05 22:20:52 -05:00
.codacy.yaml Mass replace pions -> pion 2019-04-04 15:32:03 -07:00
.eslintrc.json Add eslintrc for codacy 2018-08-11 13:56:28 -07:00
.gitignore Fix OpusWriter issues that break VLC 2019-08-15 17:12:01 -07:00
.golangci.yml Update CI configs to v0.4.12 2020-11-06 20:33:59 -08:00
api_js.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
api_test.go Improve API nil handling 2022-01-30 20:19:35 -05:00
api.go Improve API nil handling 2022-01-30 20:19:35 -05:00
atomicbool.go Add swap function to atomicBool 2021-11-20 13:44:43 -05:00
AUTHORS.txt Remove ICETransportStateNew check in DTLS Start 2022-02-03 14:49:05 -05:00
bundlepolicy_test.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
bundlepolicy.go JSON marshalling/unmarshalling for Configuration 2020-12-29 22:02:42 -08:00
certificate_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
certificate.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
codecov.yml Update CI configs to v0.3.3 2020-07-15 14:22:42 +09:00
configuration_common.go Copy ICEServers when creating new PeerConnection 2020-06-10 00:16:43 -07:00
configuration_js.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
configuration_test.go JSON marshalling/unmarshalling for Configuration 2020-12-29 22:02:42 -08:00
configuration.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
constants.go Handle Simulcast RepairStream 2021-09-15 15:08:22 -04:00
datachannel_go_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
datachannel_js_detach.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
datachannel_js.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
datachannel_test.go Add test for negotiated DataChannel.OnOpen 2021-11-03 13:50:06 -04:00
datachannel.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
datachannelinit.go Remove RTCDataChannel priority 2019-09-26 15:44:19 -07:00
datachannelmessage.go Add JavaScript/WASM bindings 2019-03-08 00:26:17 +01:00
datachannelparameters.go Properly generate DataChannel streamId 2019-11-14 10:51:05 -08:00
datachannelstate_test.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
datachannelstate.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
DESIGN.md Fix a typo in DESIGN.md 2020-07-17 10:36:18 -07:00
dtlsfingerprint.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
dtlsparameters.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
dtlsrole_test.go Move candidate parsing to pion/ice 2020-09-13 00:05:09 -07:00
dtlsrole.go Move candidate parsing to pion/ice 2020-09-13 00:05:09 -07:00
dtlstransport_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
dtlstransport.go DTLS retransmission interval setting 2022-02-07 22:57:31 +05:30
dtlstransportstate_test.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
dtlstransportstate.go Various spell fixes 2019-10-17 23:31:21 -07:00
errors.go Fix RTPSender.Send crash 2022-01-07 10:46:18 -05:00
gathering_complete_promise.go Fix a race condition in GatheringCompletePromise 2020-12-22 20:19:42 -08:00
go.mod Update DTLS to v2.1.2 2022-02-05 12:49:51 +05:30
go.sum Update DTLS to v2.1.2 2022-02-05 12:49:51 +05:30
ice_go.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
icecandidate_test.go Update CI configs to v0.4.7 2020-09-30 09:06:34 -07:00
icecandidate.go Update CI configs to v0.4.7 2020-09-30 09:06:34 -07:00
icecandidateinit_test.go Don't use omitempty for ICECandidateInit 2020-08-20 20:56:35 -07:00
icecandidateinit.go Don't use omitempty for ICECandidateInit 2020-08-20 20:56:35 -07:00
icecandidatepair.go Basic stats 2019-06-25 19:36:57 +00:00
icecandidatetype_test.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icecandidatetype.go Update CI configs to v0.4.7 2020-09-30 09:06:34 -07:00
icecomponent_test.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icecomponent.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
iceconnectionstate_test.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
iceconnectionstate.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icecredentialtype_test.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icecredentialtype.go Make PeerConnection constructor with WebIDL errors 2020-08-21 07:00:28 -07:00
icegatherer_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
icegatherer.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
icegathererstate_test.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icegathererstate.go Fix ICEGatherer state change callback order 2020-03-10 16:32:44 +09:00
icegatheringstate_test.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icegatheringstate.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icegatheroptions.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icemux.go UDPMuxParams use net.PacketConn instead of UDPConn 2021-10-26 14:54:57 -04:00
iceparameters.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
iceprotocol_test.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
iceprotocol.go Update CI configs to v0.4.7 2020-09-30 09:06:34 -07:00
icerole_test.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icerole.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
iceserver_js.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
iceserver_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
iceserver.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
icetransport_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
icetransport.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
icetransportpolicy_test.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
icetransportpolicy.go JSON marshalling/unmarshalling for Configuration 2020-12-29 22:02:42 -08:00
icetransportstate_test.go Move to pion/ice@v2 2020-06-28 00:01:47 -07:00
icetransportstate.go Move to pion/ice@v2 2020-06-28 00:01:47 -07:00
interceptor_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
interceptor.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
js_utils.go Update CI configs to v0.6.6 2022-02-07 14:43:24 -05:00
LICENSE Initial commit 2018-05-18 16:10:05 -07:00
mediaengine_test.go Add test for 65b517 2022-02-01 19:03:00 -05:00
mediaengine.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
networktype_test.go Populate network types from config 2020-04-15 21:42:31 +03:00
networktype.go Update CI configs to v0.4.7 2020-09-30 09:06:34 -07:00
oauthcredential.go Move ICE code out of internal 2019-06-15 01:29:08 -07:00
offeransweroptions.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
operations_test.go Revert "Read/Write RTP/RTCP packets with context" 2020-12-02 20:11:06 -08:00
operations.go Fix operations queue memory leak 2021-06-30 20:58:33 -04:00
ortc_datachannel_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
ortc_media_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
ortc_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
package.json Update dependency wrtc to v0.4.7 2021-01-14 13:07:47 -08:00
peerconnection_close_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
peerconnection_go_test.go Use ICE role to set DTLS role in answer 2022-02-02 12:33:59 -05:00
peerconnection_js_test.go Move candidate parsing to pion/ice 2020-09-13 00:05:09 -07:00
peerconnection_js.go Update all examples with copySessionDescription 2022-02-05 13:41:44 -05:00
peerconnection_media_test.go Add test for 65b517 2022-02-01 19:03:00 -05:00
peerconnection_renegotiation_test.go Add test for 65b517 2022-02-01 19:03:00 -05:00
peerconnection_test.go Move Simulcast SDP Modification into helper 2021-08-29 20:54:44 -04:00
peerconnection.go Use ICE role to set DTLS role in answer 2022-02-02 12:33:59 -05:00
peerconnectionstate_test.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
peerconnectionstate.go Implement OnNegotiationNeeded 2020-08-19 14:37:18 -05:00
README.md Remove 'New Release' Section 2021-09-23 12:17:06 -04:00
renovate.json Update CI configs to v0.6.0 2021-11-15 22:44:20 -05:00
rtcpfeedback.go Update CI configs to v0.4.7 2020-09-30 09:06:34 -07:00
rtcpmuxpolicy_test.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
rtcpmuxpolicy.go JSON marshalling/unmarshalling for Configuration 2020-12-29 22:02:42 -08:00
rtpcapabilities.go Allow extensions to be configured with direction 2020-12-04 11:52:48 -08:00
rtpcodec.go Improved h264 fmtp line parsing 2021-07-30 13:23:07 -04:00
rtpcodingparameters.go Handle non-Simulcast Repair Streams 2021-10-04 22:08:27 -04:00
rtpdecodingparameters.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
rtpencodingparameters.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
rtpreceiveparameters.go Add Simulcast support 2020-07-24 01:01:43 -07:00
rtpreceiver_go_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
rtpreceiver_go.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
rtpreceiver_js.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
rtpreceiver_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
rtpreceiver.go Set up RTP Receivers synchronously 2022-01-17 14:57:24 -05:00
rtpsender_js.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
rtpsender_test.go Add ability to set RTP stream ID on TrackLocal 2022-01-14 12:37:06 -05:00
rtpsender.go Add ability to set RTP stream ID on TrackLocal 2022-01-14 12:37:06 -05:00
rtpsendparameters.go Fix RTPSendParameters 2020-12-05 23:02:27 -08:00
rtptransceiver_js.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
rtptransceiver_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
rtptransceiver.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
rtptransceiverdirection_test.go Remove RTCDataChannel priority 2019-09-26 15:44:19 -07:00
rtptransceiverdirection.go Allow extensions to be configured with direction 2020-12-04 11:52:48 -08:00
rtptransceiverinit.go New Track API 2020-11-15 09:20:47 -08:00
sctpcapabilities.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
sctptransport_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
sctptransport.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
sctptransportstate_test.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
sctptransportstate.go Remove rtc prefix from filenames 2019-02-17 16:22:56 -08:00
sdp_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
sdp.go Use ICE role to set DTLS role in answer 2022-02-02 12:33:59 -05:00
sdpsemantics_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
sdpsemantics.go JSON marshalling/unmarshalling for Configuration 2020-12-29 22:02:42 -08:00
sdptype_test.go Expose NewSDPType 2021-01-09 14:51:22 -08:00
sdptype.go Expose NewSDPType 2021-01-09 14:51:22 -08:00
sessiondescription_test.go Don't cache SessionDescription during unmarshal 2021-02-16 12:43:11 -08:00
sessiondescription.go Don't cache SessionDescription during unmarshal 2021-02-16 12:43:11 -08:00
settingengine_js.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
settingengine_test.go DTLS retransmission interval setting 2022-02-07 22:57:31 +05:30
settingengine.go DTLS retransmission interval setting 2022-02-07 22:57:31 +05:30
signalingstate_test.go Update CI configs to v0.4.7 2020-09-30 09:06:34 -07:00
signalingstate.go Update CI configs to v0.4.7 2020-09-30 09:06:34 -07:00
srtp_writer_future.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
stats_go_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
stats_go.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
stats.go New Track API 2020-11-15 09:20:47 -08:00
track_local_static_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
track_local_static.go Add ability to set RTP stream ID on TrackLocal 2022-01-14 12:37:06 -05:00
track_local.go Add ability to set RTP stream ID on TrackLocal 2022-01-14 12:37:06 -05:00
track_remote.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
track_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
vnet_test.go Run gofmt to add new build constraints 2022-01-17 22:36:01 -05:00
webrtc.go Fix Simulcast routine leak 2020-12-07 09:18:15 -08:00
yarn.lock Update dependency wrtc to v0.4.7 2021-01-14 13:07:47 -08:00

Pion WebRTC
Pion WebRTC

A pure Go implementation of the WebRTC API

Pion webrtc Sourcegraph Widget Slack Widget Twitter Widget
Build Status PkgGoDev Coverage Status Go Report Card Codacy Badge License: MIT


Usage

Go Modules are mandatory for using Pion WebRTC. So make sure you set export GO111MODULE=on, and explicitly specify /v2 or /v3 when importing.

example applications contains code samples of common things people build with Pion WebRTC.

example-webrtc-applications contains more full featured examples that use 3rd party libraries.

awesome-pion contains projects that have used Pion, and serve as real world examples of usage.

GoDoc is an auto generated API reference. All our Public APIs are commented.

FAQ has answers to common questions. If you have a question not covered please ask in Slack we are always looking to expand it.

Now go build something awesome! Here are some ideas to get your creative juices flowing:

  • Send a video file to multiple browser in real time for perfectly synchronized movie watching.
  • Send a webcam on an embedded device to your browser with no additional server required!
  • Securely send data between two servers, without using pub/sub.
  • Record your webcam and do special effects server side.
  • Build a conferencing application that processes audio/video and make decisions off of it.
  • Remotely control a robots and stream its cameras in realtime.

Want to learn more about WebRTC?

Join our Office Hours. Come hang out, ask questions, get help debugging and hear about the cool things being built with WebRTC. We also start every meeting with basic project planning.

Check out WebRTC for the Curious. A book about WebRTC in depth, not just about the APIs. Learn the full details of ICE, SCTP, DTLS, SRTP, and how they work together to make up the WebRTC stack.

This is also a great resource if you are trying to debug. Learn the tools of the trade and how to approach WebRTC issues.

This book is vendor agnostic and will not have any Pion specific information.

Features

PeerConnection API

  • Go implementation of webrtc-pc and webrtc-stats
  • DataChannels
  • Send/Receive audio and video
  • Renegotiation
  • Plan-B and Unified Plan
  • SettingEngine for Pion specific extensions

Connectivity

  • Full ICE Agent
  • ICE Restart
  • Trickle ICE
  • STUN
  • TURN (UDP, TCP, DTLS and TLS)
  • mDNS candidates

DataChannels

  • Ordered/Unordered
  • Lossy/Lossless

Media

Security

  • TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 and TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA for DTLS v1.2
  • SRTP_AEAD_AES_256_GCM and SRTP_AES128_CM_HMAC_SHA1_80 for SRTP
  • Hardware acceleration available for GCM suites

Pure Go

  • No Cgo usage
  • Wide platform support
    • Windows, macOS, Linux, FreeBSD
    • iOS, Android
    • WASM see examples
    • 386, amd64, arm, mips, ppc64
  • Easy to build Numbers generated on Intel(R) Core(TM) i5-2520M CPU @ 2.50GHz
    • Time to build examples/play-from-disk - 0.66s user 0.20s system 306% cpu 0.279 total
    • Time to run entire test suite - 25.60s user 9.40s system 45% cpu 1:16.69 total
  • Tools to measure performance provided

Roadmap

The library is in active development, please refer to the roadmap to track our major milestones. We also maintain a list of Big Ideas these are things we want to build but don't have a clear plan or the resources yet. If you are looking to get involved this is a great place to get started! We would also love to hear your ideas! Even if you can't implement it yourself, it could inspire others.

Community

Pion has an active community on the Slack.

Follow the Pion Twitter for project updates and important WebRTC news.

We are always looking to support your projects. Please reach out if you have something to build! If you need commercial support or don't want to use public methods you can contact us at team@pion.ly

Contributing

Check out the contributing wiki to join the group of amazing people making this project possible:

License

MIT License - see LICENSE for full text