Re: floats & Color APIs
Re: floats & Color APIs
- Subject: Re: floats & Color APIs
- From: Erik Buck <email@hidden>
- Date: Mon, 23 Oct 2006 14:38:24 -0700 (PDT)
This is just speculation, but it could be because Apple's color API sits on top of Open-GL and Open-GL prefers float. Open-GL may prefer float because the hardware acceleration for Open GL prefers float.
Another reason may be to facilitate alpha compositing with pre-multiplied alpha: (From CoreImage.pdf)
"Premultiplied alpha is a term used to describe a source color, the components of which have already been multiplied by an alpha value. Premultiplying speeds up the rendering of an image by eliminating the need to perform a multiplication operation for each color component. For example, in an RGB color space, rendering an image with premultiplied alpha eliminates three multiplication operations (red times alpha, green times alpha, and blue times alpha) for each pixel in the image...
By default, Core Image assumes that processing nodes are 128 bits-per-pixel, linear light, premultiplied RGBA floating-point values..."
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden