Permalink
Browse files

Improved the accuracy of colors written out to *.ico files

  • Loading branch information...
1 parent 35b9a8d commit 435b138726532972f7849b09c0eaa998fdf4d5a6 @mattrajca mattrajca committed Apr 29, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 Archiving/Image Exporters/PXIconExporter.m
@@ -135,7 +135,7 @@ - (void)writeImageData:(NSMutableData *)data withCanvas:(PXCanvas *)canvas
int bytesWritten = 0;
for (i = 0; i < canvasSize.width; i++)
{
- NSColor *color = [NSReadPixel(NSMakePoint(i, j)) colorUsingColorSpaceName:NSCalibratedRGBColorSpace];
+ NSColor *color = NSReadPixel(NSMakePoint(i, j));
byte colors[4];
colors[3] = (byte) round([color alphaComponent] * 255);
colors[2] = (byte) round([color redComponent] * 255);

0 comments on commit 435b138

Please sign in to comment.