Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. 3rd Party Software
  4. Qt Application using Gstreamer works only with root privileges
Forum Updated to NodeBB v4.3 + New Features

Qt Application using Gstreamer works only with root privileges

Scheduled Pinned Locked Moved Solved 3rd Party Software
2 Posts 1 Posters 837 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.
  • Fal92F Offline
    Fal92F Offline
    Fal92
    wrote on last edited by Fal92
    #1

    Hello everybody, I'm encountering this issue while developing on Qt Creator an application that uses gstreamer.
    basically, the application works when it runs with Sudo privileges from the terminal but when it runs from Qt creator gives the following error

    Failed to create qtquick2videosink. Make sure it is installed correctly
    ASSERT failure in RefPointer::operator->() const: "Attempted to dereference a null pointer", file /usr/include/Qt5GStreamer/QGlib/refpointer.h, line 355
    

    at the same time, I tried to investigate a little the gstreamer installation on my system, to see if there was a problem with qt5videosink.
    When running :

    gst-inspect-1.0 | grep qt5videosink
    

    it gives no output, but if I run it with root privileges:

    sudo gst-inspect-1.0 | grep qt5videosink
    
    output:
     
    qt5videosink:  qt5videosink: Qt video sink
    qt5videosink:  qt5glvideosink: Qt GL video sink
    qt5videosink:  qwidget5videosink: QWidget video sink
    qt5videosink:  qtquick2videosink: QtQuick2 video sink
    
    

    now, qt5videosink magically exists.

    My first guess would be a permission problem of the component but I don't know how to get my hands on it.
    If anybody has had the same issue I would be glad if you shared your experience helping me to get it to work normally from QT Creator.

    Thank you in advance for your help.

    FR.

    1 Reply Last reply
    0
    • Fal92F Offline
      Fal92F Offline
      Fal92
      wrote on last edited by
      #2

      Solved: if anyone encounters the same issue there's the solution that worked for me.

      delete the following file in the cache:

      rm ~/.cache/gstreamer-1.0 registry.x86_64.bin
      

      and then run:

      gst-inspect-1.0
      

      to regenerate it. now the plugins are visible and usable by all users.

      1 Reply Last reply
      1

      • Login

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