Sunday 24 November 2019

Limiting Ink Density

If you're printing at Lightning Source, e.g. because you're doing a POD product at DriveThruRPG, you have to abide by LS's printing specifications. One of those is a so-called "ink density limit."

What is an ink density limit, and how do you stay within it?

As I wrote in the last post, printing presses use four colors of ink to replicate the colors in your digital files, cyan, magenta, yellow, and black.. CMYK. Most colors are reproduced using a combination of multiple inks. Darker colors need more ink, as do more saturated colors.

For especially deep, saturated colors like inky maroons or really dark, muddy greens, you can need quite a lot of ink - black, yellow, and magenta. Just like coloring over the same spot over and over again with a marker, too much ink can wrinkle the paper, or cause smudging and bleeding before the ink has had time to dry.

For this reason, Lightning Source imposes a blanket restriction on the total amount of ink any one spot on the paper can take, to 240%. Their darkest, richest black allowable is achieved by 100% black ink, with 60% cyan, 40% magenta, and 40% yellow.

Do we have a problem?

Waiting for Lightning Source to tell you that you have an ink density problem is going to ratchet up your turnaround time. It takes several days for DTRPG and Lightning Source together to check, process and then reject your PDF. Better to check it yourself.

The best way to check I've found so far isn't great, as you have to skim your whole document by hand in InDesign. Even so, it beats losing half a week to turnaround time.

Open up the so-called 'Separations Preview' panel, in the menu: Window | Separations Preview.

(It's called that, because it's a preview of how your document colors will be separated into the four different inks.)

Turn the 'View' to 'Ink Limit', and then change the numeric value to '240%', like so:


This causes your document to be re-rendered in a washed-out gray, but with any areas that violate the 240% limit picked out in red.

For example, here's an ink-heavy map from my compendium in the normal view:


Here's how it looks with the Ink Density limit preview on:


If you click on that to zoom in you can see a few areas have been called out by InDesign as busting the ink density limit.

Why those areas? There are some dark, muddy browns there - they're close to gray but not exactly gray, which means you need a combination of cyan, magenta, and yellow to reproduce them on paper. They're also really dark, which means a bunch of black ink goes on as well. Soggy.

InDesign doesn't seem to have any sort of whole-document pre-flight check for ink density, which means there's no simple way to find these problems without scanning the whole document. (If you know of one, let me know!)

Checking Ink Density in Photoshop

Unfortunately, Photoshop only allows you to check a single pixel at a time. Open up the Info panel, and click the eye droppers to change its display options. You want to see the CMYK color, and Total Ink views.


As you mouse around your image, Photoshop will show you the total ink density. This isn't really useful for finding problems, but it's a decent way to check that you have fixed them. (See below.)

Fixing Ink Density

Fixing ink density problems can be tricky for indie publishers, particularly if the publisher/artist roles are played by separate people and the publisher only has InDesign, and the artist only has Photoshop.

If you're the publisher:

  1. You may need to explain to the artist what ink density is, and how to spot check it.
  2. Send the artist a screenshot of the ink density view from InDesign, so they can see the problem areas.

If you're the artist:

  1. Learn what ink density is, and how to spot check it.
  2. Find out from your publisher what the problem areas of the image are, so you can check them out
  3. Keep your original art piece separate, because many of the methods of fixing ink density are destructive, making permanent changes to the art.

Method 1: Tweak the image

This involves some trial and error, but some combination of level adjustments, curves, and desaturating dark colors can fix ink density problems. This may keep you in your comfort zone, but it strikes me as a little haphazard for two reasons:
  • Photoshop doesn't seem to have any built-in adjustments that target ink density. Because density is a subtle combination of high saturation and low brightness, there's no blend mode or levels solution that's a guaranteed fix that won't wash out the image (as far as I can tell).
  • Checking your work isn't isn't easy, because you can only check one pixel at a time. By the time you've fixed the problems, but then re-adjusted so your image isn't washed out, you might have caused new problems elsewhere.
I welcome tips or links to articles about this approach.

Method 2: Convert to the printer's recommended color profile

Converting to some specially designed color profiles seems to fix ink limits.. sometimes.

For this method, you should probably learn what color profiles are so you have some idea of what's happening.

