• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Creating a color image with NSBitmapImageRep and greyscale data
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Creating a color image with NSBitmapImageRep and greyscale data


  • Subject: Re: Creating a color image with NSBitmapImageRep and greyscale data
  • From: David Spooner <email@hidden>
  • Date: Tue, 27 Nov 2007 21:53:21 -0700

Yes, the documentation for the CIColorMap filter is somewhat vague. There is a posting on the quartz-dev list which points to an example usage in the Core Imager Fun House application and states that the gradient image (2nd argument) is a 1xN lookup table mapping greyscale values (appropriately scaled?) to rgb values...

dave

On 27-Nov-07, at 9:37 PM, Jason Horn wrote:

Dave,

Actually, there was a bug in my code.  That loop should have been:

	for (pixel=0; pixel<numPixels; pixel++) {
		RGBData[RGBpixel] = pixels[pixel];
		RGBData[RGBpixel+1] = pixels[pixel];
		RGBData[RGBpixel+2] = pixels[pixel];
		RGBpixel += 3;
	}

So, now I have a color image (that is grey), but CIColorMap still does not produce a color image. Perhaps I don't understand how CIColorMap works.

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Creating a color image with NSBitmapImageRep and greyscale data (From: Jason Horn <email@hidden>)
 >Re: Creating a color image with NSBitmapImageRep and greyscale data (From: David Spooner <email@hidden>)
 >Re: Creating a color image with NSBitmapImageRep and greyscale data (From: David Spooner <email@hidden>)
 >Re: Creating a color image with NSBitmapImageRep and greyscale data (From: Jason Horn <email@hidden>)

  • Prev by Date: Re: Creating a color image with NSBitmapImageRep and greyscale data
  • Next by Date: Referenced projects and their targets/executables
  • Previous by thread: Re: Creating a color image with NSBitmapImageRep and greyscale data
  • Next by thread: validate custom view toolbar item
  • Index(es):
    • Date
    • Thread