Graphics, Figures & TablesGrayscale output with latex (via GS)

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
Faust
Posts: 55
Joined: Thu Oct 29, 2009 12:45 pm

Grayscale output with latex (via GS)

Post by Faust »

I have been asked to supply a black/white copy of some pdf's.

I presume this is for decreased size and for those who do not own a color printer.

Anyways, I have 2 questions regarding this:

-is there a way to make grayscale pfs with pdf2latex (what command if there is)

-Im using the latex- ps- pdf route via ghostscript and added commands for grayscale output, however this is as fast as a snale in hibernation. Is there a way to speed it up? I used this:

Arguments for the ghostscript postprocessing in the profile I made:

-sPAPERSIZE=a4 -sColorConversionStrategy=Gray -dProcessColorModel=/DeviceGray -dSAFER -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile="%bm.pdf" -c save pop -f "%bm.ps"


it looks nice and grey though but took like 5 mins to build.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

phi
Posts: 577
Joined: Tue Oct 21, 2008 8:10 pm

Grayscale output with latex (via GS)

Post by phi »

Try \selectcolormodel from the xcolor package:

Code: Select all

Code, edit and compile here:
\documentclass{article}
\usepackage{xcolor}
\selectcolormodel{gray}
\begin{document}
\textcolor{blue}{\rule{5cm}{2cm}}
\textcolor{yellow}{\rule{5cm}{2cm}}
\end{document}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
Faust
Posts: 55
Joined: Thu Oct 29, 2009 12:45 pm

Re: Grayscale output with latex (via GS)

Post by Faust »

This doesnt work for figures Im using, just text.
Post Reply