编译QtAV工程库
去https://github.com/wang-bin/QtAV下載源代碼
?
去https://sourceforge.net/projects/qtav/files/depends/QtAV-depends-windows-x86%2Bx64.7z/download下載依賴庫(kù)QtAV-depends-windows-x86+x64.7z
將里面的include目錄內(nèi)容和lib內(nèi)容分別拷貝到Qt的include和lib目錄下
?
QtAV解壓后用Qt Creator打開(kāi)QtAV.pro
?
工程名QtAV右鍵-Run qmake
依次Build libQtAV,libQtAVWidgets,libQMLAV
在build-QtAV-Desktop_Qt_5_5_0_MSVC2013_32bit-Debug\lib_win_x86生成對(duì)應(yīng)QmlAVd.dll,QtAVd1.dll,QtAVWidgetsd1.dll以及l(fā)ib文件
在build-QtAV-Desktop_Qt_5_5_0_MSVC2013_32bit-Release\lib_win_x86生成對(duì)應(yīng)QmlAV.dll,QtAV1.dll,QtAVWidgets1.dll以及l(fā)ib文件
?
開(kāi)發(fā)使用時(shí),頭文件使用QtAV-master\src\QtAV文件夾和QtAV-master\widgets\QtAVWidgets文件夾
.pro文件
CONFIG(debug, debug|release):LIBS += -L$$PWD/QtAV/lib -lQtAVd1 -lQtAVWidgetsd1
CONFIG(release, debug|release):LIBS += -L$$PWD/QtAV/lib -lQtAV1 -lQtAVWidgets1
?
QtAV::GLWidgetRenderer2* renderer = new QtAV::GLWidgetRenderer2; _player = new QtAV::AVPlayer; _player->setRenderer(renderer); _player->play(appDir+"/media/Wildlife.wmv"); gridLayout->addWidget( renderer, 0,0,1,4 );?
轉(zhuǎn)載于:https://www.cnblogs.com/coolbear/p/5473460.html
總結(jié)
- 上一篇: 近期H5项目开发小结
- 下一篇: 谈谈软件兼容性测试