From 269fb472e92923d75343f4866dc2b676e4c10fc0 Mon Sep 17 00:00:00 2001 From: langhuihui <178529795@qq.com> Date: Fri, 2 Aug 2024 11:34:04 +0800 Subject: [PATCH] feat: add meta data into flv download file --- pull.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pull.go b/pull.go index cdf7f57..4bf2df5 100644 --- a/pull.go +++ b/pull.go @@ -115,7 +115,11 @@ func (puller *HDLPuller) Pull() (err error) { puller.WriteAVCCVideo(puller.absTS, &frame, puller.pool) } case codec.FLV_TAG_TYPE_SCRIPT: - puller.Info("script", zap.ByteString("data", mem.Value)) + var amf util.AMF + amf.Buffer = mem.Value + obj, _ := amf.Unmarshal() + obj, err = amf.Unmarshal() + puller.Info("script", zap.Any("meta", obj)) frame.Recycle() } }