Chinaunix

标题: 关于gstreamer录像管道问题 [打印本页]

作者: 末日使者day    时间: 2016-02-25 17:39
标题: 关于gstreamer录像管道问题
求大神帮帮忙啊,avi存放本地可以实现,但是mp4就有问题了
gst-launch-1.0 v4l2src num-buffers=250 norm=255 ! 'video/x-raw,width=320,height=240,framerate=(fraction)15/1' ! queue ! mux. audiotestsrc num-buffers=440 ! audioconvert ! queue ! faac ! mux. avimux name=mux ! filesink location=test.avi(测试可行)

gst-launch-1.0 v4l2src num-buffers=250 norm=255 ! 'video/x-raw,width=320,height=240,framerate=(fraction)15/1' ! queue ! mux. audiotestsrc num-buffers=440 ! audioconvert ! queue ! faac ! mux. avimux name=mux ! filesink location=test.avi(会报以下两种错误)

设置暂停管道 ...
管道正在使用且不需要 PREROLL ...
设置播放管道 ...
New clock: GstSystemClock
Caught SIGSEGV
Spinning.  Please run 'gdb gst-launch-1.0 9595' to continue debugging, Ctrl-C to quit, or Ctrl-\ to dump core.
错误:来自组件 /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:内部数据流错误。
额外的调试信息:
gstbasesrc.c(2943): gst_base_src_loop (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src0:
streaming task paused, reason not-linked (-1)
Execution ended after 0:00:00.903066825
设置暂停管道 ...
设置备用管道 ...

设置暂停管道 ...
管道正在使用且不需要 PREROLL ...
设置播放管道 ...
New clock: GstSystemClock
错误:来自组件 /GstPipeline:pipeline0/GstV4l2Src:v4l2src1:Device '/dev/video0' is busy
额外的调试信息:
gstv4l2object.c(3224): gst_v4l2_object_set_format_full (): /GstPipeline:pipeline0/GstV4l2Src:v4l2src1:
Call to S_FMT failed for YUYV @ 320x240: 设备或资源忙
Execution ended after 0:00:00.575136508
设置暂停管道 ...
设置备用管道 ...
设置 NULL 管道 ...
释放管道资源 ...
作者: 末日使者day    时间: 2016-02-25 17:48
出错的管道贴错了,sorry

gst-launch-1.0 v4l2src mp4mux name=mux ! filesink location=test.mp4 v4l2src num-buffers=250 norm=255! 'video/x-raw,width=320,height=240,framerate=(fraction)15/1' ! videoconvert ! queue ! x264enc tune="zerolatency" threads=4 ! mux. audiotestsrc num-buffers=440 ! audioconvert ! queue ! faac ! mux.




欢迎光临 Chinaunix (http://bbs.chinaunix.net/) Powered by Discuz! X3.2