feat: rtmp add pb

This commit is contained in:
langhuihui
2024-04-18 20:40:19 +08:00
parent f4eab4cf51
commit 788923749e
33 changed files with 990 additions and 59 deletions

13
plugin/rtmp/api.go Normal file
View File

@@ -0,0 +1,13 @@
package plugin_rtmp
import (
"context"
"m7s.live/m7s/v5/plugin/rtmp/pb"
rtmp "m7s.live/m7s/v5/plugin/rtmp/pkg"
)
func (r *RTMPPlugin) PushOut(ctx context.Context, req *pb.PushRequest) (res *pb.PushResponse, err error) {
go r.Push(req.StreamPath, req.RemoteURL, &rtmp.Client{})
return &pb.PushResponse{}, nil
}