Sophie

Sophie

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

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>CONVERSIONS(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_scale, im_scaleps - scale an image to unsigned char image 
<h2><a name='sect1' href='#toc1'>Synopsis</a></h2>
#include
&lt;vips/vips.h&gt; 
<p> int im_scale(in, out) <br>
IMAGE *in, *out; 
<p> int im_scaleps(in, out) <br>
IMAGE *in, *out; 
<h2><a name='sect2' href='#toc2'>Description</a></h2>
These functions scale a non-complex image to
a displayable byte (unsigned char) image. 
<p> im_scale() scales the image held
by image descriptor to a byte (unsigned char) image and writes the result
on the image descriptor out.  Sizes and the number of the bands of out are
identical to those of input.  Input image should be non complex and can
have any number of channels.   The output is scaled between 0 and 255; if
the image is multiband the maximum value of all channels is set to 255
and the minimum to 0.  In all cases, rounding is performed by adding .5 to
the scaled values. 
<p> <b>im_scaleps()</b> scales to 0 - 255 by mapping each pixel

<p>through the equation 
<p>    log10(1.0 + pow(x, 0.25))<br>
 
<p> and then multiplying by a factor so that the image maximum is 255. 
<p> This
transformation highlights both low and high spatial  frequencies in the
power spectrum.   The images produced by this non-linear transformation are
only for display and not for further processing. 
<h2><a name='sect3' href='#toc3'>Return Value</a></h2>
Each function
returns 0 on success and -1 on error. 
<h2><a name='sect4' href='#toc4'>See Also</a></h2>
<a href='im_any2c.3.html'>im_any2c(3)</a>
, <a href='im_c2amph.3.html'>im_c2amph(3)</a>
,
<a href='im_clip.3.html'>im_clip(3)</a>
  <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>
</ul>
</body>
</html>