Applying the profile is easy (once it's installed). In Photoshop, use Edit | Convert to Profile, and pick the printer's profile.

A key limitation of this approach is that ink density limits are not a feature of color profiles. Reducing the ink density can be a side effect of a profile conversion, but there's nothing in the profile that sits there as an ongoing safeguard against ink density problems.

Photoshop does its best, but if you have any layers in the multiply blend mode, while each layer individually might respect ink density limits, the resulting final pixels can still blow past the limits.

For this reason, if you rely on a color profile conversion to fix ink density you should:
  • Flatten the image first (to get rid of blending mode interactions)
  • Limit the amount of adjusting you do afterwards, e.g. fixing the contrast
  • Spot check problem areas before you declare victory
Currently, DriveThruRPG is recommending that art be converted to the CGATS21_CRPC1.icc profile, which you can download from them.

Method 3: Convert to custom CMYK profile settings

If you can't figure out the printer's target color profile, Photoshop will let you manually specify an ink density limit if you convert to a 'custom' CMYK profile.

Choose Edit | Convert to Profile..



Chose the CMYK destination space, then pick 'Custom CMYK' as the profile. When the profile customization dialog pops up, type in '240' as the ink density limit:


..and that's it.

Finally, spot check any problem areas your publisher highlighted for you, and any other likely problem areas if you do any adjustments after the conversion.

As with using the printer's color profile, there's nothing magical about converting to CMYK that will keep your image within the ink density limit if you adjust it. It may already be out of whack if you have blend mode interactions, so try this with a flattened version of the image if your spot checks.

Send it back to the publisher and.. good luck!

Saturday 23 November 2019

Basics of Color Profiles

Any time you're tangling with a print run or POD, you're going to have to tangle with color profiles. This is a confusing subject, and the fundamentals are elusive. There are lots of, "Well, what worked for me.." type posts, but relatively little on exactly how and when InDesign uses the many color profiles at play for any given document:

  • InDesign's current "working space" color profiles
  • The document's assigned color profiles
  • The color profiles embedded within any images included in the document
  • The Proof Colors color profile
  • The color profile you're exporting to
To make this more confusing, many of the conversions can be tweaked or skipped by either document-level or InDesign-level overrides.

Welcome to my journey of trying to figure out color profiles. Warning - this isn't a "how to" document, this is me trying to feel my way through the fundamentals so I can understand wtf is going on better, and so I can piece through the implications of the instructions that different printers give me.

Encoding Colors

To explain what color profiles are, I first need to explain how colors are encoded. In indie publishing, most of the colors we deal with are so-called process colors: instructions to some machine for reproducing a color. (These contrast with spot colors, which are like Pantone paint chips, pre-agreed, specifically named colors.)

You're probably familiar with the RBG scale, which has red, blue and green components, each from 0 to 255. These numbers are an instruction to a monitor about how much red, blue, and green light to send. 0 means 'none', and '255' means, "as much as you can."

An RGB value of 255, 255, and 255 is the most light a given monitor can send, which is white—or, at least, as white as that monitor can get.

Here's the first problem: "as much as you can" isn't very specific. That's going to depend on the monitor!

Print colors have a different process, based on combining four colors of inks: cyan, magenta, yellow, and black, CMYK. If all the numbers are zero, c=0, m=0, y=0, k=0, then no ink is laid down. If all of these are set to maximum, that tells the printer to print the darkest color it can, a thick, rich black.

Again, "the darkest color you can print" is completely different from printer to printer.

Color Profiles

This is where color profiles come in: the color profile indicates what machine the instructions were for.

If I'm trying to be precise about color, "as blue as you can get" isn't good enough. That will look completely different on each device I try it on.

If I say, "100% yellow on a Brother 3-400c inkjet with C-series Brother inks," then you can understand what specific color I'm talking about, and reproduce that on another printer. On a fancy printer with better inks that give it a greater range of yellow, the identical looking yellow might be only 95% of its maximum yellow.

Thermometer Analogy


I like temperature as an analogy. We can probably all agree that zero degrees is cold, and 300 degrees is pretty hot. That's fine for chatting casually, but if you're trying to follow a recipe that says to "cook at 250 degrees," you really need to know the scale: Fahrenheit or Celsius.

If just turn your oven to 250 degrees and hope for the best, you run the risk of cooking at the completely wrong temperature. If the recipe was supposed to be Celsius but your oven is in Fahrenheit, then your meal will still be raw. If the recipe was supposed to be 250 Fahrenheit but you cooked at 250 Celsius, you're going to get a black brick for dinner.

In print, this translates to dark colors coming out all washed out, or the whole image having a weird blue cast to it. "You said medium blue.." isn't precise enough.

So: color profiles are like 'Fahrenheiht' and 'Celsius' for color.

Gamuts


Now, not only are some ovens in Celsius and some are in Fahrenheit, not all ovens have the same temperature range. My oven goes from 150F to about 550F, but someone else's oven might only go up to 525F.

With colors, the range of reproducible colors is called a gamut.

You can see, below, the very different gamuts of the 'Apple RGB' profile and Friesens' 'GRACoL' CMYK profile.


The RGB profile can produce brighter reds, vibrant light greens, and luminous evening-sky blues. The GRACoL profile, on the other hand, can't do any of those colors. It's greenest green is a medium, grassy color. This makes sense, it doesn't actually have green ink, it has to make green out of yellow and blue. The more saturated the desired green, the more ink it has to use, which is self defeating because more ink you use, the darker things are.

On the other hand, GRACoL has a slightly better range of yellow, which makes of sense - it's a print process that uses bright yellow ink. The RBG profile has to make yellow out of green and red, so 'very yellow' tends to wash out because the more colors of light you use, the whiter you get.

The gamut differences are one source of unexpected color changes when you go to print: you've asked the printer to make a color it can't make, so it does the next best thing. The "next best thing" might look like total crap - particularly if you've got radiant light shining through new spring leaves, and they all come out looking like grass on an overcast day.

The point here is that color profiles really matter, because "as green as you can get" isn't just slightly disappointing, it could be a completely different color.



Managed vs. Unmanaged Color


InDesign and Photoshop use the term 'managed color.' Simply, managed color means that the colors have an identified profile (e.g. 350F), and unmanaged means they don't (um, just.. 300 degrees, y'know?).

