因此,我在一台覆盆子pi上使用gstreamer从本地网络上的摄像头拉取RTSP流,然后将内容推送到amazon kinesis。视频工作正常,但音频丢失。
但是当它通过拖缆时,音频就会被剥离。在尝试测试它时,我将内容发送到一个带有filesink的文件。文件已创建,但仅包含视频。无音频。
gst-launch-1.0 -e rtspsrc location="rtsp://Test:Test@192.168.1.18/live" short-header=TRUE ! rtph264depay ! video/x-h264, format=avc,alignment=au ! h264parse ! mp4mux ! filesink location=./file.mp4我尝试了一些我在stackoverflow上找到的东西,但它不起作用。当我尝试结束流时,它会无限期地挂起“等待EOS...”当我再次尝试停止它时,它停止了,但输出文件的大小为0。
gst-launch-1.0 -e rtspsrc location="rtsp://Test:Test@192.168.1.18/live" short-header=TRUE ! rtph264depay ! video/x-h264, format=avc,alignment=au ! h264parse ! mp4mux ! filesink location=./file.mp4我尝试启用的实际kinesis命令是这样的。
gst-launch-1.0 rtspsrc location="rtsp://192.168.1.10/live" ! rtph264depay ! h264parse ! kvssink <some additional kinesis parameters>发布于 2021-03-26 09:28:23
终于让它工作了。
这就是在raspberry pi上包含一个音频来源所需的内容。
gst-launch-1.0 rtspsrc name=src location="rtsp://Pass:Word@192.168.1.22/live" short-header=true do-timestamp=true ! rtph264depay ! h264parse ! kvssink name=sink stream-name="name" access-key="key" secret-key="secret aws-region="region" frame-timecodes=false src. ! rtppcmadepay ! alawdec ! audioresample ! audioconvert ! voaacenc ! aacparse ! queue ! sink.https://stackoverflow.com/questions/66534141
复制相似问题