Unsolved Painting NV12-Formatted Images to QLabel
-
AFAIR yes. They have several sinks between widget, OpenGL and QtQuick.
-
Okay, but what if I don't have those sinks that are mentioned in the QtGstreamer API? ("qtvideosink", "qtglvideosink" and "qwidgetvideosink" (or "qt5videosink", "qt5glvideosink" and "qwidget5videosink" in Qt5))
-
Ho did you build Qt and the support for OpenSSL ?
-
???
I think this is the wrong post, my application has no need for SSL.
-
Indeed, that answer was supposed to be for another thread. I wonder how it ended up here.
Can you elaborate on the reasons you don't have these backends with QtGStreamer ?
-
Honestly QtGstreamer is not what I'm looking for. I'm looking to see if there's any Qt5 support for taking an NV12 frame, and painting it on the screen similar to a QImage. I know that there's QVideoFrame, but the images are coming in live, not from a file.
-
Out of curiosity, what's the problem with QtGStreamer ?
What kind of camera are you using?
-
The problem with QtGstreamer is simply that we already have a working standard Gstreamer plugin/program for our custom camera. The other problem is that it's a nonstandard processor that offloads all of its image decoding onto a co-processor, but that coprocessor sends back NV12-formatted decoded frames.
-
Can you describe how your application is currently working ? And what is your problem with loading the NV12 data in QVideoFrame ?
-
I have a camera that I receive data from over a special co-processor, through a manufacturer specific gstreamer plugin. The decoded frame appears in a uchar array in NV12 format, and I would like to be able to paint that on a screen using QVideoFrame. Going through the documentation it appears that the best way to get a uchar* like this into QVideoFrame is through QAbstractVideoBuffer, but since this video is not in the framebuffer to begin with, QAbstractVideoBuffer doesn't want to latch onto it.
I was wondering if there's a way to get this uchar array onto the screen.
-
How are you using that gstreamer plugin ?
-
Just using good ol' gst_parse_launch. The key here is that the plugin does not support anything other than NV12, and colorspace changes on the processor using the gstreamer convert plugin to get to RGB are too processor intensive to be worth it. But the gstreamer plugin isn't negotiable. It's manufacturer and hardware specific.
So that's why I'm wondering if I can get NV12-formatted frames to be painted on the screen.
-
I'm not trying to avoid that plugin, just to understand how your setup is working.
If using OpenGL is an option, QtMultimedia through Qt Quick should be able to show these frames. The backend is using gstreamer so depending on the gstreamer line you have to use you may have to tweak Qt's backend to do the same thing.