Skip to content

Add configs for GIF, APNG & WEBP export and scale

Here is my patch for this weekend, I wanted to get more done especially for APNG but nevertheless this should make working with animated images much easier and the scale filter may help video too.

This patch allows animated images to set configuration options just like their video counterparts. The following has been added:

  • GIF opts: loop, transdiff, stats_mode, dithering and diff_mode

  • APNG opts: loop and pred

  • WEBP opts: lossless, compression level, quality, preset and loop

  • Scale Filter opts: bicubic, bilinear, lanczos3, neighbor and spline

There is also some minor code cleanup

Test Plan

  1. Create an animation
  2. Set custom options and export the animation as APNG
  3. Set custom options and export the animation as WEBP
  4. Set custom options and export the animation as GIF
  5. Set different scale filter and export the animation
  6. Export the animation as a video (Since video code was modified)

Formalities Checklist

  • I confirmed this builds.
  • I confirmed Krita ran and the relevant functions work.
  • I tested the relevant unit tests and can confirm they are not broken. (If not possible, don't hesitate to ask for help!)
  • I made sure my commits build individually and have good descriptions as per KDE guidelines.
  • I made sure my code conforms to the standards set in the HACKING file.
  • I can confirm the code is licensed and attributed appropriately, and that unattributed code is mine, as per KDE Licensing Policy.
Edited by Know Zero

Merge request reports