From 54e09bf52bf07fa4f160f56bebe45ead9b4bfa56 Mon Sep 17 00:00:00 2001 From: "C. McEnroe" Date: Tue, 21 Sep 2021 15:02:46 -0400 Subject: Rewrite pngo, add explicit options Interesting to see how my code habits have changed. --- bin/man1/pngo.1 | 56 ++++++++++++++++++++++++++++++++------------------------ 1 file changed, 32 insertions(+), 24 deletions(-) (limited to 'bin/man1') diff --git a/bin/man1/pngo.1 b/bin/man1/pngo.1 index cec13160..a235355b 100644 --- a/bin/man1/pngo.1 +++ b/bin/man1/pngo.1 @@ -1,4 +1,4 @@ -.Dd September 17, 2018 +.Dd September 21, 2021 .Dt PNGO 1 .Os . @@ -8,30 +8,17 @@ . .Sh SYNOPSIS .Nm -.Op Fl cv +.Op Fl acgv +.Op Fl b Ar depth .Op Fl o Ar file .Op Ar . .Sh DESCRIPTION .Nm -optimizes PNG files for size. -. -.Pp -The arguments are as follows: -.Bl -tag -width Ds -.It Fl c -Write to standard output. -.It Fl o Ar file -Write to -.Ar file . -.It Fl v -Output PNG header information. -.El -. +optimizes PNG files for size +by performing the following: .Pp -.Nm -performs the following optimizations: -.Bl -bullet +.Bl -enum -compact .It Discard ancillary chunks. .It @@ -39,18 +26,39 @@ Discard unnecessary alpha channel. .It Convert unnecessary truecolor to grayscale. .It -Palletize color and alpha if possible. +Palletize color if possible. .It -Reduce bit depth if possible. +Reduce unnecessary bit depth. .It -Apply a simple filter heuristic. +Apply a simple filter type heuristic. .It -Apply zlib's best compresion. +Apply zlib's best compression. +.El +. +.Pp +The arguments are as follows: +.Bl -tag -width Ds +.It Fl a +Always discard the alpha channel. +.It Fl b Ar depth +Reduce bit depth to +.Ar depth +or lower. +.It Fl c +Write to standard output. +.It Fl g +Convert to grayscale. +.It Fl o Ar file +Write to +.Ar file . +.It Fl v +Print header information and sizes +to standard error. .El . .Sh SEE ALSO .Xr glitch 1 . -.Sh CAVEATS +.Sh BUGS .Nm does not support interlaced PNGs. -- cgit 1.4.1