I'm trying to print a large image size 23150 x 16229. It is designed to fit on a B1 page at 600dpi.

When this is a png, it works fine with this code:

\usepackage[top=1cm, bottom=1cm, left=1cm, right=1cm,b1paper]{geometry}

When I change the file to a jpg with:

convert small_orig.png small_test.jpg

And recompile with pdf latex I get:

I can't work with sizes bigger than about 19 feet.

Any ideas? I need it as a jpg so it's in CMYK (I understand that my conversion command above doesn't do that, but I can't even get an RGB jpg to work).

Thanks, James

  • Please open your new jpg with, say, Gimp and check the size of it. Maybe LaTeX is right and the picture became bigger than 19 feet in the conversion (for whatever reason). In this case, you should scale done the image to your 23150 x 16229 again and try it again. Just a guess. – LaRiFaRi Dec 11 '14 at 7:51
  • Thanks for the guess, but GIMP has the correct dimensions. – James Dec 11 '14 at 7:53
  • Check the resolution of the jpg (\pdfimageresolution doesn't set it, if the graphics contains a resolution). – Ulrike Fischer Dec 11 '14 at 10:52
  • Yeah the resolution of the jpg is 72x72 - I guess that was the problem. – James Dec 11 '14 at 23:47

Thanks to https://tex.stackexchange.com/users/2388/ulrike-fischer, the problem is solved. If converted as I stated in the question, the jpg gets a default resolution of 72 x 72, which would make the image about 27' wide.

Changing the conversion to:

convert -units PixelsPerInch small_orig.png -density 600 small_test2.jpg

And it works fine. Thanks all

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.