[Bug 775564] New: v4l2 1.10 Regression: white pixels with camera on Raspberry Pi & gstgl

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Sat Dec 3 10:26:04 UTC 2016


https://bugzilla.gnome.org/show_bug.cgi?id=775564

            Bug ID: 775564
           Summary: v4l2 1.10 Regression: white pixels with camera on
                    Raspberry Pi & gstgl
    Classification: Platform
           Product: GStreamer
           Version: 1.10.x
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: Normal
         Component: gst-plugins-good
          Assignee: gstreamer-bugs at lists.freedesktop.org
          Reporter: gottfried.haider at gmail.com
        QA Contact: gstreamer-bugs at lists.freedesktop.org
     GNOME version: ---

We're seeing a regression on the Raspberry Pi (w/ the vc4 GLES2 driver) between
version 1.8.3. and 1.10.1, but I believe I saw the same issue already in a
1.9.x build. With the new version, retrieving a GL texture from the Raspberry
Pi camera only shows a white rectangle, while the same code worked before. The
camera is accessed using the bcm2835-v4l2 driver, and instantiated using
gst_device_create_element.

All other functionality (playback etc) seem to work just fine. Our JNI library
was compiled against 1.10.1 headers.

The pipeline is something like this: v4l2src ! capsfilter [here just:
video/x-raw] ! glupload ! glcolorconvert ! capsfilter
[video/x-raw(memory:GLMemory),format=RGBA,texture-target=2D] ! fakesink

The negotiated caps between 1.8.3 and 1.10.1 look the same (just the order is
slightly different): video/x-raw(memory:GLMemory), width=(int)320,
height=(int)200, framerate=(fraction)90/1, format=(string)RGBA,
pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive,
texture-target=(string)2D


To reproduce:

1. Download
https://github.com/processing/processing/releases/download/processing-0255-3.2.3/processing-3.2.3-linux-raspbian.zip
2. Unpack and write the image onto an SD card
3. Connect a CSI camera to the Raspberry Pi
4. Boot the prepared SD card
5. Launch Processing via the "Development" menu
6. In Processing: File > Examples... > Contributed Libraries > GL Video >
SimpleCapture
7. Hit play

This will yield a working display of the camera image. The GStreamer version
bundled is 1.8.3.

8. Quit Processing
9. Remove ~/sketchbook/libraries/glvideo
10. Download
http://sukzessiv.net/~gohai/gstreamer/processing-glvideo-1.10.1.zip
11. Unpack into ~/sketchbook/libraries
12. Launch Processing again
13. In Processing: File > Examples... > Contributed Libraries > GL Video >
SimpleCapture
14. Hit play

This will result in a white rectangle being displayed. No apparent error
messages in the console.


Source:

The gist of the JNI code can be found here:
https://github.com/gohai/processing-glvideo/blob/wip-gstreamer-1.10/src/native/impl.c

The call-chain for camera playback:
* Java_gohai_glvideo_GLVideo_gstreamer_1openDevice
** calls getDeviceSrcElement, which calls gst_device_create_element
** calls createGlPipeline, which calls init_device_player to set up the
pipeline
* the handle_buffer function is called through callbacks to retrieve the
texture id
* the Java_gohai_glvideo_GLVideo_gstreamer_1getFrame function is called from
Java to retrieve the texture id, and give up ownership of the previous one

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list