modulepackage
0.0.0-20220316124037-a531e900c37a
Repository: https://github.com/kuartis/rtp.git
Documentation: pkg.go.dev
# README
Pion RTP
A Go implementation of RTP
Copied Project from:
Pion RTP Project, link is as follows: https://github.com/pion/rtp
Roadmap
The library is used as a part of our WebRTC implementation. Please refer to that roadmap to track our major milestones.
Community
Pion has an active community on the Golang Slack. Sign up and join the #pion channel for discussions and support. You can also use Pion mailing list.
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 [email protected]
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
# Packages
Package codecs implements codec specific RTP payloader/depayloaders.
# Functions
NewAbsSendTimeExtension makes new AbsSendTimeExtension from time.Time.
NewFixedSequencer returns a new sequencer starting from a specific sequence number.
NewPacketizer returns a new instance of a Packetizer for a specific payloader.
NewRandomSequencer returns a new sequencer starting from a random sequence number.
# Structs
AbsSendTimeExtension is a extension payload format in http://www.webrtc.org/experiments/rtp-hdrext/abs-send-time.
AudioLevelExtension is a extension payload format described in https://tools.ietf.org/html/rfc6464
Implementation based on: https://chromium.googlesource.com/external/webrtc/+/e2a017725570ead5946a4ca8235af27470ca0df9/webrtc/modules/rtp_rtcp/source/rtp_header_extensions.cc#49
One byte format: 0 1 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | ID | len=0 |V| level | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Two byte format: 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | ID | len=1 |V| level | 0 (pad) | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+.
Extension RTP Header extension.
Header represents an RTP packet header.
OneByteHeaderExtension is an RFC8285 one-byte header extension.
Packet represents an RTP Packet.
RawExtension represents an RFC3550 header extension.
TransportCCExtension is a extension payload format in https://tools.ietf.org/html/draft-holmer-rmcat-transport-wide-cc-extensions-01 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 0xBE | 0xDE | length=1 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | ID | L=1 |transport-wide sequence number | zero padding | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+.
TwoByteHeaderExtension is an RFC8285 two-byte header extension.
# Interfaces
Depacketizer depacketizes a RTP payload, removing any RTP specific data from the payload.
HeaderExtension represents an RTP extension header.
Packetizer packetizes a payload.
PartitionHeadChecker is the interface that checks whether the packet is keyframe or not.
Payloader payloads a byte array for use as rtp.Packet payloads.
Sequencer generates sequential sequence numbers for building RTP packets.