[gst-devel] v4l2 device wrongly captured

Stefan Kost ensonic at hora-obscura.de
Mon Feb 7 16:42:50 CET 2011


On 06.02.2011 00:11, Guido José Valenzano Tocaimasa wrote:
> I have a NTSC camera connected to a BT878 capture device. I configure
> it with:
> $ v4l2-ctl -s ntsc
>
> Then test it with:
> $ gst-launch v4l2src ! xvimagesink
> resulting in an image as the one attached (gstreamer_output.jpg).
>
> However, using:
> $ mplayer tv:// -tv driver=v4l2:norm=0
> works perfectly (mplayer_output.jpg).
>
> Where might be the problem?
>
> I'm running Ubuntu Lucid 10.04 with GStreamer's PPA enabled. I also
> attached result of:
> $ gst-launch -v --gst-debug=v4l2:5 v4l2src device=/dev/video0
> num-buffers=1 ! xvimagesink
> in case it's useful.
>
> Another hint: I *believe* that there was no problem with the older
> GStreamer packages, but can't tell for sure.

>From the log it negotiated to use this format:

Setting format to 768x480, format YUYV
STREAMING, requesting 2 MMAP buffers
caps = video/x-raw-yuv, format=(fourcc)YUY2,
framerate=(fraction)30000/1001, width=(int)768, height=(int)480,
interlaced=(boolean)true

a few days ago the commit below went in - I wonder it it fixes your
issue? Can you try building gst-plugins-good and just install the v4l2
plugin?

Stefan

git show 6b86b56abd8a28b9e94cee679e3d86367a9a0ab3
commit 6b86b56abd8a28b9e94cee679e3d86367a9a0ab3
Author: Mark Nauwelaerts <mark.nauwelaerts at collabora.co.uk>
Date:   Thu Feb 3 23:42:59 2011 +0100

    v4l2: fix interlaced set_format configuration
   
    Commit 6c8268dbfd5c88fac28c882ef2e4598a6522e2d6 broke recording
    from interlaced v4l2 source (e.g. typical tv capture card) since
    V4L2_FIELD_SEQ_TB (with fields stored separately) does not map
    to currently defined interlaced format (fields stored interleaved).
   
    Besides this mismatch, hardware might quite likely not support or
    appreciate this field value, since querying supported formats mapped
    _INTERLACED field formats to interlaced=true caps (so the latter should
    not be mapped to field value that is not known to be supported).
>
>
> Guido
>
> BTW: I really don't know if you received the attachments correctly. In
> case you didn't, please let me know so I can upload them to 4shared,
> megaupload, or similar.
>
>
> ------------------------------------------------------------------------------
> The modern datacenter depends on network connectivity to access resources
> and provide services. The best practices for maximizing a physical server's
> connectivity to a physical network are well understood - see how these
> rules translate into the virtual world? 
> http://p.sf.net/sfu/oracle-sfdevnlfb
>
>
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel





More information about the gstreamer-devel mailing list