#include <QtAV>
#include <QtAVWidgets>
...
GLWidgetRenderer2 renderer;
renderer.show();
AVPlayer player;
player.setRenderer(&renderer);
player.play("test.avi");
|
import QtQuick 2.0
import QtAV 1.6
Item {
VideoOutput2 {
anchors.fill: parent
source: player
}
AVPlayer { //or MediaPlayer
id: player
source: "test.mp4"
}
MouseArea {
anchors.fill: parent
onClicked: player.play()
}
}
|