| 1 | // Copyright (C) 2024 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 QFFMPEGCODECSTORAGE_P_H | 
|---|
| 5 | #define QFFMPEGCODECSTORAGE_P_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 <QtFFmpegMediaPluginImpl/private/qffmpegdefs_p.h> | 
|---|
| 19 | #include "qtmultimediaglobal.h" | 
|---|
| 20 |  | 
|---|
| 21 | #include <functional> | 
|---|
| 22 | #include <optional> | 
|---|
| 23 |  | 
|---|
| 24 | QT_BEGIN_NAMESPACE | 
|---|
| 25 |  | 
|---|
| 26 | namespace QFFmpeg { | 
|---|
| 27 | class Codec; | 
|---|
| 28 |  | 
|---|
| 29 | bool findAndOpenAVDecoder(AVCodecID codecId, | 
|---|
| 30 | const std::function<AVScore(const Codec &)> &scoresGetter, | 
|---|
| 31 | const std::function<bool(const Codec &)> &codecOpener); | 
|---|
| 32 |  | 
|---|
| 33 | bool findAndOpenAVEncoder(AVCodecID codecId, | 
|---|
| 34 | const std::function<AVScore(const Codec &)> &scoresGetter, | 
|---|
| 35 | const std::function<bool(const Codec &)> &codecOpener); | 
|---|
| 36 |  | 
|---|
| 37 | std::optional<Codec> findAVDecoder(AVCodecID codecId, | 
|---|
| 38 | const std::optional<PixelOrSampleFormat> &format = {}); | 
|---|
| 39 |  | 
|---|
| 40 | std::optional<Codec> findAVEncoder(AVCodecID codecId, | 
|---|
| 41 | const std::optional<PixelOrSampleFormat> &format = {}); | 
|---|
| 42 |  | 
|---|
| 43 | } // namespace QFFmpeg | 
|---|
| 44 |  | 
|---|
| 45 | QT_END_NAMESPACE | 
|---|
| 46 |  | 
|---|
| 47 | #endif // QFFMPEGCODECSTORAGE_P_H | 
|---|
| 48 |  | 
|---|