mirror of
				https://github.com/aler9/gortsplib
				synced 2025-10-31 10:36:26 +08:00 
			
		
		
		
	
			
				
					
						
					
					363871d65898b1fdabe98049b44bc8bee93c565e
				
			
			
		
	 aler9
		
	
	363871d658
	
	
	client: support server_port=0-1 (https://github.com/aler9/rtsp-simple-server/issues/407)
			aler9
		
	
	363871d658
	
	
	client: support server_port=0-1 (https://github.com/aler9/rtsp-simple-server/issues/407)
		
	
gortsplib
RTSP 1.0 client and server library for the Go programming language, written for rtsp-simple-server.
Go ≥ 1.14 is required.
Features:
- Client
- Query servers about available streams
- Read
- Read streams from servers with UDP, TCP or TLS (RTSPS)
- Switch protocol automatically (switch to TCP in case of server error or UDP timeout)
- Read only selected tracks of a stream
- Pause or seek without disconnecting from the server
- Generate RTCP receiver reports automatically
 
- Publish
- Publish streams to servers with UDP, TCP or TLS (RTSPS)
- Switch protocol automatically (switch to TCP in case of server error)
- Pause without disconnecting from the server
- Generate RTCP sender reports automatically
 
 
- Server
- Handle requests from clients
- Sessions and connections are independent
- Read streams from clients with UDP, TCP or TLS (RTSPS)
- Write streams to clients with UDP, TCP or TLS (RTSPS)
- Generate RTCP receiver reports automatically
 
- Utilities
- Encode and decode RTSP primitives, RTP/H264, RTP/AAC, SDP
 
Table of contents
Examples
- client-query
- client-read
- client-read-partial
- client-read-options
- client-read-pause
- client-read-h264
- client-publish
- client-publish-options
- client-publish-pause
- server
- server-tls
API Documentation
https://pkg.go.dev/github.com/aler9/gortsplib#pkg-index
Links
Related projects
- https://github.com/aler9/rtsp-simple-server
- https://github.com/pion/sdp (SDP library used internally)
- https://github.com/pion/rtcp (RTCP library used internally)
- https://github.com/pion/rtp (RTP library used internally)
IETF Standards
- RTSP 1.0 https://tools.ietf.org/html/rfc2326
- RTSP 2.0 https://tools.ietf.org/html/rfc7826
- HTTP 1.1 https://tools.ietf.org/html/rfc2616
Conventions
					Languages
				
				
								
								
									Go
								
								99.8%
							
						
							
								
								
									Makefile
								
								0.2%