I just flash my Xavier to the latest firmware(by SDKManager).
But unfortunately, I found my code can’t run in this firmware(but on jetpack 4.1 DP, everything is ok).
Here is my code:
cv::VideoCapture capture(“v4l2src device=/dev/video0 ! video/x-raw, width=640, height=480, format=YUY2 ! appsink”,CV_CAP_GSTREAMER);
below is the error message:
0:00:00.000267179 11105 0x55b6b9d600 INFO GST_INIT gst.c:586:init_pre: Initializing GStreamer Core Library version 1.14.1
0:00:00.000372367 11105 0x55b6b9d600 INFO GST_INIT gst.c:587:init_pre: Using library installed in /usr/lib/aarch64-linux-gnu
0:00:00.000403441 11105 0x55b6b9d600 INFO GST_INIT gst.c:607:init_pre: Linux nvidia 4.9.140-tegra #1 SMP PREEMPT Wed Mar 13 00:30:11 PDT 2019 aarch64
0:00:00.001074925 11105 0x55b6b9d600 INFO GST_INIT gstmessage.c:127:_priv_gst_message_initialize: init messages
0:00:00.002709810 11105 0x55b6b9d600 INFO GST_INIT gstcontext.c:84:_priv_gst_context_initialize: init contexts
0:00:00.003171333 11105 0x55b6b9d600 INFO GST_PLUGIN_LOADING gstplugin.c:317:_priv_gst_plugin_initialize: registering 0 static plugins
0:00:00.003491027 11105 0x55b6b9d600 INFO GST_PLUGIN_LOADING gstplugin.c:225:gst_plugin_register_static: registered static plugin "staticelements"
0:00:00.003519572 11105 0x55b6b9d600 INFO GST_PLUGIN_LOADING gstplugin.c:227:gst_plugin_register_static: added static plugin "staticelements", result: 1
0:00:00.003566230 11105 0x55b6b9d600 INFO GST_REGISTRY gstregistry.c:1727:ensure_current_registry: reading registry cache: /home/nvidia/.cache/gstreamer-1.0/registry.aarch64.bin
0:00:00.037526956 11105 0x55b6b9d600 INFO GST_REGISTRY gstregistrybinary.c:621:priv_gst_registry_binary_read_cache: loaded /home/nvidia/.cache/gstreamer-1.0/registry.aarch64.bin in 0.033873 seconds
0:00:00.037759094 11105 0x55b6b9d600 INFO GST_REGISTRY gstregistry.c:1583:scan_and_update_registry: Validating plugins from registry cache: /home/nvidia/.cache/gstreamer-1.0/registry.aarch64.bin
0:00:00.041047136 11105 0x55b6b9d600 INFO GST_REGISTRY gstregistry.c:1685:scan_and_update_registry: Registry cache has not changed
0:00:00.041086786 11105 0x55b6b9d600 INFO GST_REGISTRY gstregistry.c:1762:ensure_current_registry: registry reading and updating done, result = 1
0:00:00.041105219 11105 0x55b6b9d600 INFO GST_INIT gst.c:807:init_post: GLib runtime version: 2.56.4
0:00:00.041123588 11105 0x55b6b9d600 INFO GST_INIT gst.c:809:init_post: GLib headers version: 2.56.2
0:00:00.041137348 11105 0x55b6b9d600 INFO GST_INIT gst.c:810:init_post: initialized GStreamer successfully
0:00:00.041259721 11105 0x55b6b9d600 INFO GST_PIPELINE gstparse.c:337:gst_parse_launch_full: parsing pipeline description 'v4l2src device=/dev/video0 ! video/x-raw ! appsink'
0:00:00.147533797 11105 0x55b6b9d600 INFO GST_PLUGIN_LOADING gstplugin.c:901:_priv_gst_plugin_load_file_for_registry: plugin "/usr/lib/aarch64-linux-gnu/gstreamer-1.0/libgstvideo4linux2.so" loaded
0:00:00.147666762 11105 0x55b6b9d600 INFO GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "v4l2src"
0:00:00.151494508 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstelement.c:670:gst_element_add_pad:<GstBaseSrc@0x55b6dcc1d0> adding pad 'src'
0:00:00.152767297 11105 0x55b6b9d600 INFO GST_PLUGIN_LOADING gstplugin.c:901:_priv_gst_plugin_load_file_for_registry: plugin "/usr/lib/aarch64-linux-gnu/gstreamer-1.0/libgstapp.so" loaded
0:00:00.152819683 11105 0x55b6b9d600 INFO GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "appsink"
0:00:00.153447198 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstelement.c:670:gst_element_add_pad:<GstBaseSink@0x55b6dd1700> adding pad 'sink'
0:00:00.153641702 11105 0x55b6b9d600 INFO GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "pipeline"
0:00:00.154010422 11105 0x55b6b9d600 INFO GST_PIPELINE grammar.y:652:gst_parse_perform_link: linking some pad of GstV4l2Src named v4l2src0 to some pad of GstAppSink named appsink0 (0/0) with caps "video/x-raw"
0:00:00.156583522 11105 0x55b6b9d600 INFO GST_PLUGIN_LOADING gstplugin.c:901:_priv_gst_plugin_load_file_for_registry: plugin "/usr/lib/aarch64-linux-gnu/gstreamer-1.0/libgstcoreelements.so" loaded
0:00:00.156627044 11105 0x55b6b9d600 INFO GST_ELEMENT_FACTORY gstelementfactory.c:361:gst_element_factory_create: creating element "capsfilter"
0:00:00.156897007 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstelement.c:670:gst_element_add_pad:<GstBaseTransform@0x55b6dda1b0> adding pad 'sink'
0:00:00.156945457 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstelement.c:670:gst_element_add_pad:<GstBaseTransform@0x55b6dda1b0> adding pad 'src'
0:00:00.157071927 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2087:gst_bin_get_state_func:<pipeline0> getting state
0:00:00.157180219 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<capsfilter0> completed state change to NULL
0:00:00.157230397 11105 0x55b6b9d600 INFO GST_EVENT gstevent.c:1517:gst_event_new_reconfigure: creating reconfigure event
0:00:00.157322369 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstutils.c:1774:gst_element_link_pads_full: trying to link element v4l2src0:(any) to element capsfilter0:sink
0:00:00.157357507 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstelement.c:920:gst_element_get_static_pad: found pad capsfilter0:sink
0:00:00.157381444 11105 0x55b6b9d600 INFO GST_PADS gstutils.c:1588:prepare_link_maybe_ghosting: v4l2src0 and capsfilter0 in same bin, no need for ghost pads
0:00:00.157478792 11105 0x55b6b9d600 INFO GST_PADS gstpad.c:2378:gst_pad_link_prepare: trying to link v4l2src0:src and capsfilter0:sink
0:00:00.157625294 11105 0x55b6b9d600 INFO GST_PADS gstpad.c:4230:gst_pad_peer_query:<capsfilter0:src> pad has no peer
0:00:00.157678480 11105 0x55b6b9d600 INFO GST_PADS gstpad.c:2586:gst_pad_link_full: linked v4l2src0:src and capsfilter0:sink, successful
0:00:00.157695857 11105 0x55b6b9d600 INFO GST_EVENT gstevent.c:1517:gst_event_new_reconfigure: creating reconfigure event
0:00:00.157718642 11105 0x55b6b9d600 INFO GST_EVENT gstpad.c:5785:gst_pad_send_event_unchecked:<v4l2src0:src> Received event on flushing pad. Discarding
0:00:00.157755475 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstutils.c:1774:gst_element_link_pads_full: trying to link element capsfilter0:src to element appsink0:(any)
0:00:00.157772404 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstelement.c:920:gst_element_get_static_pad: found pad capsfilter0:src
0:00:00.157798421 11105 0x55b6b9d600 INFO GST_PADS gstutils.c:1035:gst_pad_check_link: trying to link capsfilter0:src and appsink0:sink
0:00:00.157882105 11105 0x55b6b9d600 INFO GST_PADS gstutils.c:1588:prepare_link_maybe_ghosting: capsfilter0 and appsink0 in same bin, no need for ghost pads
0:00:00.157905722 11105 0x55b6b9d600 INFO GST_PADS gstpad.c:2378:gst_pad_link_prepare: trying to link capsfilter0:src and appsink0:sink
0:00:00.157947867 11105 0x55b6b9d600 INFO GST_PADS gstpad.c:2586:gst_pad_link_full: linked capsfilter0:src and appsink0:sink, successful
0:00:00.157959804 11105 0x55b6b9d600 INFO GST_EVENT gstevent.c:1517:gst_event_new_reconfigure: creating reconfigure event
0:00:00.157972060 11105 0x55b6b9d600 INFO GST_EVENT gstpad.c:5785:gst_pad_send_event_unchecked:<capsfilter0:src> Received event on flushing pad. Discarding
0:00:00.158123427 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstelement.c:920:gst_element_get_static_pad: found pad appsink0:sink
0:00:00.158289994 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<appsink0> current NULL pending VOID_PENDING, desired next READY
0:00:00.158355565 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<appsink0> completed state change to READY
0:00:00.158385934 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<appsink0> notifying about state-changed NULL to READY (VOID_PENDING pending)
0:00:00.158455985 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'appsink0' changed state to 2(READY) successfully
0:00:00.158481618 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<capsfilter0> current NULL pending VOID_PENDING, desired next READY
0:00:00.158524852 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<capsfilter0> completed state change to READY
0:00:00.158551829 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed NULL to READY (VOID_PENDING pending)
0:00:00.158574358 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 2(READY) successfully
0:00:00.158591254 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<v4l2src0> current NULL pending VOID_PENDING, desired next READY
0:00:00.158765406 11105 0x55b6b9d600 INFO v4l2 v4l2_calls.c:596:gst_v4l2_open:<v4l2src0:src> Opened device '"All In" Video Capture' (/dev/video0) successfully
0:00:00.158796927 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<v4l2src0> completed state change to READY
0:00:00.158811936 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<v4l2src0> notifying about state-changed NULL to READY (VOID_PENDING pending)
0:00:00.158835137 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'v4l2src0' changed state to 2(READY) successfully
0:00:00.158858946 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2651:gst_element_continue_state:<pipeline0> committing state from NULL to READY, pending PLAYING, next PAUSED
0:00:00.158874210 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<pipeline0> notifying about state-changed NULL to READY (PLAYING pending)
0:00:00.158892835 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2658:gst_element_continue_state:<pipeline0> continue state change READY to PAUSED, final PLAYING
0:00:00.158918180 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<appsink0> current READY pending VOID_PENDING, desired next PAUSED
0:00:00.158958246 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2958:gst_bin_change_state_func:<pipeline0> child 'appsink0' is changing state asynchronously to PAUSED
0:00:00.158977927 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<capsfilter0> current READY pending VOID_PENDING, desired next PAUSED
0:00:00.159005224 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<capsfilter0> completed state change to PAUSED
0:00:00.159019145 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed READY to PAUSED (VOID_PENDING pending)
0:00:00.159039401 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 3(PAUSED) successfully
0:00:00.159055338 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<v4l2src0> current READY pending VOID_PENDING, desired next PAUSED
0:00:00.159122957 11105 0x55b6b9d600 INFO basesrc gstbasesrc.c:1358:gst_base_src_do_seek:<v4l2src0> seeking: time segment start=0:00:00.000000000, offset=0:00:00.000000000, stop=99:99:99.999999999, rate=1.000000, applied_rate=1.000000, flags=0x00, time=0:00:00.000000000, base=0:00:00.000000000, position 0:00:00.000000000, duration 99:99:99.999999999
0:00:00.159181743 11105 0x55b6b9d600 INFO task gsttask.c:457:gst_task_set_lock: setting stream lock 0x55b6dce220 on task 0x55b6ddd050
0:00:00.159196880 11105 0x55b6b9d600 INFO GST_PADS gstpad.c:6131:gst_pad_start_task:<v4l2src0:src> created task 0x55b6ddd050
0:00:00.159386424 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<v4l2src0> completed state change to PAUSED
0:00:00.159404473 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<v4l2src0> notifying about state-changed READY to PAUSED (VOID_PENDING pending)
0:00:00.159425466 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2995:gst_bin_change_state_func:<pipeline0> child 'v4l2src0' changed state to 3(PAUSED) successfully without preroll
0:00:00.159446138 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2651:gst_element_continue_state:<pipeline0> committing state from READY to PAUSED, pending PLAYING, next PLAYING
0:00:00.159460411 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<pipeline0> notifying about state-changed READY to PAUSED (PLAYING pending)
0:00:00.159495933 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2658:gst_element_continue_state:<pipeline0> continue state change PAUSED to PLAYING, final PLAYING
0:00:00.159594529 11105 0x55b6dd8770 INFO GST_ELEMENT_PADS gstelement.c:917:gst_element_get_static_pad: no such pad 'sink' in element "v4l2src0"
0:00:00.159781161 11105 0x55b6b9d600 INFO GST_EVENT gstevent.c:1388:gst_event_new_latency: creating latency event 0:00:00.000000000
0:00:00.159876333 11105 0x55b6dd8770 INFO v4l2 gstv4l2object.c:1196:gst_v4l2_object_fill_format_list:<v4l2src0:src> got 1 format(s):
0:00:00.159867820 11105 0x55b6b9d600 INFO bin gstbin.c:2781:gst_bin_do_latency_func:<pipeline0> configured latency of 0:00:00.000000000
0:00:00.159913422 11105 0x55b6dd8770 INFO v4l2 gstv4l2object.c:1202:gst_v4l2_object_fill_format_list:<v4l2src0:src> YUYV
0:00:00.159948848 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<appsink0> current READY pending PAUSED, desired next PLAYING
0:00:00.159983089 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2958:gst_bin_change_state_func:<pipeline0> child 'appsink0' is changing state asynchronously to PLAYING
0:00:00.160002290 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<capsfilter0> current PAUSED pending VOID_PENDING, desired next PLAYING
0:00:00.160018835 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<capsfilter0> completed state change to PLAYING
0:00:00.160033939 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed PAUSED to PLAYING (VOID_PENDING pending)
0:00:00.160060148 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 4(PLAYING) successfully
0:00:00.160081269 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<v4l2src0> completed state change to PLAYING
0:00:00.160094838 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<v4l2src0> notifying about state-changed PAUSED to PLAYING (VOID_PENDING pending)
0:00:00.160115255 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'v4l2src0' changed state to 4(PLAYING) successfully
0:00:00.160138264 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2087:gst_bin_get_state_func:<pipeline0> getting state
0:00:00.160149912 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2392:gst_element_get_state_func:<pipeline0> waiting for element to commit state
0:00:00.160570922 11105 0x55b6dd8770 INFO v4l2 gstv4l2object.c:4136:gst_v4l2_object_probe_caps:<v4l2src0:src> probed caps: video/x-raw, format=(string)YUY2, width=(int)1920, height=(int)1080, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)1600, height=(int)1200, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)1280, height=(int)1024, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)1440, height=(int)900, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)1280, height=(int)960, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)1368, height=(int)768, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)1280, height=(int)800, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)1280, height=(int)720, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)1024, height=(int)768, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)960, height=(int)540, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)800, height=(int)600, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)720, height=(int)576, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)720, height=(int)480, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)640, height=(int)480, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }; video/x-raw, format=(string)YUY2, width=(int)640, height=(int)360, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction){ 60/1, 50/1, 30/1, 25/1, 24/1, 15/1 }
0:00:00.160686351 11105 0x55b6dd8770 WARN basesrc gstbasesrc.c:3055:gst_base_src_loop:<v4l2src0> error: Internal data stream error.
0:00:00.160703535 11105 0x55b6dd8770 WARN basesrc gstbasesrc.c:3055:gst_base_src_loop:<v4l2src0> error: streaming stopped, reason not-negotiated (-4)
0:00:00.160757490 11105 0x55b6dd8770 INFO GST_ERROR_SYSTEM gstelement.c:2145:gst_element_message_full_with_details:<v4l2src0> posting message: Internal data stream error.
0:00:00.160817140 11105 0x55b6dd8770 INFO GST_ERROR_SYSTEM gstelement.c:2172:gst_element_message_full_with_details:<v4l2src0> posted error message: Internal data stream error.
0:00:00.160995164 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<appsink0> current PAUSED pending VOID_PENDING, desired next READY
0:00:00.161057406 11105 0x55b6dd8770 INFO task gsttask.c:316:gst_task_func:<v4l2src0:src> Task going to paused
0:00:00.161071167 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<appsink0> completed state change to READY
0:00:00.161091008 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<appsink0> notifying about state-changed PAUSED to READY (VOID_PENDING pending)
0:00:00.161139842 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'appsink0' changed state to 2(READY) successfully
0:00:00.161160803 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<capsfilter0> current PLAYING pending VOID_PENDING, desired next READY
0:00:00.161176195 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2651:gst_element_continue_state:<capsfilter0> committing state from PLAYING to PAUSED, pending READY, next READY
0:00:00.161190116 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed PLAYING to PAUSED (READY pending)
0:00:00.161232230 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2658:gst_element_continue_state:<capsfilter0> continue state change PAUSED to READY, final READY
0:00:00.164010139 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<capsfilter0> completed state change to READY
0:00:00.164040860 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed PAUSED to READY (VOID_PENDING pending)
0:00:00.164066781 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 2(READY) successfully
0:00:00.164110463 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<v4l2src0> current PLAYING pending VOID_PENDING, desired next READY
0:00:00.164155841 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2651:gst_element_continue_state:<v4l2src0> committing state from PLAYING to PAUSED, pending READY, next READY
0:00:00.164171361 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<v4l2src0> notifying about state-changed PLAYING to PAUSED (READY pending)
0:00:00.164190306 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2658:gst_element_continue_state:<v4l2src0> continue state change PAUSED to READY, final READY
0:00:00.164238180 11105 0x55b6dd8770 INFO task gsttask.c:318:gst_task_func:<v4l2src0:src> Task resume from paused
0:00:00.164332648 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<v4l2src0> completed state change to READY
0:00:00.164352617 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<v4l2src0> notifying about state-changed PAUSED to READY (VOID_PENDING pending)
0:00:00.164377994 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'v4l2src0' changed state to 2(READY) successfully
0:00:00.164409644 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2651:gst_element_continue_state:<pipeline0> committing state from PAUSED to READY, pending NULL, next NULL
0:00:00.164423340 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<pipeline0> notifying about state-changed PAUSED to READY (NULL pending)
0:00:00.164442029 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2658:gst_element_continue_state:<pipeline0> continue state change READY to NULL, final NULL
0:00:00.164494863 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<appsink0> current READY pending VOID_PENDING, desired next NULL
0:00:00.164537553 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<appsink0> completed state change to NULL
0:00:00.164552370 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<appsink0> notifying about state-changed READY to NULL (VOID_PENDING pending)
0:00:00.164571250 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'appsink0' changed state to 1(NULL) successfully
0:00:00.164601748 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<capsfilter0> current READY pending VOID_PENDING, desired next NULL
0:00:00.164620404 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<capsfilter0> completed state change to NULL
0:00:00.164634389 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<capsfilter0> notifying about state-changed READY to NULL (VOID_PENDING pending)
0:00:00.164655158 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'capsfilter0' changed state to 1(NULL) successfully
0:00:00.164672663 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2504:gst_bin_element_set_state:<v4l2src0> current READY pending VOID_PENDING, desired next NULL
0:00:00.165853672 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<v4l2src0> completed state change to NULL
0:00:00.165872265 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<v4l2src0> notifying about state-changed READY to NULL (VOID_PENDING pending)
0:00:00.165889930 11105 0x55b6b9d600 INFO GST_STATES gstbin.c:2952:gst_bin_change_state_func:<pipeline0> child 'v4l2src0' changed state to 1(NULL) successfully
0:00:00.165973837 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2676:gst_element_continue_state:<pipeline0> completed state change to NULL
0:00:00.165989390 11105 0x55b6b9d600 INFO GST_STATES gstelement.c:2579:_priv_gst_element_state_changed:<pipeline0> notifying about state-changed READY to NULL (VOID_PENDING pending)
0:00:00.166043248 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstpad.c:2134:gst_pad_unlink: unlinking v4l2src0:src(0x55b6dce1b0) and capsfilter0:sink(0x55b6dce650)
0:00:00.166074482 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstpad.c:2188:gst_pad_unlink: unlinked v4l2src0:src and capsfilter0:sink
0:00:00.166097843 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstpad.c:2134:gst_pad_unlink: unlinking capsfilter0:src(0x55b6dce8a0) and appsink0:sink(0x55b6dce400)
0:00:00.166126036 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstpad.c:2188:gst_pad_unlink: unlinked capsfilter0:src and appsink0:sink
0:00:00.166142933 11105 0x55b6b9d600 INFO GST_PARENTAGE gstbin.c:1799:gst_bin_remove_func:<pipeline0> removed child "capsfilter0"
0:00:00.166183670 11105 0x55b6b9d600 INFO GST_REFCOUNTING gstelement.c:3251:gst_element_dispose:<capsfilter0> 0x55b6dda1b0 dispose
0:00:00.166195575 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstelement.c:789:gst_element_remove_pad:<capsfilter0> removing pad 'sink'
0:00:00.166268986 11105 0x55b6b9d600 INFO GST_ELEMENT_PADS gstelement.c:789:gst_element_remove_pad:<capsfilter0> removing pad 'src'
0:00:00.166297371 11105 0x55b6b9d600 INFO GST_REFCOUNTING gstelement.c:3297:gst_element_dispose:<capsfilter0> 0x55b6dda1b0 parent class dispose
0:00:00.166313148 11105 0x55b6b9d600 INFO GST_REFCOUNTING gstelement.c:3328:gst_element_finalize:<capsfilter0> 0x55b6dda1b0 finalize
0:00:00.166332893 11105 0x55b6b9d600 INFO GST_REFCOUNTING gstelement.c:3334:gst_element_finalize:<capsfilter0> 0x55b6dda1b0 finalize parent
0:00:00.166353853 11105 0x55b6b9d600 INFO GST_PARENTAGE gstbin.c:1799:gst_bin_remove_func:<pipeline0> removed child "appsink0"
0:00:00.166397951 11105 0x55b6b9d600 INFO GST_PARENTAGE gstbin.c:1799:gst_bin_remove_func:<pipeline0> removed child "v4l2src0"
0:00:00.166421824 11105 0x55b6b9d600 INFO GST_REFCOUNTING gstelement.c:3251:gst_element_dispose:<pipeline0> 0x55b6dd2170 dispose
0:00:00.166483363 11105 0x55b6b9d600 INFO GST_REFCOUNTING gstelement.c:3297:gst_element_dispose:<pipeline0> 0x55b6dd2170 parent class dispose
0:00:00.166501828 11105 0x55b6b9d600 INFO GST_REFCOUNTING gstelement.c:3328:gst_element_finalize:<pipeline0> 0x55b6dd2170 finalize
0:00:00.166516580 11105 0x55b6b9d600 INFO GST_REFCOUNTING gstelement.c:3334:gst_element_finalize:<pipeline0> 0x55b6dd2170 finalize parent
OpenCV Error: Unspecified error (GStreamer: unable to start pipeline
) in cvCaptureFromCAM_GStreamer, file /home/nvidia/opencv-3.4.0/modules/videoio/src/cap_gstreamer.cpp, line 890
VIDEOIO(cvCreateCapture_GStreamer (CV_CAP_GSTREAMER_FILE, filename)): raised OpenCV exception:
/home/nvidia/opencv-3.4.0/modules/videoio/src/cap_gstreamer.cpp:890: error: (-2) GStreamer: unable to start pipeline
in function cvCaptureFromCAM_GStreamer
VideoCapture or VideoWriter not opened
I also try :
gst-launch-1.0 -v v4l2src device=/dev/video0 ! video/x-raw, width=1280, height=720, format=YUY2 ! xvimagesink
everything works fine.
As I said above, the same code works fine in jetpack 4.1 DP.
Is there anyone who met the same problem before?