Most projects will start out from ingredients—images, colors chosen in InDesign—which are a mix of managed and unmanaged. For example, it's common for digital artists to supply artwork in RBG, without a declared color profile. (Guilty!)

This is a second source of unexpected color conversion problems. You might know that your oven works in Celsius, but if you don't know what the recipe was using, it doesn't help you interpret what '280 degrees' means. You are forced to decide: was it Fahrenheit, and I should convert that to Celsius? Or was it Celsius already, and I should simply assign the Celsius scale to this number?

A note on "Assigning" vs. "Converting" Profiles

These terms come in various places in InDesign and Photoshop, and they do similar but different things.

Profile conversions attempt to keep the target color the same, as instructions for a different profile. For example, if I have a temperature of 200F, and I want that in the Celsius 'profile', the conversion result is 93C.  These are the same real-world temperature, just represented in different scales.

Assigning a profile, on the other hand, keeps the numbers the same and simply asserts that the numbers are supposed to be interpreted in a given color profile.

For example, going from the temperature, "um, 200, y'know?" to "200F" is me assigning the Fahrenheit scale. This is a little dangerous, because maybe it was supposed to be Fahrenheit, but maybe not. If the recipe author meant 200C but was lazy and left off the C, then my output is going to be too cold. Assigning clearly needs to be done with care.

In general, the earlier in the process you start managing color the better, as this reduces the chance of unexpected conversions.

Multiple Profiles at Work

A complex InDesign document is going to be made of lots of different pieces: borders and solid blocks with colors chosen in InDesign, and images from all sorts of places (stock art from the web, scans from artists, etc.)

InDesign can keep track of the color profile of each of these pieces separately. This is a bit like a recipe that specifies the starting temperatures of the ingredients:
  • a potato from your root cellar at 18C [embedding the Celsius profile]
  • a zucchini from your fridge at 10F [embedding the Farenheit profile]
  • a turkey from your freezer at -18C [embedding the Farenheit profile]
  • 5mL of ethanol from your liquor cabinet, at 292K [embedding the Kelvin profile]
By keeping track of the profiles of each of the pieces, InDesign can make its final export in a color-preserving way.


What All Those Color Profile Do

Okay, so here's my understanding of how all the color profiles interact in InDesign!
  • InDesign's current "working space" color profiles
  • The document's assigned color profiles
  • The color profiles embedded within any images included in the document
  • The color profile you're exporting to
  • The Proof Colors color profile

Working Space Color Profiles


If you pop open Edit | Color Settings, you can see InDesign's current working spaces color profiles. There's one for RBG and one for CMYK.

As best I can work out, the working space color profiles are just used as a kind of fall-back default for the document: if your document doesn't have an explicitly assigned profile, InDesign will assume the current working space is the color profile.

If your document has an assigned color profile, the working space color profile has no effect whatsoever.

Document Color Profile(s)


The document's two color profiles (again, one for RBG and one for CMYK) are an explicit way of saying, "Unless I say otherwise, all the stuff in this document is in this color profile.)

