After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 739385 - GstGLMixer link with capsfilter not-negotiated
GstGLMixer link with capsfilter not-negotiated
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
git master
Other Linux
: Normal normal
: 1.5.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-10-30 05:59 UTC by comicfans44
Modified: 2014-10-30 12:10 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description comicfans44 2014-10-30 05:59:38 UTC
construct pipeline as 

videotestsrc !  glvideomixer name=mix ! capsfilter name=capsfilter ! glimagesink videotestsrc name=s2 ! mix. 

and set capsfilter.caps to GL:Memory video, log gives error as 
reason not-negotiated (-4)

seems that gst_gl_mixer_query_caps didn't add GL capsfeatures to caps (line 605)
call gst_gl_mixer_update_caps here fix the problem .

following demo can trigger this problem:

#include <gst/gst.h>

#include <gst/gl/gstglmemory.h>

    
int main(int argc, char *argv[])
{

    gst_init(NULL,NULL);

    GstElement* pipeline=gst_parse_launch("videotestsrc !  glvideomixer name=mix ! capsfilter name=capsfilter ! glimagesink videotestsrc  ! mix. ",NULL);

    GstElement *capsfilter=gst_bin_get_by_name(GST_BIN(pipeline),"capsfilter");


    GstCaps *caps=gst_caps_new_simple("video/x-raw",
            "width",G_TYPE_INT,700,
            "height",G_TYPE_INT,700,NULL);

    gst_caps_set_features(caps,0,
            gst_caps_features_new(GST_CAPS_FEATURE_MEMORY_GL_MEMORY,NULL));

    g_object_set(G_OBJECT(capsfilter),"caps",caps,NULL);

    GMainLoop *loop=g_main_loop_new(NULL,FALSE);


    gst_element_set_state(pipeline,GST_STATE_PLAYING);

    g_main_loop_run(loop);

}
Comment 1 Matthew Waters (ystreet00) 2014-10-30 12:10:20 UTC
commit a4af98b8c659093197fd3c3764f375e6d1636dfb
Author: Matthew Waters <matthew@centricular.com>
Date:   Thu Oct 30 23:08:00 2014 +1100

    glmixer: don't get the current caps from GstVideoInfo for the srcpad
    
    It's missing the caps features needed.