← 返回命令列表

Linux command

pamscale 命令

趣味

涉及管道、覆盖或删除,执行前请先确认路径和参数。

常用示例

Scale to specific size

pamscale -width [800] -height [600] [input.pam] > [output.pam]

Scale by factor

pamscale [0.5] [input.pam] > [half.pam]

Scale preserving aspect ratio

pamscale -xyfit [800] [600] [input.pam] > [output.pam]

Scale width only

pamscale -xsize [800] [input.pam] > [output.pam]

High quality scaling

pamscale -filter=lanczos [0.5] [input.pam] > [output.pam]

说明

pamscale resizes PAM/PNM images using high-quality resampling. It can scale by factor, to specific dimensions, or fit within a bounding box while preserving aspect ratio.

参数

scale
Scale factor (0.5 = half).
-width, -xsize _n_
Output width.
-height, -ysize _n_
Output height.
-xyfit _w_ _h_
Fit within box, keep aspect.
-filter _name_
Resampling filter.
-linear
Linear interpolation.

FAQ

What is the pamscale command used for?

pamscale resizes PAM/PNM images using high-quality resampling. It can scale by factor, to specific dimensions, or fit within a bounding box while preserving aspect ratio.

How do I run a basic pamscale example?

Run `pamscale -width [800] -height [600] [input.pam] > [output.pam]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does scale do in pamscale?

Scale factor (0.5 = half).