mirror of
https://github.com/Monibuca/plugin-record.git
synced 2025-10-05 16:56:53 +08:00
🐛 FIX: 自动录制没有进入当前录制列表中
This commit is contained in:
8
raw.go
8
raw.go
@@ -14,11 +14,17 @@ type RawRecorder struct {
|
||||
Recorder
|
||||
}
|
||||
|
||||
func (r *RawRecorder) Start(streamPath string) error {
|
||||
r.Record = &recordConfig.Raw
|
||||
r.ID = streamPath + "/raw"
|
||||
return plugin.Subscribe(streamPath, r)
|
||||
}
|
||||
|
||||
func (r *RawRecorder) OnEvent(event any) {
|
||||
r.Recorder.OnEvent(event)
|
||||
switch v := event.(type) {
|
||||
case *RawRecorder:
|
||||
go r.Start()
|
||||
go r.start()
|
||||
case *track.Video:
|
||||
if r.Ext == "." {
|
||||
if v.CodecID == codec.CodecID_H264 {
|
||||
|
Reference in New Issue
Block a user