mirror of
https://github.com/pion/webrtc.git
synced 2025-09-27 03:25:58 +08:00
RTX attribute constants should be public
This commit is contained in:

committed by
cnderrauber

parent
219c6a35ce
commit
d82b0d0a88
10
constants.go
10
constants.go
@@ -39,10 +39,12 @@ const (
|
||||
|
||||
sdesRepairRTPStreamIDURI = "urn:ietf:params:rtp-hdrext:sdes:repaired-rtp-stream-id"
|
||||
|
||||
// Attributes returned when Read() returns an RTX packet from a separate RTX stream (distinct SSRC)
|
||||
attributeRtxPayloadType = "rtx_payload_type"
|
||||
attributeRtxSsrc = "rtx_ssrc"
|
||||
attributeRtxSequenceNumber = "rtx_sequence_number"
|
||||
// AttributeRtxPayloadType is the interceptor attribute added when Read() returns an RTX packet containing the RTX stream payload type
|
||||
AttributeRtxPayloadType = "rtx_payload_type"
|
||||
// AttributeRtxSsrc is the interceptor attribute added when Read() returns an RTX packet containing the RTX stream SSRC
|
||||
AttributeRtxSsrc = "rtx_ssrc"
|
||||
// AttributeRtxSequenceNumber is the interceptor attribute added when Read() returns an RTX packet containing the RTX stream sequence number
|
||||
AttributeRtxSequenceNumber = "rtx_sequence_number"
|
||||
)
|
||||
|
||||
func defaultSrtpProtectionProfiles() []dtls.SRTPProtectionProfile {
|
||||
|
@@ -454,9 +454,9 @@ func (r *RTPReceiver) receiveForRtx(ssrc SSRC, rsid string, streamInfo *intercep
|
||||
continue
|
||||
}
|
||||
|
||||
attributes.Set(attributeRtxPayloadType, b[1]&0x7F)
|
||||
attributes.Set(attributeRtxSequenceNumber, binary.BigEndian.Uint16(b[2:4]))
|
||||
attributes.Set(attributeRtxSsrc, binary.BigEndian.Uint32(b[8:12]))
|
||||
attributes.Set(AttributeRtxPayloadType, b[1]&0x7F)
|
||||
attributes.Set(AttributeRtxSequenceNumber, binary.BigEndian.Uint16(b[2:4]))
|
||||
attributes.Set(AttributeRtxSsrc, binary.BigEndian.Uint32(b[8:12]))
|
||||
|
||||
b[1] = (b[1] & 0x80) | uint8(track.track.PayloadType())
|
||||
b[2] = b[headerLength]
|
||||
|
Reference in New Issue
Block a user