我想将 m3u8 流摄取到 kinesis 视频(MKV 格式)。我编译了 kvssink 插件,但 gstreamer 失败并出现未知错误。
也许我需要在发送到 kvssink 之前以某种方式转换流?有人可以评论这一点吗?
命令:
gst-launch-1.0 souphttpsrc location=http://devimages.apple.com/iphone/samples/bipbop/gear4/prog_index.m3u8 ! hlsdemux ! video/x-h264, format=avc,alignment=au ! h264parse ! kvssink stream-name="my-stream" storage-size=128 access-key="<key>" secret-key="<secret>"
错误
Stream is ready
Pipeline is live and does not need PREROLL ...
Got context from element 'souphttpsrc0': gst.soup.session=context, session=(SoupSession)NULL, force=(boolean)false;
Setting pipeline to PLAYING ...
New clock: GstSystemClock
ERROR: from element /GstPipeline:pipeline0/GstHLSDemux:hlsdemux0: Internal data stream error.
Additional debug info:
gstadaptivedemux.c(2531): _src_chain (): /GstPipeline:pipeline0/GstHLSDemux:hlsdemux0:
streaming stopped, reason not-negotiated (-4)
[INFO ] [05-04-2020 10:44:30:735.727 GMT] stopKinesisVideoStreamSync(): Synchronously stopping Kinesis Video Stream 000055d1f527ef50.
更新
经过小的更改后,它现在可以与 fakesink 一起使用,但仍然会出现 kvssink 错误
gst-launch-1.0 souphttpsrc location=http://devimages.apple.com/iphone/samples/bipbop/gear4/prog_index.m3u8 ! hlsdemux ! tsdemux ! queue ! video/x-h264 ! h264parse ! kvssink stream-name="my-stream" storage-size=128 access-key="<key>" secret-key="<secret>"
错误
[ERROR] [05-04-2020 18:33:57:145.773 GMT] Failed to get the size of the buffer for hex decoding the codec private data with: 3
ERROR: from element /GstPipeline:pipeline0/GstKvsSink:kvssink0: GStreamer encountered a general stream error.
Additional debug info:
/home/ubuntu/amazon-kinesis-video-streams-producer-sdk-cpp/kinesis-video-gstreamer-plugin/src/gstkvssink.cpp(947): gst_kvs_sink_handle_sink_event (): /GstPipeline:pipeline0/GstKvsSink:kvssink0: