LinuxCommandLibrary

pnmgamma

Apply gamma correction to PNM images

TLDR

Apply gamma correction
$ pnmgamma [gamma] [input.pnm] > [output.pnm]
copy
Brighten image
$ pnmgamma 2.2 [input.pnm] > [output.pnm]
copy
Darken image
$ pnmgamma 0.5 [input.pnm] > [output.pnm]
copy
Per-channel gamma
$ pnmgamma [r_gamma] [g_gamma] [b_gamma] [input.pnm] > [output.pnm]
copy

SYNOPSIS

pnmgamma [options] gamma [file]

DESCRIPTION

pnmgamma applies gamma correction to PNM images, adjusting the brightness curve by raising each pixel value to a power function. Values greater than 1 brighten the image while values less than 1 darken it.
Per-channel gamma values can be specified separately for red, green, and blue. The -ungamma option reverses a previously applied gamma correction. Part of the Netpbm toolkit; superseded by pamgamma.

PARAMETERS

GAMMA

Gamma correction value.
FILE
Input PNM file.
-ungamma
Remove gamma correction.
-cieramp
Use CIE luminance ramp.

CAVEATS

Values >1 brighten, <1 darken. Part of Netpbm suite.

HISTORY

pnmgamma was created as part of Netpbm for gamma correction operations.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard