Also tweaked the notes/docs about resulting encoded video output.
implementation writes each video frame to a PNG image in the current
directory.~~
-Video decoding and encoding is finished, but there is some noticable drops in
-quality when encoding to colored dithered video. It may be better to just
-output each frame to individual PNGs, then combining them later just like as
-mentioned here: https://trac.ffmpeg.org/wiki/Slideshow .
+Video decoding and encoding is finished, ~~but there is some noticable drops in
+quality when encoding to colored dithered video~~ but the resulting video may
+end up being too large. It may be better to just output each frame to individual
+PNGs, then combining them later just like as mentioned here with the params you
+want set: https://trac.ffmpeg.org/wiki/Slideshow .
# Other Notes
enc_codec_context->height = height;
enc_stream->time_base = time_base;
enc_codec_context->time_base = time_base;
- enc_codec_context->gop_size = 12;
+ enc_codec_context->gop_size = 128;
enc_codec_context->global_quality = 23;
+ enc_codec_context->qmax = 35;
+ enc_codec_context->qmin = 20;
enc_codec_context->pix_fmt = AVPixelFormat::AV_PIX_FMT_YUV444P;
if (avf_enc_context->oformat->flags & AVFMT_GLOBALHEADER) {
enc_codec_context->flags |= AV_CODEC_FLAG_GLOBAL_HEADER;
* \brief Dithers the frames in the input video.
*
* If output_as_pngs is true, then the output will be individaul PNGs of each
- * frame instead of a video file. This may be desireable because the output
- * video struggles to maintain video quality.
+ * frame instead of a video file. This may be desireable for more control over
+ * the params set when encoding the resulting video.
*
* \return True on success.
*/