A small question for the Photoshop wizards, anyone ?

1 Star2 Stars3 Stars4 Stars5 Stars (4 votes, average: 3.50 out of 5)
Loading...
By Oliver AKA The Admin on 13 comments
in Categories: Just Talking

Hello there, if you’re a photoshop wizard, could you take a minute to enlighten a self-learning half-newbie ? :D

This is about pngs in indexed colors bugging me, in a nutshell.

To describe it simply, I have a problem with pngs, when their color set is “indexed colors”.
When I open them in Photoshop (cs5) :
– I cannot duplicate layers, create layers, it’s like mono-layered
– when I select a zone and then I attempt to perform a clone stamp inside this zone, the clone stamp isn’t “previewing” (in the circle-shaped mouse pointer) what it is going to be drawn

The problems don’t end here ! Because of this, when I want to do something with that kind of png, I convert them to grayscale or RGB. But, to my horror, this conversion changes the picture !
Look, compare an original png, still in “indexed colors”, with the grayscale-converted version.

I suppose there must be an explanation.
I hope there is a solution to avoid the picture change when converting out of indexed colors.
But my google-fu didn’t allow me to find neither a solution nor an explanation :-|

So please, if the reply is obvious for you, you’re welcome to flame me or ridicule me (as a friend once yelled after far too much alcohol : “attach me with manacles to the radiator and speak to me in German !!”, maybe that is horrible), as long as you have a valid reply ;)

Subscribe
Notify of
guest

13 Comments
oldest
newest most voted
Inline Feedbacks
View all comments
Setebos
Setebos
13 years ago

LOL, no help here, but you've amused me with this "attach me with manacles to the radiator and speak to me in German !!”

EXO02
13 years ago

I got the indexed image and converted to rgb, lab and grayscale and not even one pixel changes in appearance. Checked back and forth but I have not experienced that issue.
So, it must be some configuration setting on your Photoshop.

Itsit
Itsit
13 years ago

have you tried converting the image with other program? (GIMP, for example). If you can do it with other programs, then the problem is with photoshop. Likewise, try converting other images to see if the problem remains.

DivinoAG/Kemwer
13 years ago

Photoshop doesn't allow the use of layers on 256 colors/grayscale images, such as indexed PNGs or GIFs. So you must convert them to RGB to be able to create new layers. As a rule of thumb, you will probably want to convert them to at least RGB everytime anyways, because the less colors are allowed on the image, the lower will be the quality of any editing you make on them.

This is also a good tip if you are making some serious color editing on a picture, and you start to get color banding on some areas. To avoid that, try converting the image to 16bits before making the edit, then converting it back to 8bits before saving.

As to why the colors change… that comes with the territory. Any color mode conversion end with slightly different colors than the original (it's a lot worse if you try going from RGB to CMYK, believe me), because of rounding differences during the calculation of the converted image. On this particular case, I wouldn't worry about it because it won't be noticeable on the end product, but you can try to create a duplicate of the file (menu Image > Duplicate), converting one of them and then compensating with brightness/contrast adjustments.

Hope it helps. Ask again if I was not clear or if you need any more help. ;)

Joseph
Joseph
13 years ago

Though I agree with most of what you said, converting from indexed PNG to RGBA should be lossless !

I think the problem comes from color correction/screen calibration.

If you look at the metadata from the not converted PNG, it gives this :
—————————————————————–
ExifTool Version Number : 7.89
File Name : not-converted-to-grayscale-png-for-question-about-index-colors.png
Directory : .
File Size : 640 kB
File Modification Date/Time : 2010:08:02 03:36:44+02:00
File Type : PNG
MIME Type : image/png
Image Width : 1110
Image Height : 1600
Bit Depth : 8
Color Type : Palette
Compression : Deflate/Inflate
Filter : Adaptive
Interlace : Noninterlaced
Software : Adobe ImageReady
Palette : (Binary data 96 bytes, use -b option to extract)
Image Size : 1110×1600
—————————————————————–

But when you look at the converted PNG, it gives this :
—————————————————————–
ExifTool Version Number : 7.89
File Name : converted-to-grayscale-png-for-question-about-index-colors.png
Directory : .
File Size : 726 kB
File Modification Date/Time : 2010:08:02 03:36:34+02:00
File Type : PNG
MIME Type : image/png
Image Width : 1110
Image Height : 1600
Bit Depth : 8
Color Type : Grayscale
Compression : Deflate/Inflate
Filter : Adaptive
Interlace : Noninterlaced
Pixels Per Unit X : 2835
Pixels Per Unit Y : 2835
Pixel Units : Meters
Profile CMM Type : ADBE
Profile Version : 2.1.0
Profile Class : Output Device Profile
Color Space Data : GRAY
Profile Connection Space : XYZ
Profile Date Time : 1999:06:03 00:00:00
Profile File Signature : acsp
Primary Platform : Apple Computer Inc.
CMM Flags : Not Embedded, Independent
Device Manufacturer : none
Device Model :
Device Attributes : Reflective, Glossy, Positive, Color
Rendering Intent : Media-Relative Colorimetric
Connection Space Illuminant : 0.9642 1 0.82491
Profile Creator : ADBE
Profile ID : 0
Profile Copyright : Copyright 1999 Adobe Systems Incorporated
Profile Description : Dot Gain 20%
Media White Point : 0.9642 1 0.82491
Media Black Point : 0 0 0
Gray Tone Reproduction Curve : (Binary data 524 bytes, use -b option to extract)
White Point X : 0.31269
White Point Y : 0.32899
Red X : 0.63999
Red Y : 0.33001
Green X : 0.3
Green Y : 0.6
Blue X : 0.15
Blue Y : 0.05999
Image Size : 1110×1600
—————————————————————–

