Files
tldr/pages.zh/common/ppmtoxpm.md

20 lines
710 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# ppmtoxpm
> 将PPM图像转换为X11版本3的位图。
> 更多信息:<https://netpbm.sourceforge.net/doc/ppmtoxpm.html>。
- 将PPM图像转换为XPM图像
`ppmtoxpm {{path/to/input_file.ppm}} > {{path/to/output_file.xpm}}`
- 在输出的XPM图像中指定前缀字符串
`ppmtoxpm -name {{prefix_string}} {{path/to/input_file.ppm}} > {{path/to/output_file.xpm}}`
- 在输出的XPM文件中通过十六进制代码指定颜色而不是通过名称
`ppmtoxpm -hexonly {{path/to/input_file.ppm}} > {{path/to/output_file.xpm}}`
- 使用指定的PGM文件作为透明度遮罩
`ppmtoxpm -alphamask {{path/to/alpha_file.pgm}} {{path/to/input_file.ppm}} > {{path/to/output_file.xpm}}`