volumetric-regimes-book/command-line/tools/rgb2cmyk.sh

15 lines
277 B
Bash
Raw Normal View History

2022-06-09 10:08:24 +02:00
#! /bin/bash
# CONVERTS RGB PDF TO CMYK PDF PRESERVING TRUE BLACK FOR VECTORS
# USAGE:
# ./rgb2cmyk.sh input.pdf
# OUTPUT:
# input-cmyk.pdf
bn=$(basename $1 ".pdf")
gs -q -sDEVICE=pdfwrite -o ${bn}-CMYK.pdf -sColorConversionStrategy=CMYK -sSourceObjectICC=control.txt $1