简体   繁体   English

NGINX-RTMP-模块:无法记录

[英]NGINX-RTMP-Module : Can't record

I would like to make a thumbnail of the current stream. 我想对当前视频流做一个缩略图。 According to this post it's possible by using a recorded block. 根据这篇文章,可以通过使用记录的块来实现。

Unfortunatly I cannot make it work. 不幸的是,我无法使其工作。 Nothing happens. 什么都没发生。 Checked error.log nothing in there too. 检查error.log那里什么也没有。 I also tryed to record just in flv but same issue as previously. 我还尝试仅在flv中录制,但与以前相同。

Below is my nginx.conf 以下是我的nginx.conf

Note : The rtmp stream is live (Don't know if that makes a difference) 注意:rtmp流是实时的(不知道是否有所不同)

Note 2 : I used sudo mkdir /usr/local/nginx/var/rec 注意2:我使用了sudo mkdir / usr / local / nginx / var / rec

rtmp {
        server {
                listen 1935;
                chunk_size 4096;

                application live {
                    live on;
                    recorder preview {
                        record keyframes;
                        record_max_frames 4;
                        record_path /var/rec;
                        record_interval 30s;

                        exec_record_done ffmpeg -i rtmp://localhost:7000/live/$name -vcodec png -vframes 1 -an -f rawvideo -s 320x240 -ss 00:00:01 -y /var/rec/test.png;
                    }


            }
        }
}

我认为您错过了record all

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM