Bug 55454 - encodebin element missing -> camerabin2 fails on osx.
Summary: encodebin element missing -> camerabin2 fails on osx.
Status: REOPENED
Alias: None
Product: GStreamer SDK
Classification: Unclassified
Component: General (show other bugs)
Version: 2013.6
Hardware: All All
: high normal
Assignee: bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-09-29 21:15 UTC by Mario Kleiner
Modified: 2013-07-03 17:19 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
Test application (890 bytes, text/plain)
2013-05-07 15:19 UTC, Thiago Santos
Details

Description Mario Kleiner 2012-09-29 21:15:55 UTC
Hi,

when i tried to test the camerabin2 element in the OSX 2012.9 universal SDK:

/Library/Frameworks/GStreamer.framework/Commands/gst-launch-0.10 -v -m camerabin2

This fails immediately with:

ERROR: from element /GstCameraBin2:camerabin20: Missing element 'encodebin' - check your GStreamer installation.

Indeed encodebin is missing from the SDK.

I've only tested with x86_64 on OSX, but it may be missing from other SDKs, e.g., 32-Bit SDK or Windows SDK as well.

thanks,
-mario
Comment 1 Sebastian Dröge (slomo) 2012-10-01 09:50:28 UTC
Thanks for reporting, this is fixed in GIT now and this fix will be included in the next release.
Comment 2 Mario Kleiner 2012-11-30 15:22:02 UTC
Retested with 2012.11 SDK. This time the encodebin plugin which was omitted last time is bundled, but now it fails one step further.

If i set camerabin2's "mode" property to 2 for video recording i get:

          Error from element image-encodebin: Your GStreamer installation is missing a plug-in.
           Additional debug info: gstencodebin.c(1703): create_elements_and_pads (): /GstCameraBin2:ptbvideocapturepipeline/GstEncodeBin:image-encodebin:
No available muxer for format 0x124383980.

If instead i leave it at its default of 1 for still image capture, it complains about some missing jpeg encoder:

ERROR: Pipeline doesn't want to pause. 
Got message #59 from element "image-encodebin" (element): missing-plugin, type=(string)encoder, detail=(GstCaps)image/jpeg, name=(string)"JPEG\ encoder"; 
Missing element: JPEG encoder 
Got message #60 from element "image-encodebin" (error): GstMessageError, gerror=(GError)NULL, debug=(string)"gstencodebin.c\(1703\):\ create_elements_and_pads\ \(\):\ /GstCameraBin2:camerabin20/GstEncodeBin:image-encodebin:\012No\ available\ muxer\ for\ format\ 00000000056C9400"; 
ERROR: from element /GstCameraBin2:camerabin20/GstEncodeBin:image-encodebin: Your GStreamer installation is missing a plug-in. 
Additional debug info: 
gstencodebin.c(1703): create_elements_and_pads (): /GstCameraBin2:camerabin20/GstEncodeBin:image-encodebin: 
No available muxer for format 00000000056C9400 

e.g, by calling gst-launch -v -m camerabin2

In any case, now different other required plugins are missing for camerabin2 to work.

Could somebody please test this with some webcam and make sure that at least basic video capture works, before marking the bug as fixed?

thanks,
-mario
Comment 3 Sebastian Dröge (slomo) 2013-02-19 12:35:34 UTC
I can confirm that, it looks like jpegparse or any other element is missing. The error message is a bit misleading
Comment 4 Thiago Santos 2013-05-06 18:20:54 UTC
Hello,

can you check if you have jpegenc and jifmux in your sdk version? You can try running the following commands from your gst-sdk environment.

gst-inspect-0.10 jpegenc
gst-inspect-0.10 jifmux

I'm testing with current gstreamer-sdk git and I got those 2 installed.

Unfortunatelly at the moment I have no cameras connected to my osx computer, so I'm unable to properly get camerabin2 running.
Comment 5 Thiago Santos 2013-05-07 15:19:08 UTC
So I wrote a small script that sets videotestsrc as the video source for camerabin2 and it works with current git of gstreamer-sdk.
Comment 6 Thiago Santos 2013-05-07 15:19:43 UTC
Created attachment 78985 [details]
Test application

Attaching the test application here for reference
Comment 7 Mario Kleiner 2013-07-03 17:19:03 UTC
Retesting with 2013.6, camerabin2 still doesn't work at all with default settings. I found a workaround for my app, so the problem is "solved" for my purpose, as shown in this commit:

<https://github.com/kleinerm/Psychtoolbox-3/commit/ce2b0c63fb7c74101dce752c10cee02c318cdb8d>

My hunch from reading through the gstencodebin.c code is that maybe the missing "jifmux" plugin or other missing jpeg muxer (formatter?) in the SDK is causing the problem?

Below is the debug output without the workaround, with "image-profile" property left at its default value.

best,
-mario

