ImageData problem, the results were different on Mac and Windows

Paul Hibbert paulhibbert at mac.com
Fri Nov 8 06:58:21 CET 2013


OK I can follow that, but it's the inconsistency that’s concerning me now. For another test I used a GIF as reference and compared both colour managed and non colour managed PNG and JPEGS to the the GIF, this is what I saw…

Mac:
PNG sRGB  = Visually same as GIF, numerically same as GIF
PNG NCM   = Visually darker than GIF, numerically very different to GIF
JPEG sRGB = Visually darker than GIF, numerically very different to GIF
JPEG NCM  = Visually same as GIF, numerically slightly different to GIF

Win:
PNG sRGB  = Visually lighter than GIF, numerically very different to GIF
PNG NCM   = Visually same as GIF, numerically same as GIF
JPEG sRGB = Visually same as GIF, numerically slightly different to GIF
JPEG NCM  = Visually same as GIF, numerically slightly different to GIF

NCM = No Colour Management

The index colour GIF file returned consistent numbers on both platforms, so that's why I used it for reference. The only difference between the sRGB files and NCM files is that the NCM version had no embedded colour profile, the colour data was the same. Visual references were only compared on the same platform.

I know that Mac and Windows do handle colour management differently and this may be something we just have to live with, but it would be useful to understand why the discrepancies occur in LC, there may be a rational answer, but I can't see it right now.

Incidentally, the original test showed another difference when run in LC 6.5 (rc1). Where each colour started with 0 for the Alpha channel in LC 5.5.5, it was returned as 255 in LC 6.5.0 (rc1), I only ran this on Mac as I haven't downloaded LC 6.5.0 on Win yet, I guess there's more testing to do!

e.g.
[0, 161, 40, 65] on LC 5.5.5 = [255, 161, 40, 65] on LC 6.5.0

Paul


On 2013-11-07, at 4:07 PM, J. Landman Gay <jacque at hyperactivesw.com> wrote:

> On 11/7/13 5:30 PM, Paul Hibbert wrote:
> 
>> I didn't see any discrepancy when I switched the image to a non
>> colour managed JPG or a GIF, although the figures for the JPG were
>> slightly different to the GIF. Colour managed JPEGs also exhibited
>> the same sort of discrepancy.
> 
> It sounds like the imagedata is returning the screen colors, not the image colors. Which would be appropriate I think.
> 
> -- 
> Jacqueline Landman Gay         |     jacque at hyperactivesw.com
> HyperActive Software           |     http://www.hyperactivesw.com
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode




More information about the use-livecode mailing list