2007-08-29 18:23:50 +02:00
|
|
|
.TH IM_BUILDLUT 3 "June 2006"
|
|
|
|
.SH NAME
|
|
|
|
im_buildlut \- build a LUT from a set of x/y points
|
|
|
|
.SH SYNOPSIS
|
|
|
|
#include <vips/vips.h>
|
|
|
|
|
|
|
|
int
|
|
|
|
.br
|
|
|
|
im_buildlut( DOUBLEMASK *input, IMAGE *output )
|
|
|
|
|
|
|
|
.SH DESCRIPTION
|
|
|
|
.B im_buildlut(3)
|
|
|
|
constructs a LUT, interpolating a set of x/y points. Interpolation is strictly
|
|
|
|
piecewise linear. For example, if the input is:
|
|
|
|
|
2009-03-18 17:47:17 +01:00
|
|
|
0 0
|
|
|
|
128 20
|
|
|
|
255 100
|
2007-08-29 18:23:50 +02:00
|
|
|
|
|
|
|
we generate
|
|
|
|
|
2009-03-18 17:47:17 +01:00
|
|
|
0 0
|
|
|
|
1 0.01
|
|
|
|
.. etc. linear interpolation
|
|
|
|
128 20
|
|
|
|
129 20.5
|
|
|
|
.. etc. linear interpolation
|
|
|
|
255 100
|
2007-08-29 18:23:50 +02:00
|
|
|
|
|
|
|
the x axis (12 .. 17) is implied. The x/y points don't need to be
|
|
|
|
sorted: we do that. You can have several Ys ... each becomes a band in the
|
|
|
|
output LUT.
|
|
|
|
|
|
|
|
.SH RETURN VALUE
|
|
|
|
-1 on error, otherwise 0
|
|
|
|
.SH SEE ALSO
|
|
|
|
im_invertlut(3), im_identity(3).
|
|
|
|
.SH COPYRIGHT
|
|
|
|
2006, Imperial College
|