It clearly says that the converted PNG have color calibration in it. The problem is that your browser doesn’t take it into account while Photoshop does.

As to how change this behaviour under Photoshop, I cannot help you.

DivinoAG/Kemwer
13 years ago
Reply to  Joseph

Photoshop MAY take color calibration in account when converting files (it's optional), which would also explain the color difference. What happens in that case is the converted file is showing the correct color, because the browser is not displaying the color corrected version of the PNG file, is just displaying the raw data. When converting, PS takes that raw data, color correct it to display, and then it converts to RGB.

You are probably correct about it in this case, that didn't cross my mind when I posted before. But even without taking color correction in consideration, these differences when converting from color modes are not very uncommon.

But as I said before, try to always avoid working on low-bit color modes when doing image treatment, because you end up generating a lot of artifacts on the image, which can be avoided by converting to a high-bit mode before. For example, when doing "Playboy-style" skin cleanup on models for magazine work, I always work on 16-bit CMYK images and convert to 8-bit files as the last step of the process, since that helps avoid banding the skin tones after color correction.

Roy Mustang
Roy Mustang
13 years ago

imnot exactly an expert but what i know is that indexed colors means that there's a table of colors allowed to be used in that image. It's like those pictures to paint for kids, where the areas has a number and the kid must fill the areas with the same number with the same color, well in this case you have a limited number of colors and that why PS wont let you use the advanced tools. as they say, the only way is to transforme the image and work around it.

Hope it helps.

Mystery
Mystery
13 years ago

Oliver just use the save as web with the file in RGB and save then when you open it change it to Rgb and modefy and save it again no changes in it if you don't mess with Grayscale colors and the size is the same as RGB

Mystery
Mystery
13 years ago
Reply to  Mystery

Plus Oliver do you know the configs for Save as Web & Devices ? if not here
http://senbonzakura.kageyoshi.net/2008/04/03/savi

Lol for the Record I'm Vaizard lol can't Login for some reason lol XD o and never use Gray scales beacuse it's not about the saving it's about gray scales if you change from a RGB to GrayS and Back to RGB the image will be darker never use Gray scales just mantain RGB i learned that while editing Taihen lol i made the images darker when i saved and i didn't know why the i got myself doing so stuff lol If the original is Gray scales make it RGB before everything and leave it but never backwords lol bye hope it helped lol and plus that site is really good for manga cleaning it was were i learned it all XD

Vaizard
13 years ago
Reply to  Mystery

LOL now i can login lol just do what i said up there lol and everything should be fine if it's to confusing or it's not working just send me a e-mail i'll respond to it with a Simple and Efective clean tutorial lol bye YAAAAAAAAAHHHHHHHAAAA!!!!!!!!!!

Vaizard
13 years ago
Reply to  Vaizard

LOL i'm really stupid lol sorry oliver i'm really anoying i know but here ya go i forgot to say the way to check if what i said was true

1- Load a JPG file to PS in RGB form.

2- Just erase part of the image if you what to be sure you maid changes.

3- Save as Web & Devices (use the configs i gave you the make the file Smaller but they don't interfer with this)

4- Save it as "A" and chose about 40 our more colors 40 is always a good nº( This Save was in RGB Form)

5- Now Go back to the Image Change it to Gray Scales

6- Save it the same way with the name "B"

7- Check the Original and A & B, "B" is is darker then the other 2

If i helped please do tell me XD i'm really full of myself lol but i don't know a lot about PS lol BYE XD

Feanor
Feanor
13 years ago

Me neither. But I never had any trouble with grayscaling. I check it for every black/white page and it has never changed the colors. And I could always make new layers.
The same goes for changing from indexed to grayscale. Never had trouble or changes doing that.

I don't know photoshop that well though (but it's enough to make hq scanlations *gg*).

PS: I save the pictures with PNG 8, adaptive, diffusion, 100% dither and 32 colors. You can even only use 17 colors. It doesn't affect the picture quality and keeps the filesize real low.
As you can see, there are more ways than one.