← 返回命令列表

Linux command

ppmntsc 命令

文本

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

常用示例

Convert to NTSC-safe colors

ppmntsc [input.ppm] > [output.ppm]

Use PAL limits

ppmntsc --pal [input.ppm] > [output.ppm]

Show count of illegal pixels

ppmntsc --verbose [input.ppm] > [output.ppm]

Output only corrected pixels

ppmntsc --correctedonly [input.ppm] > [output.ppm]

说明

ppmntsc adjusts the colors in a PPM image to fall within the legal range for NTSC television broadcast. It tests each pixel and reduces saturation for those outside the legal range, while leaving compliant pixels unchanged. Colors that exceed the NTSC signal limits are clipped to the nearest legal value, preventing artifacts like blooming and color bleeding on broadcast displays. The --pal option switches to PAL broadcast limits instead. The --verbose mode reports how many pixels were illegal, helping assess whether the source image is significantly out of gamut. The filtering options (--legalonly, --illegalonly, --correctedonly) allow isolating specific pixels for analysis. Part of the Netpbm toolkit.

参数

--pal
Use PAL broadcast color limits instead of the default NTSC.
--verbose
Display a count of illegal pixels found.
--debug
Display detailed output listing each illegal color and its corrected version.
--legalonly
Output only compliant pixels; replace non-compliant ones with black.
--illegalonly
Output only non-compliant pixels uncorrected; replace compliant ones with black.
--correctedonly
Output only corrected versions of non-compliant pixels; replace compliant ones with black.

FAQ

What is the ppmntsc command used for?

ppmntsc adjusts the colors in a PPM image to fall within the legal range for NTSC television broadcast. It tests each pixel and reduces saturation for those outside the legal range, while leaving compliant pixels unchanged. Colors that exceed the NTSC signal limits are clipped to the nearest legal value, preventing artifacts like blooming and color bleeding on broadcast displays. The --pal option switches to PAL broadcast limits instead. The --verbose mode reports how many pixels were illegal, helping assess whether the source image is significantly out of gamut. The filtering options (--legalonly, --illegalonly, --correctedonly) allow isolating specific pixels for analysis. Part of the Netpbm toolkit.

How do I run a basic ppmntsc example?

Run `ppmntsc [input.ppm] > [output.ppm]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does --pal do in ppmntsc?

Use PAL broadcast color limits instead of the default NTSC.