Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Gstreamer and scrollarea
QtWS25 Last Chance

Gstreamer and scrollarea

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 144 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    micheal15
    wrote on last edited by
    #1

    I'm using gstreamer how can i put the camera stream in a ui->scrollarea?

     gst_init(nullptr, nullptr);
    
        GstElement *pipeline = gst_parse_launch("udpsrc port=5200 ! application/x-rtp, media=video, clock-rate=90000, payload=96 ! rtpjpegdepay ! jpegdec ! videoconvert ! autovideosink", nullptr);
    
        gst_element_set_state(pipeline, GST_STATE_PLAYING);
    
        GstBus *bus = gst_element_get_bus(pipeline);
        GstMessage *msg = gst_bus_timed_pop_filtered(bus, GST_CLOCK_TIME_NONE, static_cast<GstMessageType>(GST_MESSAGE_ERROR | GST_MESSAGE_EOS));
    
        gst_message_unref(msg);
        gst_object_unref(bus);
        gst_element_set_state(pipeline, GST_STATE_NULL);
        gst_object_unref(pipeline);
    
    JoeCFDJ 1 Reply Last reply
    0
    • M micheal15

      I'm using gstreamer how can i put the camera stream in a ui->scrollarea?

       gst_init(nullptr, nullptr);
      
          GstElement *pipeline = gst_parse_launch("udpsrc port=5200 ! application/x-rtp, media=video, clock-rate=90000, payload=96 ! rtpjpegdepay ! jpegdec ! videoconvert ! autovideosink", nullptr);
      
          gst_element_set_state(pipeline, GST_STATE_PLAYING);
      
          GstBus *bus = gst_element_get_bus(pipeline);
          GstMessage *msg = gst_bus_timed_pop_filtered(bus, GST_CLOCK_TIME_NONE, static_cast<GstMessageType>(GST_MESSAGE_ERROR | GST_MESSAGE_EOS));
      
          gst_message_unref(msg);
          gst_object_unref(bus);
          gst_element_set_state(pipeline, GST_STATE_NULL);
          gst_object_unref(pipeline);
      
      JoeCFDJ Offline
      JoeCFDJ Offline
      JoeCFD
      wrote on last edited by JoeCFD
      #2

      @micheal15 use GstGLVideoItem as sink to add to and display your pipeline.

      An example can be found here:
      https://github.com/GStreamer/gst-plugins-good/blob/master/tests/examples/qt/qmlsink/main.qml

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved