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

17 lines
641 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.

# pamfix
> 修复 PAM、PBM、PGM 和 PPM 文件中的错误。
> 另见:`pamfile``pamvalidate`。
> 更多信息:<https://netpbm.sourceforge.net/doc/pamfix.html>。
- 修复缺少最后部分的 Netpbm 文件:
`pamfix -truncate {{path/to/corrupted.ext}} > {{path/to/output.ext}}`
- 通过降低有问题的像素值来修复像素值超过图像 `maxval` 的 Netpbm 文件:
`pamfix -clip {{path/to/corrupted.ext}} > {{path/to/output.ext}}`
- 通过增加 `maxval` 来修复像素值超过图像 `maxval` 的 Netpbm 文件:
`pamfix -changemaxval {{path/to/corrupted.pam|pbm|pgm|ppm}} > {{path/to/output.pam|pbm|pgm|ppm}}`