linux c++ ffmpeg rtsp推流报错 rtsp://localhost:8554/Live: Protocol not found

根据报错内容rtsp://localhost:8554/Live: Protocol not found

意思是没有找到对应协议,添加以下红色字体指令解决,

std::string rtsp_server_url = "rtsp://localhost:8554/live";

std::stringstream command;

command << "ffmpeg ";

command << "-y " // overwrite output files

<< "-an " // disable audio

<< "-f rawvideo " // force format to rawvideo

<< "-vcodec rawvideo " // force video rawvideo ('copy' to copy stream)

<< "-pix_fmt bgr24 " // set pixel format to bgr24

<< "-s 640x516 " // set frame size (WxH or abbreviation)

<< "-r 25 "; // set frame rate (Hz value, fraction or abbreviation)

command << "-i - "; //

command << "-c:v libx264 " // Hyper fast Audio and Video encoder

<< "-pix_fmt yuv420p " // set pixel format to yuv420p

<< "-preset ultrafast " // set the libx264 encoding preset to ultrafast

<< "-f flv " // force format to flv

<< "-rtsp_transport tcp "

<< "-f rtsp "

<< rtsp_server_url;

相关推荐
夜颂春秋12 分钟前
jmeter做压力测试
linux·运维·服务器·压力测试
lihui_cbdd4 小时前
AMBER 24 生产环境部署完全指南(5090可用)
linux·计算化学
生活很暖很治愈7 小时前
Linux基础开发工具
linux·服务器·git·vim
u0109272717 小时前
C++中的策略模式变体
开发语言·c++·算法
似霰8 小时前
Linux Shell 脚本编程——核心基础语法
linux·shell
Aevget8 小时前
MFC扩展库BCGControlBar Pro v37.2新版亮点:控件功能进一步升级
c++·mfc·界面控件
Tansmjs9 小时前
C++与GPU计算(CUDA)
开发语言·c++·算法
LUCIFER10 小时前
[驱动进阶——MIPI摄像头驱动(五)]rk3588+OV13855摄像头驱动加载过程详细解析第四部分——ISP驱动
linux·驱动开发
暮云星影10 小时前
四、linux系统 应用开发:UI开发环境配置概述 (一)
linux·ui·arm
挖矿大亨10 小时前
c++中的函数模版
java·c++·算法