0:00:01.661788000  1604 0x7f894cb1b600 DEBUG              encodebin gstencodebin.c:1355:_create_stream_group: Done creating elements, adding StreamGroup to our controlled stream list
0:00:01.661817000  1604 0x7f894cb1b600 INFO              GST_STATES gstelement.c:2479:gst_element_continue_state:<muxer> completed state change to NULL
0:00:01.661858000  1604 0x7f894cb1b600 INFO        GST_ELEMENT_PADS gstelement.c:979:gst_element_get_static_pad: found pad videobin-capsfilter:src
0:00:01.661907000  1604 0x7f894cb1b600 INFO                GST_PADS gstpad.c:1978:gst_pad_link_prepare: trying to link videobin-capsfilter:src and video-encodebin:video_0
0:00:01.693754000  1604 0x7f894cb1b600 INFO                GST_PADS gstpad.c:2161:gst_pad_link_full: linked videobin-capsfilter:src and video-encodebin:video_0, successful
0:00:01.693830000  1604 0x7f894cb1b600 DEBUG              encodebin gstencodebin.c:1937:gst_encode_bin_set_profile:<image-encodebin> profile : Psychtoolbox audio/video
0:00:01.693840000  1604 0x7f894cb1b600 DEBUG              encodebin gstencodebin.c:1918:gst_encode_bin_setup_profile: Setting up profile Psychtoolbox audio/video (type:container)
0:00:01.693847000  1604 0x7f894cb1b600 DEBUG              encodebin gstencodebin.c:1647:create_elements_and_pads: Current profile : Psychtoolbox audio/video
0:00:01.693853000  1604 0x7f894cb1b600 DEBUG              encodebin gstencodebin.c:1582:_get_muxer: Getting list of muxers for format 0x7f894d0a9900
0:00:01.693900000  1604 0x7f894cb1b600 WARN               encodebin gstencodebin.c:1698:create_elements_and_pads: No available muxer for 0x7f894d0a9900
0:00:01.693982000  1604 0x7f894cb1b600 WARN               encodebin gstencodebin.c:1705:create_elements_and_pads:<image-encodebin> error: No available muxer for format 0x7f894d0a9900
0:00:01.694002000  1604 0x7f894cb1b600 INFO        GST_ERROR_SYSTEM gstelement.c:1983:gst_element_message_full:<image-encodebin> posting message: Your GStreamer installation is missing a plug-in.
0:00:01.694019000  1604 0x7f894cb1b600 INFO        GST_ERROR_SYSTEM gstelement.c:2006:gst_element_message_full:<image-encodebin> posted error message: Your GStreamer installation is missing a plug-in.
0:00:01.694029000  1604 0x7f894cb1b600 DEBUG              encodebin gstencodebin.c:1889:gst_encode_bin_tear_down_profile: Tearing down profile Psychtoolbox audio/video
0:00:01.694089000  1604 0x7f894cb1b600 INFO        GST_ELEMENT_PADS gstelement.c:979:gst_element_get_static_pad: found pad imagebin-capsfilter:src
0:00:01.694109000  1604 0x7f894cb1b600 DEBUG              encodebin gstencodebin.c:705:gst_encode_bin_request_new_pad:<image-encodebin> templ:video_%d, name:(null)
0:00:01.694121000  1604 0x7f894cb1b600 DEBUG              encodebin gstencodebin.c:670:request_pad_for_stream:<image-encodebin> name:(null) caps:0x0
0:00:01.694131000  1604 0x7f894cb1b600 DEBUG              encodebin gstencodebin.c:611:next_unused_stream_profile:<image-encodebin> ptype:GstEncodingVideoProfile, caps:0x0
0:00:01.694142000  1604 0x7f894cb1b600 WARN               encodebin gstencodebin.c:687:request_pad_for_stream:<image-encodebin> Couldn't find a compatible stream profile
0:00:01.696052000  1604 0x7f894cb1b600 INFO              GST_STATES gstelement.c:2787:gst_element_change_state:<ptbvideocapturepipeline> have FAILURE change_state return
0:00:01.696106000  1604 0x7f894cb1b600 INFO              GST_STATES gstbin.c:1784:gst_bin_get_state_func:<ptbvideocapturepipeline> getting state
PTB-ERROR: Statechange failed with GST_STATE_CHANGE_FAILURE!
PTB-ERROR: GStreamer videocapture engine reports this error:
           Error from element image-encodebin: Your GStreamer installation is missing a plug-in.
           Additional debug info: gstencodebin.c(1705): create_elements_and_pads (): /GstCameraBin2:ptbvideocapturepipeline/GstEncodeBin:image-encodebin:
No available muxer for format 0x7f894d0a9900.

Error in function OpenVideoCapture:     Usage error
In OpenVideoCapture: Opening the video capture device failed during camerabin2 pipeline zero -> ready. Reason given above.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.