1// Copyright (C) 2021 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QPLATFORMMEDIAFORMATINFO_H
5#define QPLATFORMMEDIAFORMATINFO_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists purely as an
12// implementation detail. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <private/qtmultimediaglobal_p.h>
19#include <qimagecapture.h>
20#include <qmediaformat.h>
21
22QT_BEGIN_NAMESPACE
23
24class Q_MULTIMEDIA_EXPORT QPlatformMediaFormatInfo
25{
26public:
27 QPlatformMediaFormatInfo();
28 virtual ~QPlatformMediaFormatInfo();
29
30 QList<QMediaFormat::FileFormat> supportedFileFormats(const QMediaFormat &constraints, QMediaFormat::ConversionMode m) const;
31 QList<QMediaFormat::AudioCodec> supportedAudioCodecs(const QMediaFormat &constraints, QMediaFormat::ConversionMode m) const;
32 QList<QMediaFormat::VideoCodec> supportedVideoCodecs(const QMediaFormat &constraints, QMediaFormat::ConversionMode m) const;
33
34 bool isSupported(const QMediaFormat &format, QMediaFormat::ConversionMode m) const;
35
36 struct CodecMap {
37 QMediaFormat::FileFormat format;
38 QList<QMediaFormat::AudioCodec> audio;
39 QList<QMediaFormat::VideoCodec> video;
40 };
41 QList<CodecMap> encoders;
42 QList<CodecMap> decoders;
43
44 QList<QImageCapture::FileFormat> imageFormats;
45};
46
47QT_END_NAMESPACE
48
49
50#endif // QPLATFORMMEDIAFORMATINFO_H
51

source code of qtmultimedia/src/multimedia/platform/qplatformmediaformatinfo_p.h