Sophie

Sophie

distrib > Mandriva > 2010.0 > i586 > media > contrib-release > by-pkgid > c109337651527e96d7bb9adc83c5b18a > files > 554

libvips-devel-7.18.2-1mdv2010.0.i586.rpm

<!-- manual page source format generated by PolyglotMan v3.2, -->
<!-- available at http://polyglotman.sourceforge.net/ -->

<html>
<head>
<title>TONE(3) manual page</title>
</head>
<body bgcolor='white'>
<a href='#toc'>Table of Contents</a><p>

<h2><a name='sect0' href='#toc0'>Name</a></h2>
im_tone_build, im_tone_map, im_tone_analyse, im_tone_build_range - tone-curve
adjustment of LAB images 
<h2><a name='sect1' href='#toc1'>Synopsis</a></h2>

<p> int  <br>
im_tone_build_range(  <br>
   int in_max, int out_max,<br>
 <br>
   IMAGE *lut, <br>
 <br>
   double Lb, double Lw,<br>
 <br>
   double Ps, double Pm, double Ph,<br>
 <br>
   double S, double M, double H )<br>
 
<p> int  <br>
im_tone_build(  <br>
   IMAGE *lut, <br>
 <br>
   double Lb, double Lw,<br>
 <br>
   double Ps, double Pm, double Ph,<br>
 <br>
   double S, double M, double H )<br>
 
<p> int  <br>
im_tone_analyse(  <br>
   IMAGE *in, <br>
 <br>
   IMAGE *lut, <br>
 <br>
   double Ps, double Pm, double Ph,<br>
 <br>
   double S, double M, double H )<br>
 
<p> int  <br>
im_tone_map( IMAGE *in, IMAGE *out, IMAGE *lut ) 
<p> 
<h2><a name='sect2' href='#toc2'>Description</a></h2>
Various functions
relating to tone curve adjustment. Example tone curve: 
<p>  repro L* out<br>
      ^ <br>
      |<br>
  100 | . . . . . . . . . . . . . . . .*      <br>
      |                              * .                              <br>
   Lw | . . . . . . . . . . . . . .*   .                    <br>
      |                          * .   .                           <br>
      |                        /*  .   .                         <br>
      |                      / *   .   .                       <br>
      |                    / .*    .   .                     <br>
      |              * * /* *.     .   .                   <br>
      |           * *  /     .     .   .                 <br>
      |         *    / .     .     .   .               <br>
      |        *   /   .     .     .   .             <br>
      |       *  /     .     .     .   .           <br>
      |      * / .     .     .     .   .         <br>
      |     */   .     .     .     .   .       <br>
   Lb | . .*     .     .     .     .   .     <br>
      |  * .     .     .     .     .   .   <br>
      |*   .     .     .     .     .   . <br>
    0 +---------------------------------------&gt;<br>
      0    Lb    Ls    Lm    Lh    Lw  100   L* in<br>
 
<p> <a href='im_tone_build_range.3.html'><b>im_tone_build_range(3)</b></a>
 generates a tone curve for the adjustment of image
levels. The curve is an unsigned 16-bit image with (in_max + 1) entries,
each in the range [0, out_max]. 
<p> The parameters are expressed as 0-100, as
in LAB colour space, but you specify the scaling for the input and output
images with the in_max and out_max parameters. 
<p> Parameters: 
<p>     Lb  - black
point<br>
     Lw  - white point<tt> </tt>&nbsp;<tt> </tt>&nbsp;<br>
 
<p> Both in L* units, ie. in the range [0,100]. These should be set by histogram
analysis of the image to be transformed to 0.1% and 99.9% of the full range
of the image. See im_tone_analyse() below.  <br>
     Ps  - shadow point<br>
     Pm  - mid-tone point<br>
     Ph  - highlight point<br>
  <br>
 All in [0,1], meaning max of shadow section of curve should be positioned
at Lb+Ps(Lw-Lb), etc. Suggested values: Ps, Pm, Ph should be 0.2, 0.5 and 0.8.
Ps is limited to the range [0.1,0.3], Pm to the range [0.4,0.6] and Ph to [0.7,0.9].
 <br>
     S  - shadow adjustment factor (+/- 15)<br>
     M  - mid-tone adjustment factor (+/- 30)<br>
     H  - highlight adjustment factor (+/- 15)<br>
 
<p> These are the principal parameters, controlling the brightness in the
shadow, mid-tone and highlight areas. Suggested values: 
<p>     0, 0,  0   -
no change to input image<br>
     5, 0, -2   - boost shadows a little, depress highlights slightly<br>
 
<p> <a href='im_tone_build.3.html'><b>im_tone_build(3)</b></a>
 is a convenience function that calls  <a href='im_tone_build_range.3.html'><b>im_tone_build_range(3)</b></a>

with ranges suitable for tone correcting a LABQ image to a LABS image. 
<p>
Use  <a href='im_ismonotonic.3.html'><b>im_ismonotonic(3)</a>
 </b> to check that the slope of your tone curve is always
&gt;0, use  <a href='im_histplot.3.html'><b>im_histplot(3)</a>
 </b> to graph the curve, use  <a href='im_tone_map.3.html'><b>im_tone_map(3)</a>
 </b> to apply
your curve to an image. 
<p> <a href='im_tone_map.3.html'><b>im_tone_map(3)</b></a>
 map just the L channel of a LabQ
or LabS image through a tone curve. 
<p> <a href='im_tone_analyse.3.html'><b>im_tone_analyse(3)</b></a>
 find the histogram
of a LabS or LabQ image and use that to set the Ln and Lw parameters of
 <a href='im_tone_build.3.html'><b>im_tone_build(3)</a>
. </b> All other parameters as above. 
<p> Example: 
<p>   example%
im_tone_analyse $VIPSHOME/pics/master.v /tmp/lut.v <br>
      0.2 0.5 0.8 6.3 0.8 -3<br>
   example% im_ismonotonic /tmp/lut.v<br>
   255<br>
   example% im_tone_map $VIPSHOME/pics/master.v /tmp/master2.v /tmp/lut.v<br>
 
<p> 
<h2><a name='sect3' href='#toc3'>Return Value</a></h2>
All functions returns 0 on success and -1 on error. 
<h2><a name='sect4' href='#toc4'>See Also</a></h2>
<a href='im_histplot.3.html'>im_histplot(3)</a>
,
<a href='im_ismonotonic.3.html'>im_ismonotonic(3)</a>
. 
<h2><a name='sect5' href='#toc5'>Copyright</a></h2>
1995, National Gallery  
<h2><a name='sect6' href='#toc6'>Authors</a></h2>
J. Cupitt <p>

<hr><p>
<a name='toc'><b>Table of Contents</b></a><p>
<ul>
<li><a name='toc0' href='#sect0'>Name</a></li>
<li><a name='toc1' href='#sect1'>Synopsis</a></li>
<li><a name='toc2' href='#sect2'>Description</a></li>
<li><a name='toc3' href='#sect3'>Return Value</a></li>
<li><a name='toc4' href='#sect4'>See Also</a></li>
<li><a name='toc5' href='#sect5'>Copyright</a></li>
<li><a name='toc6' href='#sect6'>Authors</a></li>
</ul>
</body>
</html>