New ToneCurve CIFilter from Lion (10.7)

Jean-Jacques Boutaud
Member
Posts: 1638
Joined: July 10th, 2006, 2:29 pm
Location: France
Contact:

Postby Jean-Jacques Boutaud » November 27th, 2011, 7:20 am

Hi Nick
One of the most powerful cifilters added to Lion is the Tone Curve filter, very similar to Photoshop Curves.
Unfortunately, it seems that, in IT3, default values (default and identity values are the same ones for this cifilter) and types are wrong as you can see in this description from Apple developer documentation (Each point is a CIVector of type Offset (XY coordinates) not an angle and radius):

From Apple's CoreImageRef documentation (2011-10-12, page 284):

CIToneCurve
Adjusts tone response of the R, G, and B channels of an image.
Parameters
inputImage
A CIImage class whose display name is Image.
inputPoint0
A CIVector class whose attribute type is CIAttributeTypeOffset and whose display name is Point 1.
Default value: [0, 0] Identity: [0, 0]
inputPoint1
A CIVector class whose attribute type is CIAttributeTypeOffset and whose display name is Point 2l
Default value: [0.25, 0.25] Identity: [0.25, 0.25]
inputPoint2
A CIVector class whose attribute type is CIAttributeTypeOffset and whose display name is Point 3l
Default value: [0.5, 0.5] Identity: [0.5, 0.5]
inputPoint3
A CIVector class whose attribute type is CIAttributeTypeOffset and whose display name is Point 4
Default value: [0.75, 0.75] Identity: [0.75, 0.75]
inputPoint4
A CIVector class whose attribute type is CIAttributeTypeOffset and whose display name is Point 5
Default value: [1, 1] Identity: [1, 1]
Discussion
The input points are five x,y values that are interpolated using a spline curve. The curve is applied in a perceptual (gamma 2) version of the working space.
Member of
CICategoryBuiltIn, CICategoryNonSquarePixels, CICategoryInterlaced, CICategoryStillImage, CICategoryVideo, CICategoryColorAdjustment
Localized Display Name
Tone Curve
(end of Apple documention)

Here's what UI could be with default values (screenshot made with a little help of AT):

Image

Note that i've used the DisplayName attributes (from Point1 to Point5).
If using 10 sliders in place of one curve, each slider should have a range of 0.00 to 1.00.
JJBee, Président (à vie) du G.R.O.I.N.
Secrétaire général : iMac C2D 2.16GHz
Secrétaire adjoint : MacBook Pro 17" Unibody 3.06GHz
http://belightcommunity.free.fr/BeLight Community website
Nick
Member
Posts: 7237
Joined: July 6th, 2006, 3:13 am
Location: Odessa, Ukraine
Contact:

Postby Nick » November 27th, 2011, 9:46 am

Hi Jean-Jacques,

Thanks for information! I'll pass it to the developers.

Nick

Return to “Image Tricks”

Who is online

Users browsing this forum: No registered users and 1 guest