diff options
author | Lars Knoll <lars.knoll@qt.io> | 2021-02-04 19:57:09 +0100 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2021-02-09 14:34:54 +0000 |
commit | 0eb4012490601a3d45bd7239e117ae583d71dc97 (patch) | |
tree | 61e502a4d0f3931d1327981c9e4171c1e5405cd3 /src/multimedia/qmediaformat.h | |
parent | 7b963b971afb942f7b7f6da5374fae251e8af887 (diff) |
Add support for retrieving a mimetype for a QMediaFormat
And remove WMA from the list of supported codecs, add ALAC
instead as it's more widely used.
Change-Id: I3c08f2d1871783dc1e15c948e2ec9a7a033cb917
Reviewed-by: Doris Verria <doris.verria@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/multimedia/qmediaformat.h')
-rw-r--r-- | src/multimedia/qmediaformat.h | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/multimedia/qmediaformat.h b/src/multimedia/qmediaformat.h index 69e795545..a488fd378 100644 --- a/src/multimedia/qmediaformat.h +++ b/src/multimedia/qmediaformat.h @@ -46,6 +46,7 @@ QT_BEGIN_NAMESPACE +class QMimeType; class QMediaFormat; class QMediaEncoderSettings; class QMediaFormatPrivate @@ -72,10 +73,9 @@ public: FLAC, MP3, Mpeg4Audio, - Opus, + ALAC, Wave, - WindowsMediaAudio, - LastFileFormat = WindowsMediaAudio + LastFileFormat = Wave }; enum class AudioCodec { @@ -89,8 +89,8 @@ public: Opus, Vorbis, Wave, - WindowsMediaAudio, - LastAudioCodec = WindowsMediaAudio + ALAC, + LastAudioCodec = ALAC }; enum class VideoCodec { @@ -127,6 +127,8 @@ public: bool isAudioFormat() const; + QMimeType mimeType() const; + static QString fileFormatName(QMediaFormat::FileFormat c); static QString audioCodecName(QMediaFormat::AudioCodec c); static QString videoCodecName(QMediaFormat::VideoCodec c); |