[libcamera-devel] Unable to copy video sources due to gstreamer erroring out

Nicolas Dufresne nicolas at ndufresne.ca
Mon Jan 16 21:35:08 CET 2023


Hi,

see answer below ...

Le lundi 09 janvier 2023 à 09:12 +0530, Pranav Lal via libcamera-devel a écrit :
> gst-launch-1.0 libcamerasrc
> camera-name="/base/soc/i2c0mux/i2c\@1/imx290\@1a" ! \
> 
>     video/x-raw,width=640,height=480,framerate=30/1,format=NV12 \
> 
>     ! videoconvert ! video/x-raw,format=YUY2 ! queue ! \
> 
>     v4l2sink device=/dev/video25
> 
>  
> 
> 
> Setting pipeline to PAUSED ...
> 
> [8:00:18.743819763] [4414]  INFO Camera camera_manager.cpp:299 libcamera
> v0.0.2+55-5df5b72c                             
> [8:00:18.776776428] [4415]  INFO RPI raspberrypi.cpp:1425 Registered camera
> /base/soc/i2c0mux/i2c at 1/imx290 at 1a to Unicam device /dev/media4 and ISP
> device /dev/media0
> 
> Pipeline is live and does not need PREROLL ...
> 
> Pipeline is PREROLLED ...
> 
> Setting pipeline to PLAYING ...
> 
> New clock: GstSystemClock
> 
> [8:00:18.785127351] [4419]  INFO Camera camera.cpp:1026 configuring streams:
> (0) 640x480-NV12                           
> [8:00:18.785674879] [4415]  INFO RPI raspberrypi.cpp:805 Sensor:
> /base/soc/i2c0mux/i2c at 1/imx290 at 1a - Selected sensor format:
> 1280x720-SRGGB12_1X12 - Selected unicam format: 1280x720-pRCC
> 
> ERROR: from element /GstPipeline:pipeline0/GstLibcameraSrc:libcamerasrc0:
> Internal data stream error.                   
> Additional debug info:
> 
> ../src/gstreamer/gstlibcamerasrc.cpp(312): processRequest ():
> /GstPipeline:pipeline0/GstLibcameraSrc:libcamerasrc0:     
> streaming stopped, reason error (-5)

I notice a bug in libcamerasrc that cause the real error to be hidden.

  GST_ELEMENT_FLOW_ERROR(src_, ret);

If the GST_FLOW_ERROR came from pushing a buffer, we should not post an ERROR to
the bus as this would override the real error. Its up to the downstream element
to post.

Meanwhile, you can probably find what fails by setting GST_DEBUG=2 (warning and
error). Its probably something in v4l2sink that fails (or in v4l2loopback
driver).

regards,
Nicolas

> 
> Execution ended after 0:24:17.264181490
> 
> Setting pipeline to NULL ...
> 
> Freeing pipeline ...



More information about the libcamera-devel mailing list