Questions tagged [qtmultimedia]
QtMultimedia module from the Qt Toolkit that provides a rich feature set to easily take advantage of a platform's multimedia capabilites and hardware.
qtmultimedia
242
questions
59
votes
2
answers
3k
views
Playing a custom avi data stream using QtMultimedia
I need to play back a custom AVI file that contains a classic video stream, an audio stream but also a custom data stream.
The custom stream contains data that is visualized by some custom widgets; ...
50
votes
1
answer
900
views
Qt5 VideoOverview example does not work. Any solution?
I am stuck for a month with a video example given in Qt Video Overview.
I tried that code, but I only got a blank square (QWidget). I am using GStreamer0.10 for media playback over Qt5. I also played ...
13
votes
2
answers
6k
views
Qt6 and Multimedia module
As I can see in Qt6 no more Multimedia API. Am I right? Is it correct that in Qt6 for such simple task as playing sound I should look at third-party libraries now?
9
votes
2
answers
4k
views
QAudioDeviceInfo finds no default audio device on Ubuntu
I am trying to run the basic example from the QAudioDeviceInfo class reference, but Qt is not finding a default audio device.
Running this code shows no output:
foreach (const QAudioDeviceInfo &...
9
votes
2
answers
15k
views
No decoder available for type 'video/x-h264
I am trying to run one of qt sample apps without any modification. It is called player and it is a multimedia widget demonstration. My system is Ubuntu 16.04 64bit. When I try to play a video, I see ...
6
votes
1
answer
5k
views
Custom source property for VideoOutput QML
What exactly has to be done to provide custom source of frames for VideoOutput QML object?
Does VideoOuput itself provide an instance of QAbstractVideoSurface class to the "source"?
The Qt5 ...
6
votes
1
answer
10k
views
Unknown module(s) in QT: multimedia
I have downloaded qt-everywhere-opensource-src-5.4.1 and build and installed static.
Next i built QMultimedia and installed.
I get "Unknown module(s) in QT: multimedia" from the .pro when including
...
6
votes
1
answer
3k
views
How to draw QtGraphicsView on Top of QVideoWidget with transparency
I am trying to overlay some graphics(QtGraphicsView) on top of video player(QVideoWidget). i have already tried setting QtGraphicsView subclass stylesheets to transparent and background brush and none ...
5
votes
1
answer
3k
views
How video is played in the QML?
I am new to qml. I would like to know how the video is played in the qml. How the video is handled in the back-end(The classes and modules responsible for video playback). How can i add a custom ...
5
votes
1
answer
3k
views
Force QMediaPlayer to update position accurately for video scrubbing application?
I am writing an application which will allow the user to scrub through an open video. Developing on Windows 7/8 with Qt 5.3, I have been using QMediaPlayer and QVideoWidget following the qvideowidget ...
5
votes
3
answers
1k
views
Unable to play video Qt5 multimedia ubuntu 16.04
I am trying to use QMediaPlayer class to play videos, but keep getting this error -
`GLib-GObject-WARNING **: cannot register existing type 'GstObject'
GLib-CRITICAL **: g_once_init_leave: ...
5
votes
0
answers
533
views
How to get total number of frames in a video.mp4 using Qt Multimedia
Scenario
I am using QMediaPlayer to a display a video on a VideoOutput.
Works well.
I do a MyQMediaPlayerPtr->setMedia(sample_video.mp4) & I have full control on that video playback.
I am ...
5
votes
2
answers
4k
views
Can't import QtMultimedia in PyQt 5 on Windows
I'm trying to learn PyQt5 + qml, and everything I tried so far works fine, however I've ran into a snag when trying to import QtMultimedia into my qml file results in the following error:
plugin ...
4
votes
2
answers
4k
views
How to play video with qt5
I'm trying to make a simple videoplayer using qt. However, I can't get the videowidget example that comes with qt to work, instead I get an error: "The QMediaPlayer object does not have a valid ...
4
votes
3
answers
4k
views
QAudioDecoder - no service found
I am trying to decode a .wav file using QAudioDecoder class. Even though I had included the QtMultimedia module into my .pro file by adding
QT += multimedia I am receiving an error that service for ...
4
votes
1
answer
5k
views
PulseAudioService pa_context_connect() failed in all Qt GUI applications
I have an embedded linux device that is running linux kernel 4.4 and QT5.9.1 with busybox. I have two applications written in QT, one with a GUI and another backend service also written in QT but has ...
4
votes
2
answers
2k
views
Fullscreen mode for a video
I have a video output embedded in a QML view. It is working fine, but I want to make that video output go fullscreen when I click on it.
Every time, some images that are in the view (some sibiling, ...
4
votes
1
answer
3k
views
Qt : How to create a video from multiple QImages
How to create a .mp4 video out of multiple QImages in a Qt application.
Looking at QMediaRecorder examples, it only knows how to grab frames from camera. There seems to be no way to pass multiple ...
4
votes
0
answers
711
views
No Module named QtMultimedia
Trying to play audio in a qt gui
I've tried basically every suggestion on Google pertaining to playing audio with pyqt (pyside, pygame, QtMultimedia). It seems pretty straight forward using QSound, ...
4
votes
0
answers
2k
views
recording video to file with QML
I am using the Qt Multimedia framework and I can display video on my window just fine using QML and the Camera module as follows:
ControlView {
id: recorderWindow
color: "#000000"
border....
3
votes
2
answers
9k
views
Error: No module named 'PyQt5.QtMultimedia'
I am trying to build a GUI integrating videos, and for this I need to import PyQt5.QtMultimedia. Yet when trying to import the module (import PyQt5.QtMultimedia) I receive an error: ...
3
votes
3
answers
14k
views
Get file name from an opened file, not a file path
Let's say I opened a file called file1.mp3 in a PyQt5 app using the file dialog and assigned it to a variable like this:
song = QFileDialog.getOpenFileName(self, "Open Song", "~", "Sound Files (*.mp3 ...
3
votes
1
answer
822
views
Invalid/undefined mediaobject property of QML Camera
I'm trying to create a QML item, defined in C++, that would intercept frames from a QML Camera before they are displayed by a VideoOutput. Something like:
Window {
Camera {
id: camera
...
3
votes
2
answers
4k
views
How to get length of a song using Qt 5.1?
How can I get the length of a song in Qt 5.1 API? I think I can read it using Length metadata but I'm not sure if this metadata will be available for all audio files.
3
votes
1
answer
1k
views
Using Camera on Linux Desktop in Qt Quick
I have a simple project in Qt Quick in which I need to process output from camera. The project should run on Android, Windows and Linux. So far I am successful in connecting to the camera on Android, ...
3
votes
1
answer
6k
views
QtQuick: cannot playback any video on embedded linux
I cross compiled Qt 5.2.1 for TI AM335x board using the toolchain provided by TI together with their SDK 6.00.00.
Unluckily I am not able to reproduce any video in QML...
The debug console tells:
...
3
votes
1
answer
2k
views
How to install Qt with multimedia on Windows
I'd installed QT for Windows but when I try to use
QT += multimedia in the .pro file it showed me that this module was unknown. I checked Qt online installer for additional modules but there was no ...
3
votes
1
answer
6k
views
QMediaPlayer doesn't play anything on Ubuntu 16.04 / Qt 5.6
I'm using the official Qt 5.6 SDK on Ubuntu 16.04 and when I try to play an mp3 file I just get:
defaultServiceProvider::requestService(): no service found for - "org.qt-project.qt.mediaplayer"
The ...
3
votes
2
answers
5k
views
Why QML MediaPlayer/VideoOutput doesn't work for me?
I'm trying to play test video with qml by this code:
import QtQuick 2.2
import QtMultimedia 5.0
Item {
width: 300
height: 300
MediaPlayer {
id: player
source: "C:\\...
3
votes
1
answer
1k
views
QSoundEffect always loading status in Qt 5.4
Following code isn't working. QSoundEffect::status always return QSoundEffect::Loading and QSoundEffect::isLoaded return false.
QFile file("file.wav");
file.open(QIODevice::ReadWrite);
QByteArray ...
3
votes
3
answers
3k
views
How to find video resolution and aspect ratio of QMediaPlayer video?
This seems too simple, I must be overlooking something?
How do I find the native video size or aspect ratio from a video file being displayed by a QMediaPlayer?
The video Resolution, ...
3
votes
2
answers
5k
views
Unable to loop video using QML MediaPlayer
I am trying to create a simple video player that just plays a specified video on loop. While the video plays as expected, it does not loop.
The following is the code I am using:
import QtQuick 2.0
...
3
votes
1
answer
2k
views
multimedia module cannot be found in Qt for android
I use MediaPlayer qml type to play a music.I just put one single qml file for this project.And It runs perfect on windows.
When I build it an android. Debug says module "QtMultimedia" plugin "...
3
votes
0
answers
2k
views
Plugin cannot be loaded for module "QtMultimedia". Cannot load library declarative_multimedia.dll
I'm creating a PyQt5 + qml application. Windows 10, PyQt5 5.13.2, Python 3.6. Everything works fine until I try and import QtMultimedia, which results in the error message:
QQmlApplicationEngine ...
3
votes
0
answers
643
views
Two QML Video elements work fine on desktop but not on Android
We want to have multiple simultaneous video playbacks in our application.
This example below runs fine on Mac but on Android, I see only video in the left QML Video element.
I notice, from the ...
3
votes
0
answers
2k
views
Can't get my video played with Qt Multimedia and gstreamer
I've just installed gstreamer on my Debian Jessie linux.
I actually plan to use it within QtMultimedia framework. And though I'm familiar with vlc...I'm new in gstreamer's world.
I tried to run the ...
3
votes
1
answer
2k
views
Qt 5.4 QML VideoOutput not working on iOS
I'm trying to play a video with sound in an iOS application with Qt or Qml.
My environment is :
Qt 5.4
OSX Yosemite 10.10.2
iPad 2 (iOS 8.3) and Iphone6+ (iOS 8.3)
Test code (QML version):
import ...
3
votes
0
answers
719
views
Qt MediaPlayer send additional HTTP headers in source urls in QML?
I'm trying to do a video player in Qt and I'm using for that a MediaPlayer QML type. My problem is that the backend server providing the video requires additional custom http headers for handshaking. ...
3
votes
1
answer
2k
views
How to get the total time of an audio file?
How to get the total time of an audio file? I am trying this:
QMediaPlayer* audioPlayer = new QMediaPlayer();
audioPlayer->setMedia(QUrl::fromLocalFile("F:/Audio/mysong.mp3"));
audioPlayer->...
2
votes
2
answers
13k
views
module "QtMultimedia" is not installed
I've installed Qt and Qtcreator on a Raspberry Pi 3 using the normal apt-get install method. Everything seems to work fine except when I try to build the declarative-camera example or other multimedia ...
2
votes
2
answers
3k
views
QMediaplayer streaming from a custom QIODevice with encryption on Mac OS (10.9)
i'm currently porting an application from Qt4(.8.4) to Qt5(.2.0).
I'm nearly done with all the known changes like deprecated toAscii()-function, missing QtGui and so on. Now we had a music player ...
2
votes
1
answer
5k
views
pyqt5 looping mp3 file
I want to loop an audio file and using a combination of THIS CODE (my orignal question with solution) and THIS CODE (Qt C example) managed to create this:
from PyQt5.QtCore import *
from PyQt5....
2
votes
3
answers
4k
views
Building QT module from source [closed]
Can please someone explain in detail how to build a single qt module. I tried to understand the build sources documentation, but there is no info on how to build just a single module, let alone what ...
2
votes
1
answer
6k
views
Getting video frame in provided time Qt
What I want to do is to get video frame at some time (for example at 20 sec).
I know I could do something like this - rewind video and pause it:
QMediaPlayer* player = new QMediaPlayer;
...
player-&...
2
votes
2
answers
3k
views
QML data folder
Im my app based on QML I use Camera and CameraCapture to capture an image from the camera. After it was captured I want to store captured image in application data folder with CameraCapture....
2
votes
1
answer
2k
views
Replace QCameraViewfinder with QVideoWidget in Qt 6
I am trying to port some code to Qt 6's reworked QtMultimedia framework and running into a lot of issues of disappearing APIs.
One of these is QCameraViewfinder, which as I understand it, is a simple ...
2
votes
1
answer
1k
views
Qt: QAudioInput vs QAudioRecorder
I am using Qt Multimedia 5 to analyze audio (FFT, LUFS, and dBFS, etc.) from audio input device.
To get audio data, there are two main options, QAudioRecorder and QAudioInput.
They can all read audio ...
2
votes
1
answer
525
views
QMediaPlayer gives me wrong informations about video
I'm trying to implement a server terminal application which inspects video files. I need to get informations like audio/video codec, resolution, bitrate, length, etc.
I found most of the needed ...
2
votes
1
answer
2k
views
How to get a direct jump in QSlider without damaging performance
I am now creating a simple video player in QT.
I created a slider that is connected with Connect to a multimedia player (he is responsible for running the movie back and forth) and I want it to be ...
2
votes
1
answer
245
views
Qt 6.4.3 QMediaPlayer::Resource Error "Could not open file"
My organisation is using Qt 6.4.3 and using the Qt Multimedia(Widgets) module. Currently, I am unable to play any non-local files (http/https/rtsp/...) using the FFmpeg backend.
I have verified that ...