您好,我正在尝试使用and Windows pc的网络摄像头对“实时”视频进行编码和解码。我当前使用的gstreamer版本是1.15.1 对于编码行,我使用:
gst-launch-1.0 ksvideosrc ! \
'video/x-raw, width=640, height=480, framerate=30/1' ! \
videoconvert ! \
x264enc pass=qual quantizer=20 tune=zerolatency ! \
rtph264pay ! \
filesink location=D:\\cam.ts
这会在D驱动器上创建一个文件,但是当尝试对其进行解码时,出现错误。 使用的行:
gst-launch-1.0 filesrc location=D:\\cam.ts ! \
rtph264depay ! \
avdec_h264 ! \
videoconvert ! \
autovideosink sync=false
这是Gstreamer给我的答案
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
ERROR: from element /GstPipeline:pipeline0/GstFileSrc:filesrc0: Internal data stream error.
Additional debug info:
../libs/gst/base/gstbasesrc.c(3064): gst_base_src_loop ():
/GstPipeline:pipeline0/GstFileSrc:filesrc0:
streaming stopped, reason error (-5)
ERROR: pipeline doesn't want to preroll.
Setting pipeline to NULL ...
Freeing pipeline ...