This page covers the availability of Qt Multimedia features on iOS and macOS.
Since Qt Multimedia for iOS uses the camera and microphone, the
Info.plist
assigned to QMAKE_INFO_PLIST in the project file must contain the keys
NSCameraUsageDescription
and
NSMicrophoneUsageDescription
. Otherwise, the application will abort on startup. See
Info.plist
documentation from Apple for more information regarding this key.
FFmpeg binaries from the online installer must be embedded into the application's bundle. To embed these libraries, you can add the qt6_add_ios_ffmpeg_libraries() command to the app's CMakeLists.txt file:
qt_add_ios_ffmpeg_libraries(mytarget)
When using QMake, add the following to your
.pro
文件:
CONFIG += add_ios_ffmpeg_libraries
注意: The FFmpeg binaries from the online installer are built for arm64 and x86_64-simulator to ensure they pass validation with Apple Store Connect and can be used when running the iOS simulator.
注意: A limitation in Qt Multimedia builds that include FFmpeg support, is that FFmpeg libraries must be provided at link-time when building iOS applications. Failing to do so will result in linker errors. This includes the Qt Multimedia builds supplied by Qt Maintenance Tool. Applications that use such builds are required to call qt_add_ios_ffmpeg_libraries , or otherwise link their own FFmpeg libraries. As a consequence, application developers that wish to deploy iOS applications without FFmpeg, must build their own build of Qt Multimedia without FFmpeg support.