Export to PNG alters RGB-values

Post questions on how to use or achieve an effect in Inkscape.
frederikheremans
Posts: 2
Joined: Tue Mar 27, 2012 5:55 pm

Export to PNG alters RGB-values

Postby frederikheremans » Tue Mar 27, 2012 6:07 pm

Hi,

I've been using Inkscape for quite some years now and never seen this behavior before. I have designed assets to use in an iPad app in Inkscape (v 0.48 - Mac OSX Lion - MBP). When I export my the images I need, the RGB values that end up in my PNG are different (eg: red off by 12, g by 1 and green stays the same). I'm guessing this has something to do with the second monitor I use (I recently calibrated it). I took a look at the "Color Management" in Inkscape prefs and doc props, but can't seem to "switch off" the ICC behavior.

Can anybody shed some light on this and perhaps help me with getting the original RGB-values exported? Thanks in advance!

User avatar
BobSongs
Posts: 324
Joined: Fri Sep 14, 2007 2:18 pm
Location: Montreal, Canada

Re: Export to PNG alters RGB-values

Postby BobSongs » Fri Mar 30, 2012 3:47 am

frederikheremans wrote:<snip>When I export my the images I need, the RGB values that end up in my PNG are different (eg: red off by 12, g by 1 and green stays the same).</snip>


I have a couple of questions that may bring something to light.

What software told you the figures you selected for red were off by 12 and green by 1 and blue (original post has green twice) stays the same?

Have you tried making the red "off" by 12 in Inkscape and green by 1 in the opposite direction then exported the image and, finally, tested the results for colour mis-management? If that's unclear, we'll say the red you selected was 50 but the PNG gave 62 (difference of 12). What if you reduced the 50 to 38 in the SVG and tested an export. Does the PNG say the red's 50 then? I realize a work-around is not what you're after... but the test results might be eye-opening to the developers who browse the forums.

:)

frederikheremans
Posts: 2
Joined: Tue Mar 27, 2012 5:55 pm

Re: Export to PNG alters RGB-values

Postby frederikheremans » Fri Mar 30, 2012 6:30 pm

Thanks for your reply.

The software that told me the colors where off was inkscape itself and some other color-drop-app on a colleague's machine. So I exported the png and pasted it again in inkscape, and used the inkscape dropper (you see an instant color difference).

Concrete example:

- Color in inkscape: rgb(134, 209, 240)
- After export: rgb(117, 199, 236)
- Altered color by reversing the delta (as BobSongs suggested): rgb(151, 219, 244)
- After exporting altered color: rgb(135, 211, 241)

Looks like it's not a fixed correction (of eg. 12 like in the first post I made) but I'm guessing a percentual correction (based on calibration of monitor I presume).
I'm quite sure it has something to do with the monitor calibration. When I open the exported PNG in mac "preview" and take a screenshot (instead of actually copying the image) of the image, the colors are matching again, so I presume the reverse-correction happens again on the mac-clipboard or when x11 pulls it from the clipboard and pastes it into inkscape.


Return to “Help with using Inkscape”