Categorygithub.com/aliveyun/gortsplib
modulepackage
0.0.0-20230607064056-7860b573d9b7
Repository: https://github.com/aliveyun/gortsplib.git
Documentation: pkg.go.dev

# README

gortsplib

Test Lint Go Report Card CodeCov PkgGoDev

RTSP 1.0 client and server library for the Go programming language, written for MediaMTX.

Go ≥ 1.18 is required.

Features:

  • Client
    • Query servers about available media streams
    • Read
      • Read media streams from servers with the UDP, UDP-multicast or TCP transport protocol
      • Read TLS-encrypted streams (TCP only)
      • Switch transport protocol automatically
      • Read only selected media streams
      • Pause or seek without disconnecting from the server
      • Generate RTCP receiver reports (UDP only)
      • Reorder incoming RTP packets (UDP only)
    • Publish
      • Publish media streams to servers with the UDP or TCP transport protocol
      • Publish TLS-encrypted streams (TCP only)
      • Switch transport protocol automatically
      • Pause without disconnecting from the server
      • Generate RTCP sender reports
  • Server
    • Handle requests from clients
    • Sessions and connections are independent
    • Publish
      • Read media streams from clients with the UDP or TCP transport protocol
      • Read TLS-encrypted streams (TCP only)
      • Generate RTCP receiver reports (UDP only)
      • Reorder incoming RTP packets (UDP only)
    • Read
      • Write media streams to clients with the UDP, UDP-multicast or TCP transport protocol
      • Write TLS-encrypted streams
      • Compute and provide SSRC, RTP-Info to clients
      • Generate RTCP sender reports
  • Utilities
    • Parse RTSP elements
    • Encode/decode format-specific frames into/from RTP packets. The following formats are supported:
      • Video: AV1, VP9, VP8, H265, H264, MPEG-4 Video (H263, Xvid), M-JPEG
      • Audio: Opus, MPEG-4 Audio (AAC), MPEG-2 Audio (MP3), G722, G711 (PCMA, PCMU), LPCM

Table of contents

Examples

API Documentation

https://pkg.go.dev/github.com/aliveyun/gortsplib#pkg-index

Standards

Links

Related projects

# Packages

No description provided by the author
No description provided by the author

# Functions

No description provided by the author
NewServerStream allocates a ServerStream.

# Constants

Log levels.
Log levels.
Log levels.
Log levels.
states.
states.
states.
states.
states.
transport protocols.
transport protocols.
transport protocols.

# Structs

Client is a RTSP client.
Packet stores compressed audio/video data.
No description provided by the author
No description provided by the author
Server is a RTSP server.
ServerConn is a server-side RTSP connection.
ServerHandlerOnAnnounceCtx is the context of OnAnnounce.
ServerHandlerOnConnCloseCtx is the context of OnConnClose.
ServerHandlerOnConnOpenCtx is the context of OnConnOpen.
ServerHandlerOnDecodeErrorCtx is the context of OnDecodeError.
ServerHandlerOnDescribeCtx is the context of OnDescribe.
ServerHandlerOnGetParameterCtx is the context of OnGetParameter.
ServerHandlerOnPacketLostCtx is the context of OnPacketLost.
ServerHandlerOnPauseCtx is the context of OnPause.
ServerHandlerOnPlayCtx is the context of OnPlay.
ServerHandlerOnRecordCtx is the context of OnRecord.
ServerHandlerOnSessionCloseCtx is the context of ServerHandlerOnSessionClose.
ServerHandlerOnSessionOpenCtx is the context OnSessionOpen.
ServerHandlerOnSetParameterCtx is the context of OnSetParameter.
ServerHandlerOnSetupCtx is the context of OnSetup.
ServerHandlerOnWarningCtx is the context of OnWarning.
ServerSession is a server-side RTSP session.
ServerStream represents a data stream.

# Interfaces

No description provided by the author
No description provided by the author
ServerHandler is the interface implemented by all the server handlers.
ServerHandlerOnAnnounce can be implemented by a ServerHandler.
ServerHandlerOnConnClose can be implemented by a ServerHandler.
ServerHandlerOnConnOpen can be implemented by a ServerHandler.
ServerHandlerOnDecodeError can be implemented by a ServerHandler.
ServerHandlerOnDescribe can be implemented by a ServerHandler.
ServerHandlerOnGetParameter can be implemented by a ServerHandler.
ServerHandlerOnPacketLost can be implemented by a ServerHandler.
ServerHandlerOnPause can be implemented by a ServerHandler.
ServerHandlerOnPlay can be implemented by a ServerHandler.
ServerHandlerOnRecord can be implemented by a ServerHandler.
ServerHandlerOnRequest can be implemented by a ServerHandler.
ServerHandlerOnResponse can be implemented by a ServerHandler.
ServerHandlerOnSessionClose can be implemented by a ServerHandler.
ServerHandlerOnSessionOpen can be implemented by a ServerHandler.
ServerHandlerOnSetParameter can be implemented by a ServerHandler.
ServerHandlerOnSetup can be implemented by a ServerHandler.
ServerHandlerOnWarning can be implemented by a ServerHandler.

# Type aliases

ClientLogFunc is the prototype of the log function.
LogLevel is a log level.
ServerSessionState is a state of a ServerSession.
Transport is a RTSP transport protocol.