Hello everyone,
I'm trying to play .mp4 video in Qt android application using libVlc.
**Working:** When i specified **mrl** path as **mrl:"file:///home/videos/video.mp4"** it is working fine.
**not working:** when i specified **mrl** path using Qt resources(i added that .mp4 file using Qt resources) as **mrl:"qrc:///video.mp4"**
i'm getting following errors.
**core input error: open of `qrc:///video.mp4' failed
core input error: Your input can't be opened
core input error: VLC is unable to open the MRL 'qrc:///video.mp4'. Check the log for details.**
**code:**
import QtQuick 2.7
import QtQuick.Controls 2.2
import QtQuick.Layouts 1.0
import QmlVlc 0.1
import QtMultimedia 5.0
import QtQuick.Window 2.2
ApplicationWindow {
visible: true
width: Screen.width
height: Screen.height/1.1
VlcPlayer {
id: vlcPlayer;
mrl:"qrc:///video.mp4";
}
VideoOutput {
source: vlcPlayer;
anchors.centerIn: parent;
anchors.top: parent.top;
anchors.left: parent.left;
anchors.bottom: parent.bottom;
anchors.right: parent.right;
width: Screen.width-10 ;
height: Screen.height-10 ;
anchors.margins: 10
opacity: 0.9;
}
MouseArea
{
onClicked: vlcPlayer.pause();
onDoubleClicked: vlcPlayer.play(vlcPlayer.mrl);
}
}
Please help me ?
Thank you in advance.