Skip to content

Animated corruption

andreweathan edited this page May 14, 2023 · 11 revisions

These parameters let you control the result of animated corruption.

int -randshift (default 0, any number above 0)

This adds randomness to -shift! -shift doesn't need to be non-zero for this to work.

percent -breaks (default 0, 0-100)

The chance that decides whether pngsmasher corrupts a frame of an animated image, or leaves it alone.
This is useful if you want an image to have gaps in between corrupted images, hence the name (taking a break)

Original Without -breaks -breaks 50
original cioss_nobreaks cioss_breaks

#2: pngsmasher.cli -input cioss.png -frames 30 -fps 10 -crunch 60 -seed 100 -splits 1 -shift -1 -div 1 +bg -rmin -10 -rmax -8 -randshift 1
#3: pngsmasher.cli -input cioss.png -frames 30 -fps 10 -crunch 60 -seed 100 -splits 1 -shift -1 -div 1 +bg -rmin -10 -rmax -8 -randshift 1 -breaks 50

These 2 parameters let you turn a single-frame PNG into an animated corrupted APNG!
To enable this, set -frames and -fps to anything other than 0.
These won't work for APNG inputs, only for single-frame PNGs!

int -frames (default 0, no max limit)

How many corrupted frames the APNG should have.

int -fps (default 0, no max limit)

How many frames per second the APNG should play at. This applies to both animated corruption and APNG inputs!

bool -/+defaultfpsonbreak (default false) (needs -breaks to work)

Makes it so that the fps is default when "taking a break" (-breaks), but when not, the fps is set to -fps.

bool -/+nofxonbreak (default false)

By default, pngsmasher applies contrast, NTSC, and other non-corrupting effects during a break. This option makes frames "on break" to be identical to the input.