How do you tell if your document has an assigned color profile? Pop open Edit | Convert to Profile, and look at the Source Space:


I think what's happening here is that my document does not have an RBG profile specified at the document level, it's just borrowing from the current Working Space.

On the other hand, the CMYK is explicitly set to CGATS21_CRPC1.icc, so I do have a document level CMYK color profile.

From what I can tell, having an assigned document color profile is a good idea. If you're working on multiple documents, destined for different printers (PDF, an offset print run, DTRPG POD), you definitely don't want to be remembering to switch an application-level setting back and forth to make sure your inputs are interpreted correctly. That's begging for trouble.

Linked Image Embedded Profiles


If you want to check the profiles of all your source images, open the InDesign Links panel. (Window | Links). You may need to go into the panel settings to adjust which columns are displayed, but either way the Link Info area will show you the color space (RGB vs. CMYK) of each image, along with any embedded color profile.


Here you can see that the "Dragon skin" image I've included is an RGB image, in the 'Display' color space.

I believe that images which don't have an assigned color space will be treated as if they are in the document's color space, or the working space if there isn't one at the document level.

This strikes me as a rather haphazard fallback plan, because InDesign's interpretation of your colors will depend on whatever working space you have chosen today. That might vary from task to task, so it's probably wise to specify at the image level.

Export Destination Color Profile


Depending on your export settings, the 'export to PDF' process may convert color profiles to a different destination color profile. There are a lot of settings here, as conversion is a rich area. I'm going to focus on the Color Conversion and Destination settings.



There seem to be three conversion approaches:

1. Don't convert anything: leave everything in the original color spaces, if any are specified. If there are assets without specified color spaces, then leave them unspecified.

If you choose this option, you also get to choose a Profile Inclusion Policy for the embedded assets. This basically controls whether InDesign embeds your images' current color profiles into the final PDF, or strips them off.

2. Convert to Destination: remap all the colors into the chosen destination profile (which, again, should probably not be your working space unless you like settings bleeding from project to project).

This setting comes with a warning that any unmanaged colors that have made it this far are just going to get assigned to the destination color space, whether that's right or not. (151 degrees? I'll assume they meant 151. It'll be fine.)

3. Convert to Destination (preserve numbers): This setting remaps colors into the destination color space, but only if InDesign can work out what the source color space was. In other words, if you're exporting to Fahrenheit, it will convert 93 Celsius into 200 Fahrenheit, but if you have a temperature of '151' specified somewhere, with no scale, it will leave it as 151 with no scale.

Which of these export settings you want is going to depend greatly on your printer. But, two principles come to mind:
  • Your printer will probably insist on particular settings for this step.
  • If any colors are unmanaged at this point, you're relying on the default assumptions of your printer on how it will interpret '151 degrees'. You should probably know what those are.
A note on conversion methods
  • Perceptual conversion tries to preserve color differences within the converted images, squeezing the source color range into the destination color range.
  • Colorimetric conversions just take the source color and find the closest matching color in the destination profile.
These two methods have the biggest difference (I think) when the source and destination gamuts are very different.

If you're going from a big gamut into a smaller one (e.g. RBG into CMYK), perceptual will dull down the contrast of the whole image so that its range of colors fits into the target gamut. In situations where the destination gamut is larger, this may expand the range of colors used into that gamut somewhat. (I don't know this.)

Colorimetric, on the other hand, leaves the parts of the image that convert cleanly untouched, and only fiddles with colors that don't have direct analogues. Un-renderable colors are just substituted for their closest match, other colors are unmodified, and any additional range in the target gamut simply goes unused.

Most resources I've found recommend using relative colorimetric, but also tend to recommend pre-converting your images into the destination space so you don't get any unexpected effects, and not relying on last-minute export-time conversions.

Proof Colors Space

Finally, InDesign has a setting that lets you preview what your colors kinda sorta might look like after export. If you go View | Proof Setup, you can choose a destination color profile, which I assume should match your export destination profile.

This has no effect on your document, other than to show you, on screen, what InDesign thinks your document will look like post-conversion. This is of course approximate, and is of course impossible for ink colors that your monitor can't display.

Also, I assume the preview just assumes you're converting all colors to the preview space, which might not be what your export settings are doing.

This feature seems to interact weirdly with unmanaged colors, but I haven't poked around here extensively.

So What?

This is all part one of me struggling through DTRPG's POD color requirements. There may be a follow up when I post what I've learned when I'm completely done!