mirror of
https://github.com/aler9/gortsplib
synced 2025-10-04 14:52:46 +08:00
client: rename ClientProtocol into ClientTransport
This commit is contained in:
16
client.go
16
client.go
@@ -35,14 +35,14 @@ func DialPublish(address string, tracks Tracks) (*ClientConn, error) {
|
||||
return DefaultClient.DialPublish(address, tracks)
|
||||
}
|
||||
|
||||
// ClientProtocol is a RTSP stream protocol used by the client.
|
||||
type ClientProtocol int
|
||||
// ClientTransport is a stream transport used by the client.
|
||||
type ClientTransport int
|
||||
|
||||
// standard RTSP stream protocols.
|
||||
// standard client transports.
|
||||
const (
|
||||
ClientProtocolUDP ClientProtocol = iota
|
||||
ClientProtocolMulticast
|
||||
ClientProtocolTCP
|
||||
ClientTransportUDP ClientTransport = iota
|
||||
ClientTransportMulticast
|
||||
ClientTransportTCP
|
||||
)
|
||||
|
||||
// Client is a RTSP client.
|
||||
@@ -74,10 +74,10 @@ type Client struct {
|
||||
//
|
||||
// reading / writing
|
||||
//
|
||||
// the stream protocol (UDP, Multicast or TCP).
|
||||
// the stream transport (UDP, Multicast or TCP).
|
||||
// If nil, it is chosen automatically (first UDP, then, if it fails, TCP).
|
||||
// It defaults to nil.
|
||||
Protocol *ClientProtocol
|
||||
Transport *ClientTransport
|
||||
// If the client is reading with UDP, it must receive
|
||||
// at least a packet within this timeout.
|
||||
// It defaults to 3 seconds.
|
||||
|
Reference in New Issue
Block a user