livego icon indicating copy to clipboard operation
livego copied to clipboard

如何在livego 中实现 把rtmp 推流转成 flv存到本地

Open zswDev opened this issue 6 years ago • 3 comments

难道是,推流时 通过 请求 http://localhost:7001/live/xxx.flv, 将这个存到本地吗,能不能在代码上做处理

zswDev avatar Apr 05 '18 16:04 zswDev

参考一下这里:

https://github.com/zhangpeihao/gortmp/blob/master/demo/player/rtmp_player.go

https://github.com/zhangpeihao/goflv

zhyoulun avatar Apr 24 '18 14:04 zhyoulun

@zhyoulun 大佬,你这个 gortmp如何实现连麦呢

zswDev avatar May 07 '18 03:05 zswDev

need this feature + 1

there this a function , but no where to use

var (
	flvHeader = []byte{0x46, 0x4c, 0x56, 0x01, 0x05, 0x00, 0x00, 0x00, 0x09}
	flvFile   = flag.String("filFile", "./out.flv", "output flv file name")
)

func NewFlv(handler av.Handler, info av.Info) {
	patths := strings.SplitN(info.Key, "/", 2)

	if len(patths) != 2 {
		log.Println("invalid info")
		return
	}

fastfading avatar Mar 28 '19 06:03 fastfading