mirror of
https://github.com/aler9/gortsplib
synced 2025-10-05 15:16:51 +08:00
44 lines
877 B
Go
44 lines
877 B
Go
package formats //nolint:dupl
|
|
|
|
import (
|
|
"github.com/pion/rtp"
|
|
)
|
|
|
|
// MPEG1Video is a RTP format for a MPEG-1/2 Video codec.
|
|
// Specification: https://datatracker.ietf.org/doc/html/rfc2250
|
|
type MPEG1Video struct{}
|
|
|
|
func (f *MPEG1Video) unmarshal(_ uint8, _ string, _ string, _ string, _ map[string]string) error {
|
|
return nil
|
|
}
|
|
|
|
// Codec implements Format.
|
|
func (f *MPEG1Video) Codec() string {
|
|
return "MPEG-1/2 Video"
|
|
}
|
|
|
|
// ClockRate implements Format.
|
|
func (f *MPEG1Video) ClockRate() int {
|
|
return 90000
|
|
}
|
|
|
|
// PayloadType implements Format.
|
|
func (f *MPEG1Video) PayloadType() uint8 {
|
|
return 32
|
|
}
|
|
|
|
// RTPMap implements Format.
|
|
func (f *MPEG1Video) RTPMap() string {
|
|
return ""
|
|
}
|
|
|
|
// FMTP implements Format.
|
|
func (f *MPEG1Video) FMTP() map[string]string {
|
|
return nil
|
|
}
|
|
|
|
// PTSEqualsDTS implements Format.
|
|
func (f *MPEG1Video) PTSEqualsDTS(*rtp.Packet) bool {
|
|
return true
|
|
}
|