Details
-
Sub-task
-
Resolution: Out of scope
-
P2: Important
-
None
Description
Several APIs use codec names (audio, video, or container) as argument or as return value (e.g. QMediaPlayer::hasSupport(), QVideoEncoderSettings::setCodec(), QMediaRecorder::supportedAudioCodecs() and so on).
These names are inconsistent across platforms, for example H.264 is called "avc1" on OSX/iOS and "video/x-h264" with GStreamer.
We should standardize these names so that it's consistent on all platforms.
Codec names should have a dedicated API.
Possible solutions are:
- Using a string like QMediaMetaData (for example const QString QMediaType::H264 = "video/x-264".
- Using an enum and a helper function to get the associated string. This solution could also mean deprecating the existing codec APIs and adding new ones that use the enum instead.
- Using a new class, QMediaType. This solution would require to deprecate the existing API.
In any case, any string representation of a codec should be based on the IANA media type list (http://www.iana.org/assignments/media-types/media-types.xhtml)
Attachments
Issue Links
- relates to
-
QTBUG-56184 Add API to get media file extensions
-
- Closed
-