3 #ifndef Q_VIDEO_ENCODE_HEADER
4 #define Q_VIDEO_ENCODE_HEADER
40 bool open(QString formatShortName, QStringList& errors);
48 QString* errorString =
nullptr);
62 bool ignoreIfNoFileExtension =
true);
std::shared_ptr< core::Tensor > image
Video encoder based on FFmpeg.
virtual bool encodeImage(const QImage &image, int frameIndex, QString *errorString=nullptr)
Adds an image to the stream.
bool isSizeValid()
Returns whether the image size is valid.
virtual bool close()
Closes the file.
bool convertImage_sws(const QImage &image, QString *errorString=nullptr)
Convert the QImage to the internal YUV format.
bool open(QString formatShortName, QStringList &errors)
Creates an (empty) video/anmiation file.
bool isOpen() const
Returns whether the file is opened or not.
static bool GetSupportedOutputFormats(std::vector< OutputFormat > &formats, bool ignoreIfNoFileExtension=true)
Returns the list of supported output formats.
FFmpegStuffEnc * m_ff
FFmpeg variables.
QVideoEncoder(QString filename, int width, int height, unsigned bitrate, int gop=12, int fps=25)
Default constructor.