Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qffmpegvideoencoderutils_p.h
Go to the documentation of this file.
1// Copyright (C) 2022 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#ifndef QFFMPEGVIDEOENCODERUTILS_P_H
4#define QFFMPEGVIDEOENCODERUTILS_P_H
5
6//
7// W A R N I N G
8// -------------
9//
10// This file is not part of the Qt API. It exists purely as an
11// implementation detail. This header file may change from version to
12// version without notice, or even be removed.
13//
14// We mean it.
15//
16
17#include "qffmpeg_p.h"
18#include "qffmpeghwaccel_p.h"
19
21
22namespace QFFmpeg {
23
24AVPixelFormat findTargetSWFormat(AVPixelFormat sourceSWFormat, const AVCodec *codec,
25 const HWAccel &accel);
26
27AVPixelFormat findTargetFormat(AVPixelFormat sourceFormat, AVPixelFormat sourceSWFormat,
28 const AVCodec *codec, const HWAccel *accel);
29
30std::pair<const AVCodec *, std::unique_ptr<HWAccel>> findHwEncoder(AVCodecID codecID,
31 const QSize &sourceSize);
32
33const AVCodec *findSwEncoder(AVCodecID codecID, AVPixelFormat sourceSWFormat);
34
41AVRational adjustFrameRate(const AVRational *supportedRates, qreal requestedRate);
42
56AVRational adjustFrameTimeBase(const AVRational *supportedRates, AVRational frameRate);
57
58QSize adjustVideoResolution(const AVCodec *codec, QSize requestedResolution);
59
60} // namespace QFFmpeg
61
63
64#endif // QFFMPEGVIDEOENCODERUTILS_P_H
\inmodule QtCore
Definition qsize.h:25
AVPixelFormat findTargetFormat(AVPixelFormat sourceFormat, AVPixelFormat sourceSWFormat, const AVCodec *codec, const HWAccel *accel)
QSize adjustVideoResolution(const AVCodec *codec, QSize requestedResolution)
std::pair< const AVCodec *, std::unique_ptr< HWAccel > > findHwEncoder(AVCodecID codecID, const QSize &resolution)
const AVCodec * findSwEncoder(AVCodecID codecID, AVPixelFormat sourceSWFormat)
AVRational adjustFrameRate(const AVRational *supportedRates, qreal requestedRate)
adjustFrameRate get a rational frame rate be requested qreal rate. If the codec supports fixed frame ...
AVPixelFormat findTargetSWFormat(AVPixelFormat sourceSWFormat, const AVCodec *codec, const HWAccel &accel)
AVRational adjustFrameTimeBase(const AVRational *supportedRates, AVRational frameRate)
adjustFrameTimeBase gets adjusted timebase by a list of supported frame rates and an already adjusted...
Combined button and popup list for selecting options.
QMediaFormat::AudioCodec codec
double qreal
Definition qtypes.h:187