Files
lkm/rtmp/rtmp_sink.go
2023-12-01 19:16:52 +08:00

12 lines
421 B
Go

package rtmp
import (
"github.com/yangjiechina/avformat/utils"
"github.com/yangjiechina/live-server/stream"
"net"
)
func NewSink(id stream.SinkId, sourceId string, conn net.Conn) stream.ISink {
return &stream.SinkImpl{Id_: id, SourceId_: sourceId, State_: stream.SessionStateCreate, Protocol_: stream.ProtocolRtmp, Conn: conn, DesiredAudioCodecId_: utils.AVCodecIdNONE, DesiredVideoCodecId_: utils.AVCodecIdNONE}
}