How to plot CMYK mode 2d figure?

Dear Rooters,

      I have to plot a 2d color figure for publish.

By default:

    gStyle->SetPalette(1);
    TH2D *h3 = new TH2D("h3",....
    h3->Draw("colz");

Then I got a RGB mode 2d color figure.
So how to covert it to CMYK mode?
Thanks!

What do you mean ? Do you want to change the palette ? The internal ROOT color model is RGB and TColor class provides tools to convert colors from RGB to HLS model and vice versa. I do not understand what you will get using CMY compare to RGB. In the few lines you sent there is no mention of the color model used. Can you explain more ?

The internal ROOT color model is RGB.
I need the CMYK, which is necessary for publish.

Maybe I have to use TColor class to convert colors from RGB to CMYK model.
Is that mean I need to change the palette ?

Many thanks for your help.

CMY is not know by ROOT TColor. But you do not need that to change the palette. Can you explain why you need CMY ? and why you cannot do it with RGB ?

Figures that are intended to be printed in color must be prepared as CMYK (i.e., four-color) files, not RGB files. It is not possible for conventional printing presses to use RGB files. (RGB files cannot be used for printing and must be converted to CMYK.)

Ok … but how do you indent to print the pictures ? using PostScript ? gif ? pdf ? … the way the color are encoded internally in root doesn’t change the color … yellow is yellow what ever the color encoding you use … My understanding is that your printing device needs CMYK right ? if yes, can you tell what kinf of file you’ll indent to print ?

I am sorry I donot know. I just send my draft to APJ, the editor told me to convert the figure. I use “photoshop” to convert the color from RGB to CMYK, but the figure became
fuzzy. So I’d like to plot the CMYK mode figure.

in which format are your figures ? Postscript, Pdf, gif ?

EPS

Ok, send me your EPS file. I will try to convert it by hand using the appropriate PS operators. Then your can send it back to you editor. If that works, I’ll try to add a special PS option to use CMYK instead of RGB (for PS/EPS files only). CMYK is a subtractive color model (RGB is additive). It is for printing purposes only so it should be at the EPS level only.

Can you tell me how I can send you an eps file ? the attachement in the forum doesn’t work it seems … send me an email at Olivier.Couet@cern.ch

Many thanks for your help, My email is zhangyi@mail.ihep.ac.cn

CMYK is now supported in PS files. Just use :

gStyle->SetColorModelPS©

c = 0; // RGB
c = 1; // CMYK