![]() |
Miam-Player
0.8.0
A nice music player
|
#include <VideoEncoder.h>
Signals | |
void | widthChanged () |
void | heightChanged () |
void | frameRateChanged () |
void | pixelFormatChanged () |
![]() | |
void | error (const QtAV::AVError &e) |
void | codecNameChanged () |
void | bitRateChanged () |
void | timestampModeChanged (TimestampMode mode) |
Public Member Functions | |
virtual VideoEncoderId | id () const =0 |
QString | name () const Q_DECL_OVERRIDE |
virtual bool | encode (const VideoFrame &frame=VideoFrame())=0 |
encode encode a video frame to a Packet More... | |
void | setWidth (int value) |
output parameters More... | |
int | width () const |
void | setHeight (int value) |
int | height () const |
void | setFrameRate (qreal value) |
TODO: check avctx->supported_framerates. use frame_rate_used. More... | |
qreal | frameRate () const |
void | setPixelFormat (const VideoFormat::PixelFormat format) |
setPixelFormat If not set or set to an invalid format, a supported format will be used and pixelFormat() will be that format after open() More... | |
VideoFormat::PixelFormat | pixelFormat () const |
![]() | |
virtual | ~AVEncoder () |
virtual QString | description () const |
void | setCodecName (const QString &name) |
setCodecName An encoder can support more than 1 codec. More... | |
QString | codecName () const |
bool | open () |
bool | close () |
bool | isOpen () const |
virtual void | flush () |
Packet | encoded () const |
virtual void | copyAVCodecContext (void *ctx) |
used by ff muxer. More... | |
void * | codecContext () const |
void | setBitRate (int value) |
setBitRate Higher bit rate result in better quality. More... | |
int | bitRate () const |
TimestampMode | timestampMode () const |
void | setTimestampMode (TimestampMode value) |
void | setOptions (const QVariantHash &dict) |
setOptions More... | |
QVariantHash | options () const |
Static Public Member Functions | |
static QStringList | supportedCodecs () |
static VideoEncoder * | create (VideoEncoderId id) |
static VideoEncoder * | create (const char *name="FFmpeg") |
create create an encoder from registered names More... | |
static qreal | defaultFrameRate () |
template<class C > | |
static bool | Register (VideoEncoderId id, const char *name) |
static VideoEncoderId * | next (VideoEncoderId *id=0) |
next More... | |
static const char * | name (VideoEncoderId id) |
static VideoEncoderId | id (const char *name) |
Protected Member Functions | |
VideoEncoder (VideoEncoderPrivate &d) | |
![]() | |
AVEncoder (AVEncoderPrivate &d) | |
Properties | |
int | width |
int | height |
qreal | frameRate |
QtAV::VideoFormat::PixelFormat | pixelFormat |
![]() | |
int | bitRate |
QString | codecName |
TimestampMode | timestampMode |
Additional Inherited Members | |
![]() | |
enum | TimestampMode { TimestampMonotonic, TimestampCopy } |
|
protected |
|
static |
|
static |
create create an encoder from registered names
name | can be "FFmpeg". FFmpeg encoder will be created for empty name |
|
inlinestatic |
|
pure virtual |
encode encode a video frame to a Packet
frame | pass an invalid frame to get delayed frames |
qreal QtAV::VideoEncoder::frameRate | ( | ) | const |
|
signal |
int QtAV::VideoEncoder::height | ( | ) | const |
|
signal |
|
pure virtual |
|
static |
|
virtual |
Implements QtAV::AVEncoder.
|
static |
|
static |
next
id | NULL to get the first id address |
VideoFormat::PixelFormat QtAV::VideoEncoder::pixelFormat | ( | ) | const |
|
signal |
|
inlinestatic |
void QtAV::VideoEncoder::setFrameRate | ( | qreal | value | ) |
TODO: check avctx->supported_framerates. use frame_rate_used.
setFrameRate If frame rate is not set, frameRate() returns -1, but internally the default frame rate 25 will be used
value |
void QtAV::VideoEncoder::setHeight | ( | int | value | ) |
void QtAV::VideoEncoder::setPixelFormat | ( | const VideoFormat::PixelFormat | format | ) |
setPixelFormat If not set or set to an invalid format, a supported format will be used and pixelFormat() will be that format after open()
format |
void QtAV::VideoEncoder::setWidth | ( | int | value | ) |
output parameters
setWidth set the encoded video width. The same as input frame size if value <= 0
|
static |
int QtAV::VideoEncoder::width | ( | ) | const |
|
signal |
|
readwrite |
|
readwrite |
|
readwrite |
|
readwrite |