Commit Graph

2053 Commits

Author SHA1 Message Date
Renovate Bot
980a56db73 Update module github.com/pion/interceptor to v0.1.6
Generated by renovateBot
v3.1.17
2022-01-19 13:06:04 -05:00
Sean DuBois
157220e800 Run gofmt to add new build constraints
Also remove some 1.13 specific WASM code
2022-01-17 22:36:01 -05:00
boks1971
04ca4493f6 Set up RTP Receivers synchronously
Do the set up of RTP receivers synchronously so that they
are ready to receive media as soon as signalling to remote
side is sent. Once signalling to remote side is sent, the
remote can send media at any time and receiver has to be ready.

Like the bug mentions, a negotiation quickly followed by
a renegotiation left the RTP receivers of the tracks in the
second offer not set up. If the tracks in the renegotiation
happen to be simulcast tracks, they are missed as browsers
send RID only in the first few packets.

The problem can be reproduced by introducing a 1 second
delay in Downstream direction in Network Link Conditioner
and using a modified version of LiveKit JS SDK sample app to
force a double negotiation spaced closely.

With this change, onTrack fires, but the unhandled warning
from RTCP for the highest layer still happens. But, the
track fires almost immediately following that warning
(less than 5 ms later). So, all the simulcast layers
are available.

Resolves #2054
v3.1.16
2022-01-17 14:57:24 -05:00
Kevin Wang
f644649329 Add ability to set RTP stream ID on TrackLocal
This change makes it possible to set the RTP stream ID to
allow forwarding and production of simulcast streams.
v3.1.15
2022-01-14 12:37:06 -05:00
Kevin Wang
7004fbb766 Add H265 and AV1 MimeTypes
This change adds constants for H265 and AV1. Neither are fully
supported in pion, however these constants are still useful and we will
likely send a change to add H265 and AV1 packetizer/depacketizers in
the future.
2022-01-12 11:09:02 -05:00
Renovate Bot
585702f23d Update module github.com/pion/dtls/v2 to v2.1.0
Generated by renovateBot
2022-01-11 22:33:19 +00:00
juberti
be49dbc5cb Use audio negotiated PTs before video builtin PTs
This avoids a bug where negotiating Opus with PT 96 in an audio-only
session results in the VP8 codec being picked for a track (because
96 is the built-in type for VP8).
v3.1.14
2022-01-11 15:17:14 -05:00
Len
d4b645635c Fix RTPSender.Send crash
If PeerConnection removes track while RTPSender is
created and being negotiated, RTPSender.Send would
access nil pointer. Check If track is nil.

Relates to #2065
2022-01-07 10:46:18 -05:00
cnderrauber
dd9d4c503c Make setMid of Transceiver public
in some case like session migration from one sfu node
to another, we need manual set mid of transceiver instead of
auto generate, to make mid consistent between to sfu node.
2022-01-06 22:06:18 +08:00
Renovate Bot
d2cc00dc40 Update golang.org/x/net commit hash to fe4d628
Generated by renovateBot
2022-01-01 02:42:21 +00:00
Sean DuBois
fe447d6e56 Revert "Process RTCP Packets in OnTrack examples"
This is not needed. We don't perform any operations on inbound RTCP
packets. Receiver Reports and TWCC are generated by Reading RTP packets.

This reverts commit 080d7b8427.
v3.1.13
2021-12-29 23:39:32 -05:00
Len
425f5c6cef Handle implicitly created inactive transceiver
If SetRemoteDescription is called with offer SDP which
has a=invalid, PeerConnection sets its transceiver direction
as recvonly. Fix direction recvonly to invalid.

Resolves #2050
2021-12-28 20:22:36 -05:00
Sean DuBois
8c31eb98dd Remove examples that aren't unique
data-channels-close demonstrates that you are able to close a
DataChannel. Closing a DataChannel isn't exercising any unique
behaviors. I don't believe it will help users discover anything new or
prevent them from making mistakes.

