It's available in the documentation that comes with Xcode. If you go to NSColorSpace's class reference, there's an item in the TOC on the left named "Color Programming Topics for Cocoa." If you click on that link then on the "About Color Spaces" link, that will take you to a good overview.

One thing to take away is that the color space only defines the colors that can be produced by a particular color model, not whether or not a particular pixel has an alpha component. So for example, if you were using a NSDeviceRGBColorSpace instead of NSDeviceWhiteColorSpace, you could have pixels with the format RGB, BGR, ARGB, ABGR, BGRA, RGBA, depending on how the pixels are laid out (bitmap format). Notice that some of the formats have alpha (A) and some don't even though a single color space was specified.


On May 31, 2010, at 3:27 PM, Simon Raisin wrote:

Thanks Seth. I haven't been able to find any good docs on this stuff. Do you happen to know where I can read conceptual material about color spaces?

On Mon, May 31, 2010 at 1:11 PM, Seth Willits <sli...@araelium.com> wrote:

On May 31, 2010, at 4:06 AM, Simon Raisin wrote:

Thank you so much for the responses guys. This is the reason I was confused:
NSDeviceWhiteColorSpace
Device-dependent color space with white and alpha components (pure white is 1.0)
Available in Mac OS X v10.0 and later.

I thought that NSDeviceWhiteColorSpace had BOTH a white and alpha channel.

It does. Colorspace != bitmap format.

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to