Я хочу конвертировать PDF в оттенки серого, используя mutool
. есть вариант для градации серого в convert
, но я не знаю , как запустить его там нет никакой документации, вот что я пытаюсь запустить
$ mutool convert colorspace=gray input.pdf output.pdf
но это не работает, это просто показывает документацию, как показано ниже
$ mutool convert
mutool convert version 1.10a
Usage: mutool convert [options] file [pages]
-p - password
-A - number of bits of antialiasing (0 to 8)
-W - page width for EPUB layout
-H - page height for EPUB layout
-S - font size for EPUB layout
-U - file name of user stylesheet for EPUB layout
-o - output file name (%d for page number)
-F - output format (default inferred from output file name)
cbz, pdf, png
-O - comma separated list of options for output format
pages comma separated list of page ranges (N=last page)
Common raster format output options:
rotate=N: rotate rendered pages N degrees counterclockwise
resolution=N: set both X and Y resolution of rendered pages in pixels per inch
x-resolution=N: X resolution of rendered pages in pixels per inch
y-resolution=N: Y resolution of rendered pages in pixels per inch
width=N: render pages to fit N pixels wide (ignore resolution option)
height=N: render pages to fit N pixels tall (ignore resolution option)
colorspace=(gray|rgb|cmyk): render using specified colorspace
alpha: render pages with alpha channel and transparent background
Structured text output options:
preserve-ligatures: do not expand all ligatures into constituent characters
preserve-whitespace: do not convert all whitespace characters into spaces
PDF output options:
decompress: decompress all streams (except compress-fonts/images)
compress: compress all streams
compress-fonts: compress embedded fonts
compress-images: compress images
ascii: ASCII hex encode binary streams
pretty: pretty-print objects with indentation
linearize: optimize for web browsers
sanitize: clean up graphics commands in content streams
garbage: garbage collect unused objects
or garbage=compact: ... and compact cross reference table
or garbage=deduplicate: ... and remove duplicate objects