data-channels-(detach)-create demonstrates creating a DataChannel in Go.
We have a 1:1 mapping with the browser so I think this is expected. We
also have other examples demonstrate this behavior.
2021-12-27 14:39:48 -05:00
Sean DuBois
26ce88e87a Fix RTPSender.GetParameters crash
If a RTPSender doesn't have a track currently set and GetParameters is
called we would call a method on a nil pointer. Now instead of checking
the Track kind we store the kind in the RTPSender.

Resolves #2065
v3.1.12
2021-12-26 22:50:52 -05:00
Renovate Bot
83eb2acc6e Update module github.com/pion/ice/v2 to v2.1.18
Generated by renovateBot
2021-12-26 08:31:15 +00:00
Ali Error
3440d05501 Update rtp-forwarder ffplay arguments
adding low_delay and framedrop flags as well as Stackoverflow
question link @Sean-Der sent on Slack
2021-12-23 22:37:32 -05:00
Pion
98df5e4d1c Update CI configs to v0.6.4
Update lint scripts and CI configs.
2021-12-20 00:38:43 -05:00
Sean DuBois
080d7b8427 Process RTCP Packets in OnTrack examples
TWCC and Receiver Reports are needed for a good default experience
2021-12-17 12:03:39 -05:00
Renovate Bot
b8489a8f7e Update module github.com/pion/dtls/v2 to v2.0.13
Generated by renovateBot
2021-12-16 17:30:26 +00:00
Renovate Bot
517a32639a Update module github.com/pion/ice/v2 to v2.1.17
Generated by renovateBot
2021-12-16 09:15:32 +00:00
Renovate Bot
0c8f98cca0 Update module github.com/pion/sctp to v1.8.2
Generated by renovateBot
2021-12-16 00:55:04 +00:00
Sean DuBois
6160e8033f Handle unknown ICE Candidate Transport
rfc8839#section-5.1 specifies that a WebRTC Agent MUST
ignore any name/value pairs it doesn't understand. When
we parse a candidate and it fails because we don't understand
the type we now log and continue.

Resolves pion/webrtc#1949
2021-12-15 15:58:48 -05:00
Sean DuBois
2699584e9a Handle unknown ICE Candidate Type
rfc8839#section-5.1 specifies that a WebRTC Agent MUST
ignore any name/value pairs it doesn't understand. When
we parse a candidate and it fails because we don't understand
the type we now log and continue.

Resolves pion/webrtc#1949
2021-12-15 13:37:34 -05:00
Sean DuBois
8a10f67d5a Better error message on SDPSemantics mismatch
Tell user what RemoteDescription was detected as, and what was expected

Resolves #2011
2021-12-12 23:09:23 -05:00
Renovate Bot
11c4810845 Update module github.com/pion/interceptor to v0.1.4
Generated by renovateBot
2021-12-11 21:34:03 -05:00
Renovate Bot
2f7fcae945 Update module github.com/pion/dtls/v2 to v2.0.12
Generated by renovateBot
2021-12-10 11:15:46 +00:00
Renovate Bot
e62c85ca07 Update module github.com/pion/dtls/v2 to v2.0.11
Generated by renovateBot
2021-12-08 10:05:26 +00:00
Renovate Bot
d461ef97f7 Update golang.org/x/net commit hash to 0a0e4e1
Generated by renovateBot
2021-12-01 21:43:26 +00:00
Renovate Bot
03e975a312 Update golang.org/x/net commit hash to d83791d
Generated by renovateBot
2021-11-30 20:43:13 -05:00
Sean DuBois
19b78a0953 Fix typo in rtp-to-webrtc README
VP8 -> H264
2021-11-30 10:10:39 -05:00
Pion
d8dde5b459 Update CI configs to v0.6.2
Update lint scripts and CI configs.
2021-11-28 14:07:45 -05:00
Sean DuBois
31b801702e Use assert in SDPSemantics tests
Relates to #2011
2021-11-28 13:11:24 -05:00
Renovate Bot
a27f28e039 Update module github.com/pion/interceptor to v0.1.2
Generated by renovateBot
v3.1.11
2021-11-23 13:54:24 -05:00
Sean DuBois
0e0c4a2ab9 Add examples/trickle-ice
Resolves #2030
2021-11-21 15:25:28 -05:00
Sean DuBois
fa72a9529f Add examples/rtcp-processing
rtcp-processing demonstrates how to access RTCP Packets via ReadRTCP

