Linux command
pngtopam 命令
文本
涉及管道、覆盖或删除,执行前请先确认路径和参数。
常用示例
Convert PNG to PAM
pngtopam [input.png] > [output.pam]
Convert with alpha channel
pngtopam -alpha [input.png] > [output.pam]
说明
pngtopam converts a PNG image to a PAM (Portable Arbitrary Map) image. Part of the Netpbm toolkit, it preserves transparency when -alphapam is specified. If the input has no transparency, the output is typically an RGB or grayscale PAM.
参数
- -alphapam
- Output a PAM with tuple type depending on the PNG (supports transparency).
- -alpha
- Extract only the alpha channel as a PGM-style PAM.
- -mix
- Composite the image against a background color when transparency is present.
- -background _color_
- Specify the background color used with -mix (e.g., "rgb:FF/FF/FF" or a color name).
- -gamma _value_
- Set the gamma value used for display correction.
- -text
- Emit any tEXt chunks from the PNG to stderr.
- -verbose
- Print information about the conversion to stderr.
FAQ
What is the pngtopam command used for?
pngtopam converts a PNG image to a PAM (Portable Arbitrary Map) image. Part of the Netpbm toolkit, it preserves transparency when -alphapam is specified. If the input has no transparency, the output is typically an RGB or grayscale PAM.
How do I run a basic pngtopam example?
Run `pngtopam [input.png] > [output.pam]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -alphapam do in pngtopam?
Output a PAM with tuple type depending on the PNG (supports transparency).