|Jun 30, 2012, 10:36 PM||#1|
Color Calibration Problem
I am reading pixels from an image using NSReadPixel. This gives me a color with NSDeviceRGBColorSpace. I read in a small collection of these colors and then recreate the image with the reduced color set using the NSBitmapImageRep method:
initWithBitmapDataPlanes:(unsigned char **)planes pixelsWide:(NSInteger)width pixelsHigh:(NSInteger)height bitsPerSample:(NSInteger)bps samplesPerPixel:(NSInteger)spp hasAlpha:(BOOL)alpha isPlanar:(BOOL)isPlanar colorSpaceName:(NSString *)colorSpaceName bytesPerRow:(NSInteger)rBytes bitsPerPixel:(NSInteger)pBits
The colors in the image that I get as a result are off. How can I fix this problem?
If I fill bezier paths with the colors I create from the unsigned char bitmaps, then the colors match better (using both colorWithCalibratedRed:green:blue:alpha: and colorWithDeviceRed:green:blue:alpha
Last edited by Thethuthinang; Jun 30, 2012 at 10:37 PM. Reason: spacing
|Thread Tools||Search this Thread|
All times are GMT -5. The time now is 05:02 PM.