mirror of
https://github.com/m1k1o/neko.git
synced 2024-07-24 14:40:50 +12:00
Wait for keyframe on switching streams (#28)
* stream sink add keyframe lobby. * change streamsink keyframe identifier. * add h264. * use gstreamers is delta unit for sample. * use delta unit.
This commit is contained in:
@ -63,6 +63,18 @@ func (codec *RTPCodec) Register(engine *webrtc.MediaEngine) error {
|
||||
}, codec.Type)
|
||||
}
|
||||
|
||||
func (codec *RTPCodec) IsVideo() bool {
|
||||
return codec.Type == webrtc.RTPCodecTypeVideo
|
||||
}
|
||||
|
||||
func (codec *RTPCodec) IsAudio() bool {
|
||||
return codec.Type == webrtc.RTPCodecTypeAudio
|
||||
}
|
||||
|
||||
func (codec *RTPCodec) String() string {
|
||||
return codec.Type.String() + "/" + codec.Name
|
||||
}
|
||||
|
||||
func VP8() RTPCodec {
|
||||
return RTPCodec{
|
||||
Name: "vp8",
|
||||
|
Reference in New Issue
Block a user