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
QFFmpeg::VideoFrameEncoder Class Reference

#include <qffmpegvideoframeencoder_p.h>

+ Collaboration diagram for QFFmpeg::VideoFrameEncoder:

Public Member Functions

 ~VideoFrameEncoder ()
 
bool open ()
 
AVPixelFormat sourceFormat () const
 
AVPixelFormat targetFormat () const
 
qint64 getPts (qint64 ms) const
 
const AVRational & getTimeBase () const
 
int sendFrame (AVFrameUPtr frame)
 
AVPacketUPtr retrievePacket ()
 

Static Public Member Functions

static std::unique_ptr< VideoFrameEncodercreate (const QMediaEncoderSettings &encoderSettings, const QSize &sourceSize, qreal sourceFrameRate, AVPixelFormat sourceFormat, AVPixelFormat sourceSWFormat, AVFormatContext *formatContext)
 

Detailed Description

Definition at line 26 of file qffmpegvideoframeencoder_p.h.

Constructor & Destructor Documentation

◆ ~VideoFrameEncoder()

QFFmpeg::VideoFrameEncoder::~VideoFrameEncoder ( )
default

Member Function Documentation

◆ create()

std::unique_ptr< VideoFrameEncoder > QFFmpeg::VideoFrameEncoder::create ( const QMediaEncoderSettings & encoderSettings,
const QSize & sourceSize,
qreal sourceFrameRate,
AVPixelFormat sourceFormat,
AVPixelFormat sourceSWFormat,
AVFormatContext * formatContext )
static

Definition at line 17 of file qffmpegvideoframeencoder.cpp.

References QFFmpeg::isHwPixelFormat(), QFFmpeg::isSwPixelFormat(), Q_ASSERT, and sourceFormat().

Referenced by QFFmpeg::VideoEncoder::VideoEncoder().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getPts()

qint64 QFFmpeg::VideoFrameEncoder::getPts ( qint64 ms) const

Definition at line 208 of file qffmpegvideoframeencoder.cpp.

◆ getTimeBase()

const AVRational & QFFmpeg::VideoFrameEncoder::getTimeBase ( ) const

Definition at line 214 of file qffmpegvideoframeencoder.cpp.

◆ open()

bool QFFmpeg::VideoFrameEncoder::open ( )

Definition at line 188 of file qffmpegvideoframeencoder.cpp.

References QFFmpeg::applyExperimentalCodecOptions(), QFFmpeg::applyVideoEncoderOptions(), QFFmpeg::err2str(), qCDebug, and qWarning.

+ Here is the call graph for this function:

◆ retrievePacket()

AVPacketUPtr QFFmpeg::VideoFrameEncoder::retrievePacket ( )

Definition at line 307 of file qffmpegvideoframeencoder.cpp.

References QFFmpeg::err2str(), qCDebug, qCWarning, ret, and QFFmpeg::timeStampMs().

+ Here is the call graph for this function:

◆ sendFrame()

int QFFmpeg::VideoFrameEncoder::sendFrame ( AVFrameUPtr frame)

Definition at line 219 of file qffmpegvideoframeencoder.cpp.

References QFFmpeg::err2str(), frame, frameSize(), QFFmpeg::getAVFrameTime(), QSize::height(), QWidget::height, hwFramesContext, QFFmpeg::makeAVFrame(), Q_ASSERT, qCDebug, qCWarning, qWarning, QFFmpeg::setAVFrameTime(), QMediaEncoderSettings::videoResolution(), QSize::width(), and QWidget::width.

+ Here is the call graph for this function:

◆ sourceFormat()

AVPixelFormat QFFmpeg::VideoFrameEncoder::sourceFormat ( ) const
inline

Definition at line 39 of file qffmpegvideoframeencoder_p.h.

Referenced by create().

+ Here is the caller graph for this function:

◆ targetFormat()

AVPixelFormat QFFmpeg::VideoFrameEncoder::targetFormat ( ) const
inline

Definition at line 40 of file qffmpegvideoframeencoder_p.h.


The documentation for this class was generated from the following files: