出现 unref 短路故障且共置 POC 不可用
command = ['ffmpeg',
'-y',
'-f', 'rawvideo',
'-vcodec', 'rawvideo',
'-pix_fmt', 'bgr24',
'-s', "{}x{}".format(width, height),
# '-framerate', '5',
'-r', str(fps),
'-i', '-',
'-c:v', 'libx264',
'-pix_fmt', 'yuv420p',
'-preset', 'ultrafast',
'-f', 'flv',
'-flvflags', 'no_duration_filesize',
rtmp_live_url]
piped_process = subprocess.Popen(command, stdin=subprocess.PIPE)
piped_process_new.stdin.write(frame.tostring())
使用上述命令将帧从 opencv 发送到特定的 rtmp url。