在发布模式下使用QtMultimedia部署Qt应用程序 [英] Deploying Qt application using QtMultimedia in release mode
问题描述
我正在使用mingw47开发一个Qt 5.0 dekstop应用程序。我在这个应用程序使用QtMultimedia记录和播放音频。我已经测试它的调试,它的工作原理。当我尝试构建它的发布和运行可执行文件,我不能播放通常可以在调试模式下播放的音频文件。我在运行可执行文件之前添加了以下dll:
I am developing a Qt 5.0 dekstop application using mingw47. I use QtMultimedia in this application to record and play audio. I have tested it for debug and it works. When I try to build it for release and run the executable file, I can't play the audio file that can normally be played in debug mode. I've added the following dlls before running the executable file:
D3D_Compiler_43.dll,
icudt49.dll,
icuin49.dll,
icuuc49.dll,
libEGL.dll,
libgcc_s_sjlj-1.dll,
libGLESv2.dll,
liblibmpeg2_plugin.dll,
libstdc ++ - 6.dll,
libwinpthread-1.dll,
Qt5Core.dll,
Qt5Gui.dll,
Qt5Multimedia.dll,
Qt5Network.dll,
Qt5Widgets.dll,
Qt5Xml.dll,
plugins / platforms /(所有dll),
plugins / mediaservice /(所有dll ),
plugins / playlistformats(all dlls)
D3D_Compiler_43.dll,
icudt49.dll,
icuin49.dll,
icuuc49.dll,
libEGL.dll,
libgcc_s_sjlj-1.dll,
libGLESv2.dll,
liblibmpeg2_plugin.dll,
libstdc++-6.dll,
libwinpthread-1.dll,
Qt5Core.dll,
Qt5Gui.dll,
Qt5Multimedia.dll,
Qt5Network.dll,
Qt5Widgets.dll,
Qt5Xml.dll,
plugins/platforms/(all dlls),
plugins/mediaservice/(all dlls),
plugins/playlistformats(all dlls)
可能是错误的?或者我缺少什么其他dll?
What is probably wrong? Or what other dlls am I missing?
推荐答案
我找到了答案。现在我的应用程序工作。
I've found the answer. Now my application works. It can play audio file while running the executable file.
虽然没有列在depends.exe中,但在使用QMediaPlayer时应该添加以下dll:
Although not listed in depends.exe, we should add the following dlls when using QMediaPlayer:
Qt5MultimediaWidgetsapers
Qt5OpenGL
Qt5MultimediaWidgets
Qt5OpenGL
这里是参考: https://bugreports.qt-project.org/browse/QTBUG-30172
这篇关于在发布模式下使用QtMultimedia部署Qt应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!