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 742353 - camerabin: video supported caps will be ANY as wrappercamerabinsrc add videoconver and videoscale
camerabin: video supported caps will be ANY as wrappercamerabinsrc add videoc...
Status: RESOLVED WONTFIX
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
1.4.1
Other Linux
: Normal normal
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2015-01-05 05:41 UTC by kevin
Modified: 2015-01-07 06:29 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description kevin 2015-01-05 05:41:48 UTC
When get video supported caps from camerabin, it will be ANY as wrappercamerabinsrc add videoconvert and viderscale. But I want to get camera native supported resolution for performance to avoid software CSC and resize. Do need set native caps when get video supported caps? Or add one property to get that info? I can upload patch if has decision.
Comment 1 Thiago Sousa Santos 2015-01-05 18:21:35 UTC
If a property is needed it is in wrappercamerabinsrc, camerabin doesn't know what kind of element you are using as the camera-source in it.

wrappercamerabinsrc will add a videoconvert and a videoscale, the videoconvert is for convenience and maybe it could be disabled by adding a 'flags' property. The videoscale is needed for the digital zooming feature.

Can you share the caps you are getting when you ask the possibilities? Are you doing this in READY state at least? in NULL some elements won't have their devices open and you might get ANY result. The caps you get should have the prefered formats (native) ones first before the ones that will require transformations.

Another option is to query the source pad of the video source directly.
Comment 2 kevin 2015-01-06 02:11:04 UTC
I get video-capture-supported-caps when camerabin is in PLAYING state. The native caps should be the first one structure in caps? I will check if has bug.

wrappercamerabinsrc will use videoscale to do digital zooming. So how to set camera output caps? If native camera support several output resolution, do user need set camera source and capfilter bin to wrappercamerabinsrc to select native camera output resolution? Or wrappercamerabinsrc need add camera output capsfilter property?
I have tried set preview and video capsfilter on wrappercamerabinsrc output pad. But I met renegotiation error as zoom_capsfilter will be fixed to the default caps and will fail if I set caps different with the default caps.
Comment 3 kevin 2015-01-06 05:08:14 UTC
I can get viewfinder-supported-caps after camerabin in PLAYING state. But can't get video-capture-supported-caps and image-capture-supported-caps as haven't start capture.

Close the ticket.
Comment 4 Thiago Sousa Santos 2015-01-06 11:10:06 UTC
Why did you close it?

What do you mean with "can't get video-capture-supported-caps and image-capture-supported-caps as haven't start capture"?

Does the caps you get have the natively supported formats first?
Comment 5 kevin 2015-01-07 01:56:57 UTC
I only set camerabin to PLAYING state and haven't sent start-capture signal. The video-capture-supported-caps and image-capture-supported-caps is ANY as the two pads of wrappercamerabinsrc is NULL. viewfinder-supported-caps have native camera caps and convert caps. Is it right behave?

Camera Capebilities:

0:00:36.965099671  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstutils.c:2769:gst_pad_query_caps:<wrappercamerabinsrc0:vids
rc> get pad caps with filter (NULL)
0:00:36.965283337  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstpad.c:2964:gst_pad_query_caps_default:<wrappercamerabinsrc
0:vidsrc> query caps caps query: 0xcdeec0, GstQueryCaps, filter=(GstCaps)"NULL", caps=(GstCaps)"NULL";
0:00:36.965544337  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstpad.c:2964:gst_pad_query_caps_default:<outsel:src_0> query
 caps caps query: 0xcdeec0, GstQueryCaps, filter=(GstCaps)"NULL", caps=(GstCaps)"NULL";
0:00:36.965803004  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstpad.c:2987:gst_pad_query_caps_default:<outsel:src_0> tryin
g pad template caps
0:00:36.965928004  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstpad.c:3017:gst_pad_query_caps_default:<outsel:src_0> using
 caps 0xce9ac8 ANY
0:00:36.966120004  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstutils.c:2776:gst_pad_query_caps:<wrappercamerabinsrc0:vids
rc> query returned ANY
0:00:36.966273337  2566   0xc9a400 DEBUG              camerabin /nfsroot/songbing/yocto/build-x11/tmp/work/cortexa9hf-vfp-neon-mx6qdl-poky-li
nux-gnueabi/gstreamer1.0-plugins-bad/1.4.1-r0/gst-plugins-bad-1.4.1/gst/camerabin2/gstcamerabin2.c:2292:gst_camera_bin_get_property:<camerabi
n0> 111111111Setting image capture caps to ANY
0:00:36.966459671  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstutils.c:2769:gst_pad_query_caps:<wrappercamerabinsrc0:imgs
rc> get pad caps with filter (NULL)
0:00:36.966632337  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstpad.c:2964:gst_pad_query_caps_default:<wrappercamerabinsrc
0:imgsrc> query caps caps query: 0xcdef50, GstQueryCaps, filter=(GstCaps)"NULL", caps=(GstCaps)"NULL";
0:00:36.966868337  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstpad.c:2964:gst_pad_query_caps_default:<outsel:src_1> query
 caps caps query: 0xcdef50, GstQueryCaps, filter=(GstCaps)"NULL", caps=(GstCaps)"NULL";
0:00:36.967059004  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstpad.c:2987:gst_pad_query_caps_default:<outsel:src_1> tryin
g pad template caps
0:00:37.299112671  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstpad.c:3017:gst_pad_query_caps_default:<outsel:src_1> using
 caps 0xce9ac8 ANY
0:00:37.299329671  2566   0xc9a400 DEBUG               GST_CAPS /home2/jenkins/workspace/3.14.X-1.0.0_x11/temp_build_dir/build_all/tmp/work/c
ortexa9hf-vfp-neon-poky-linux-gnueabi/gstreamer1.0/1.4.1-r0/gstreamer-1.4.1/gst/gstutils.c:2776:gst_pad_query_caps:<wrappercamerabinsrc0:imgs
rc> query returned ANY
0:00:37.299479004  2566   0xc9a400 DEBUG              camerabin /nfsroot/songbing/yocto/build-x11/tmp/work/cortexa9hf-vfp-neon-mx6qdl-poky-li
nux-gnueabi/gstreamer1.0-plugins-bad/1.4.1-r0/gst-plugins-bad-1.4.1/gst/camerabin2/gstcamerabin2.c:2292:gst_camera_bin_get_property:<camerabi
n0> 111111111Setting image capture caps to ANY
Comment 6 kevin 2015-01-07 06:29:41 UTC
Can get camera native caps from video source which set to wrappercamerabinsrc
and set camera resolution by add one capsfilter after video source before set
it to wrappercamerabinsrc. Also can set video-source-filter to
wrappercamerabinsrc which can get from camerabin.
Close it.