Resolves #2027
2021-11-20 22:06:03 -05:00
brian
883973804d Add swap function to atomicBool
PeerConnection setting to closed was not an atomic operation before
2021-11-20 13:44:43 -05:00
Sean DuBois
97bca5ce35 Update example documentation
README didn't contain lines for multiple examples
2021-11-20 13:33:54 -05:00
Sean DuBois
4a0e5e0231 Fix Fingerprint Verification disablement
Early return caused DTLSTransport to not be properly initialized and
broke offline-browser-communication demo
v3.1.10
2021-11-19 21:50:18 -05:00
Renovate Bot
f444ff5b0e Update module github.com/pion/rtcp to v1.2.9
Generated by renovateBot
2021-11-19 08:33:34 +00:00
Renovate Bot
99452111ba Update module github.com/pion/ice/v2 to v2.1.14
Generated by renovateBot
2021-11-16 12:55:40 -05:00
Pion
32ebc9dfe9 Update CI configs to v0.6.0
Update lint scripts and CI configs.
2021-11-15 22:44:20 -05:00
Sean DuBois
e2af355047 Take lock when getting DataChannel ID
Resolves #2023
2021-11-15 13:28:58 -05:00
Sean DuBois
4785c30a2a Add H264 instructions to rtp-to-webrtc
Resolves #2021
2021-11-15 13:00:05 -05:00
cnderrauber
635bfd9cad Set prefer codec created by remote sdp
If a transceiver is created by remote sdp, then set
prefer codec same as offer peer.
For pion's codec match, it will use exact match
first, and then partial match. If patial match
only, the partial match codecs will become
negotiated codes. So it will be set prefer codec
when only exist partial match. And has same payload.

Add test cast for this.

refer to https://www.w3.org/TR/webrtc/#bib-rfc8829
v3.1.9
2021-11-12 14:05:33 +08:00
David Zhao
5f6baf7325 Fixed locking order in SRTP and DataChannel
Two separate potential deadlocks

1. typically the locking order is SRTP first, then DataChannel.
   However, when data channel is opened, it's locking srtp when
   generating an ID.
   It also would return without unlocking when an error is encountered
2. recursive RLock could be potentially problematic. MediaEngine
   contained a section doing so.
2021-11-11 13:06:19 -08:00
Renovate Bot
789db38eda Update module github.com/pion/datachannel to v1.5.2
Generated by renovateBot
2021-11-11 15:43:22 -05:00
Sean DuBois
1705641fa4 Open all DataChannels before accepting remote
A race existed with Negotiated DataChannels before this. Before
the remote could sends us a DataChannel message before the
datachannel was negotiated locally. We would then discard the
message and print an error.

This PR moves the processing of remote datachannel messages after
we have registered all local ones. It also informs
datachannel.Accept of existing datachannels in order to prevent
any initialization logic from proceeding incorrectly.
v3.1.8
2021-11-09 10:51:14 -05:00
Eric Daniels
c2e8c97f2d Add test for negotiated DataChannel.OnOpen
5dc7245 was missing a test for this
2021-11-03 13:50:06 -04:00
Eric Daniels
5dc7245bee Fire DataChannel.onOpen when already negotiated
Fix regression from 0180ee. Before Datachannels would always fire
OnOpen. Now they only fire when DCEP ACK is received. This caused
OnOpen to not be fired for negotiated channels. This re-enables
the previous behavior of firing OnOpen for negotiated channels.
v3.1.7
2021-11-01 12:23:37 -04:00
Artur Shellunts
979aefd702 Update jsfiddle in play-from-disk
Add 'copy browser Session Description to clipboard'. This makes it
easier to copy the Session Description. Before users would accidentally
not copy the entire value
2021-10-30 13:58:57 +02:00