Sophie

Sophie

distrib > Mageia > 1 > i586 > by-pkgid > 254cc853e818c6f29f3290af5267eed6 > files > 92

graphicsmagick-doc-1.3.12-3.3.mga1.i586.rpm

<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="generator" content="Docutils 0.5: http://docutils.sourceforge.net/" />
<title>image</title>
<link rel="stylesheet" href="../docutils-api.css" type="text/css" />
</head>
<body>

<div class="banner">
<span>
<img src="../images/gm-107x76.png" alt="GraphicMagick logo" width="107" height="76" />
<span class="title">GraphicsMagick</span>
<form action="http://www.google.com/search">
    Search&nbsp;site
	<input type=hidden name="domains" value="www.graphicsmagick.org" />
	<input type=hidden name="sitesearch" value="www.graphicsmagick.org" />
    <input type=text name="q" size="25" maxlength="255" />
    <input type=submit name="sa" value="Search" />
</form>
</span>
</div>

<div class="navmenu">
<ul>
<li><a href="../index.html">Home</a></li>
<li><a href="../Copyright.html">License</a></li>
<li><a href="../mission.html">Mission</a></li>
<li><a href="../download.html">Download</a></li>
<li><a href="../README.html">Installation</a></li>
<li><a href="../FAQ.html">FAQ</a></li>
<li><a href="../NEWS.html">News</a> </li>
<li><a href="../formats.html">Formats</a></li>
</ul>
</div>
<div class="navmenu">
<ul>
<li><a href="../process.html">Process</a></li>
<li><a href="../contribute.html">Contribute</a></li>
<li><a href="../CVS.html">CVS</a></li>
<li><a href="http://sourceforge.net/mail/?group_id=73485" target="top_">Mailing Lists</a></li>
<li><a href="../Changelog.html">ChangeLog</a></li>
<li><a href="http://sourceforge.net/projects/graphicsmagick/" target="top_">Report Bugs</a></li>
<li><a href="../utilities.html">Utilities</a></li>
<li><a href="../programming.html">Programming</a></li>
<li><a href="../links.html">Links</a></li>
</ul>
</div>
<div class="document" id="image">
<h1 class="title">image</h1>
<h2 class="subtitle" id="miscellaneous-image-methods">Miscellaneous image methods</h2>

<div class="contents topic" id="contents">
<p class="topic-title first">Contents</p>
<ul class="simple">
<li><a class="reference internal" href="#accessdefinition" id="id52">AccessDefinition</a></li>
<li><a class="reference internal" href="#adddefinitions" id="id53">AddDefinitions</a></li>
<li><a class="reference internal" href="#allocateimage" id="id54">AllocateImage</a></li>
<li><a class="reference internal" href="#allocatenextimage" id="id55">AllocateNextImage</a></li>
<li><a class="reference internal" href="#animateimages" id="id56">AnimateImages</a></li>
<li><a class="reference internal" href="#appendimages" id="id57">AppendImages</a></li>
<li><a class="reference internal" href="#catchimageexception" id="id58">CatchImageException</a></li>
<li><a class="reference internal" href="#clippathimage" id="id59">ClipPathImage</a></li>
<li><a class="reference internal" href="#cloneimage" id="id60">CloneImage</a></li>
<li><a class="reference internal" href="#cloneimageinfo" id="id61">CloneImageInfo</a></li>
<li><a class="reference internal" href="#destroyimage" id="id62">DestroyImage</a></li>
<li><a class="reference internal" href="#destroyimageinfo" id="id63">DestroyImageInfo</a></li>
<li><a class="reference internal" href="#displayimages" id="id64">DisplayImages</a></li>
<li><a class="reference internal" href="#getimageclipmask" id="id65">GetImageClipMask</a></li>
<li><a class="reference internal" href="#getimageexception" id="id66">GetImageException</a></li>
<li><a class="reference internal" href="#getimagegeometry" id="id67">GetImageGeometry</a></li>
<li><a class="reference internal" href="#getimageinfo" id="id68">GetImageInfo</a></li>
<li><a class="reference internal" href="#istaintimage" id="id69">IsTaintImage</a></li>
<li><a class="reference internal" href="#modifyimage" id="id70">ModifyImage</a></li>
<li><a class="reference internal" href="#referenceimage" id="id71">ReferenceImage</a></li>
<li><a class="reference internal" href="#removedefinitions" id="id72">RemoveDefinitions</a></li>
<li><a class="reference internal" href="#setimage" id="id73">SetImage</a></li>
<li><a class="reference internal" href="#setimageclipmask" id="id74">SetImageClipMask</a></li>
<li><a class="reference internal" href="#setimagedepth" id="id75">SetImageDepth</a></li>
<li><a class="reference internal" href="#setimageopacity" id="id76">SetImageOpacity</a></li>
<li><a class="reference internal" href="#setimagetype" id="id77">SetImageType</a></li>
</ul>
</div>
<div class="section" id="accessdefinition">
<h1><a class="toc-backref" href="#id52">AccessDefinition</a></h1>
<div class="section" id="synopsis">
<h2>Synopsis</h2>
<pre class="literal-block">
const char *AccessDefinition( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, const char *magick,
                              const char *key );
</pre>
</div>
<div class="section" id="description">
<h2>Description</h2>
<p>AccessDefinition() searches the definitions for an entry matching the
specified magick and key. NULL is returned if no matching entry is found.</p>
<p>The format of the AccessDefinition method is:</p>
<pre class="literal-block">
const char *AccessDefinition( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, const char *magick,
                              const char *key );
</pre>
<dl class="docutils">
<dt>image_info:</dt>
<dd>The image info.</dd>
<dt>magick:</dt>
<dd>Format ID. This is usually the same as the coder name.</dd>
<dt>key:</dt>
<dd>Key to search for.</dd>
</dl>
</div>
</div>
<div class="section" id="adddefinitions">
<h1><a class="toc-backref" href="#id53">AddDefinitions</a></h1>
<div class="section" id="id2">
<h2>Synopsis</h2>
<pre class="literal-block">
void AddDefinitions( <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, const char *options );
</pre>
</div>
<div class="section" id="id3">
<h2>Description</h2>
<p>AddDefinitions() adds definitions from a key/value based string to the current
map of definitions in ImageInfo. Definitions may be used by coders/decoders
that read and write images.</p>
<p>The format of the AddDefinitions method is:</p>
<pre class="literal-block">
void AddDefinitions( <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, const char *options );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image_info:</dt>
<dd>The image info.</dd>
<dt>options:</dt>
<dd>List of key/value pairs to put in the definitions map. The
format of the string is &quot;key1[=[value1]],key2[=[value2]],...&quot;. A missing
value argument (with or without the equal sign) inserts an empty, zero
length string as value for a key.</dd>
<dt>exception:</dt>
<dd>Errors result in updates to this structure.</dd>
</dl>
</div>
</div>
<div class="section" id="allocateimage">
<h1><a class="toc-backref" href="#id54">AllocateImage</a></h1>
<div class="section" id="id4">
<h2>Synopsis</h2>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *AllocateImage( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info );
</pre>
</div>
<div class="section" id="id5">
<h2>Description</h2>
<p>AllocateImage() returns a pointer to an image structure initialized to
default values.</p>
<p>The format of the AllocateImage method is:</p>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *AllocateImage( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image_info:</dt>
<dd>Many of the image default values are set from this
structure.  For example, filename, compression, depth, background color,
and others.</dd>
</dl>
</div>
</div>
<div class="section" id="allocatenextimage">
<h1><a class="toc-backref" href="#id55">AllocateNextImage</a></h1>
<div class="section" id="id6">
<h2>Synopsis</h2>
<pre class="literal-block">
void AllocateNextImage( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
</div>
<div class="section" id="id7">
<h2>Description</h2>
<p>Use AllocateNextImage() to initialize the next image in a sequence to
default values.  The next member of image points to the newly allocated
image.  If there is a memory shortage, next is assigned NULL.</p>
<p>The format of the AllocateNextImage method is:</p>
<pre class="literal-block">
void AllocateNextImage( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image_info:</dt>
<dd>Many of the image default values are set from this
structure.  For example, filename, compression, depth, background color,
and others.</dd>
<dt>image:</dt>
<dd>The image.</dd>
</dl>
</div>
</div>
<div class="section" id="animateimages">
<h1><a class="toc-backref" href="#id56">AnimateImages</a></h1>
<div class="section" id="id8">
<h2>Synopsis</h2>
<pre class="literal-block">
unsigned int AnimateImages( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
</div>
<div class="section" id="id9">
<h2>Description</h2>
<p>AnimateImages() repeatedly displays an image sequence to any X window
screen.  It returns a value other than 0 if successful.  Check the
exception member of image to determine the reason for any failure.</p>
<p>The format of the AnimateImages method is:</p>
<pre class="literal-block">
unsigned int AnimateImages( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image_info:</dt>
<dd>The image info.</dd>
<dt>image:</dt>
<dd>The image.</dd>
</dl>
</div>
</div>
<div class="section" id="appendimages">
<h1><a class="toc-backref" href="#id57">AppendImages</a></h1>
<div class="section" id="id10">
<h2>Synopsis</h2>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *AppendImages( const <a class="reference external" href="../api/types.html#image">Image</a> *image, const unsigned int stack,
                     <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
</div>
<div class="section" id="id11">
<h2>Description</h2>
<p>The AppendImages() method takes a set of images and appends them to each
other top-to-bottom if the stack parameter is true, otherwise left-to-right.</p>
<p>The format of the AppendImage method is:</p>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *AppendImages( const <a class="reference external" href="../api/types.html#image">Image</a> *image, const unsigned int stack,
                     <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
<dl class="docutils">
<dt>image:</dt>
<dd>The image sequence.</dd>
<dt>stack:</dt>
<dd>A value other than 0 stacks the images top-to-bottom.</dd>
<dt>exception:</dt>
<dd>Return any errors or warnings in this structure.</dd>
</dl>
</div>
</div>
<div class="section" id="catchimageexception">
<h1><a class="toc-backref" href="#id58">CatchImageException</a></h1>
<div class="section" id="id12">
<h2>Synopsis</h2>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#exceptiontype">ExceptionType</a> CatchImageException( <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
</div>
<div class="section" id="id13">
<h2>Description</h2>
<p>CatchImageException() returns if no exceptions are found in the image
sequence, otherwise it determines the most severe exception and reports
it as a warning or error depending on the severity.</p>
<p>The format of the CatchImageException method is:</p>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#exceptiontype">ExceptionType</a> CatchImageException( <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>An image sequence.</dd>
</dl>
</div>
</div>
<div class="section" id="clippathimage">
<h1><a class="toc-backref" href="#id59">ClipPathImage</a></h1>
<div class="section" id="id14">
<h2>Synopsis</h2>
<pre class="literal-block">
unsigned int ClipPathImage( <a class="reference external" href="../api/types.html#image">Image</a> *image, const char *pathname,
                            const unsigned int inside );
</pre>
</div>
<div class="section" id="id15">
<h2>Description</h2>
<p>ClipPathImage() sets the image clip mask based any clipping path information
if it exists.</p>
<p>The format of the ClipPathImage method is:</p>
<pre class="literal-block">
unsigned int ClipPathImage( <a class="reference external" href="../api/types.html#image">Image</a> *image, const char *pathname,
                            const unsigned int inside );
</pre>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
<dt>pathname:</dt>
<dd>name of clipping path resource. If name is preceded by #, use
clipping path numbered by name.</dd>
<dt>inside:</dt>
<dd>if non-zero, later operations take effect inside clipping path.
Otherwise later operations take effect outside clipping path.</dd>
</dl>
</div>
</div>
<div class="section" id="cloneimage">
<h1><a class="toc-backref" href="#id60">CloneImage</a></h1>
<div class="section" id="id16">
<h2>Synopsis</h2>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *CloneImage( const <a class="reference external" href="../api/types.html#image">Image</a> *image, const unsigned long columns,
                   const unsigned long rows, const unsigned int orphan,
                   <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
</div>
<div class="section" id="id17">
<h2>Description</h2>
<p>CloneImage() copies an image and returns the copy as a new image object.
If the specified columns and rows is 0, an exact copy of the image is
returned, otherwise the pixel data is undefined and must be initialized
with the SetImagePixels() and SyncImagePixels() methods.  On failure,
a NULL image is returned and exception describes the reason for the
failure.</p>
<p>The format of the CloneImage method is:</p>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *CloneImage( const <a class="reference external" href="../api/types.html#image">Image</a> *image, const unsigned long columns,
                   const unsigned long rows, const unsigned int orphan,
                   <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
<dt>columns:</dt>
<dd>The number of columns in the cloned image.</dd>
<dt>rows:</dt>
<dd>The number of rows in the cloned image.</dd>
<dt>orphan:</dt>
<dd>With a value other than 0, the cloned image is an orphan.  An
orphan is a stand-alone image that is not assocated with an image list.
In effect, the next and previous members of the cloned image is set to
NULL.</dd>
<dt>exception:</dt>
<dd>Return any errors or warnings in this structure.</dd>
</dl>
</div>
</div>
<div class="section" id="cloneimageinfo">
<h1><a class="toc-backref" href="#id61">CloneImageInfo</a></h1>
<div class="section" id="id18">
<h2>Synopsis</h2>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *CloneImageInfo( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info );
</pre>
</div>
<div class="section" id="id19">
<h2>Description</h2>
<p>CloneImageInfo() makes a copy of the given image info structure.  If
NULL is specified, a new image info structure is created initialized to
default values.</p>
<p>The format of the CloneImageInfo method is:</p>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *CloneImageInfo( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image_info:</dt>
<dd>The image info.</dd>
</dl>
</div>
</div>
<div class="section" id="destroyimage">
<h1><a class="toc-backref" href="#id62">DestroyImage</a></h1>
<div class="section" id="id20">
<h2>Synopsis</h2>
<pre class="literal-block">
void DestroyImage( <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
</div>
<div class="section" id="id21">
<h2>Description</h2>
<p>DestroyImage() dereferences an image, deallocating memory associated with
the image if the reference count becomes zero.</p>
<p>The format of the DestroyImage method is:</p>
<pre class="literal-block">
void DestroyImage( <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
</dl>
</div>
</div>
<div class="section" id="destroyimageinfo">
<h1><a class="toc-backref" href="#id63">DestroyImageInfo</a></h1>
<div class="section" id="id22">
<h2>Synopsis</h2>
<pre class="literal-block">
void DestroyImageInfo( <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info );
</pre>
</div>
<div class="section" id="id23">
<h2>Description</h2>
<p>DestroyImageInfo() deallocates memory associated with a ImageInfo
structure.</p>
<p>The format of the DestroyImageInfo method is:</p>
<pre class="literal-block">
void DestroyImageInfo( <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image_info:</dt>
<dd>The image info.</dd>
</dl>
</div>
</div>
<div class="section" id="displayimages">
<h1><a class="toc-backref" href="#id64">DisplayImages</a></h1>
<div class="section" id="id24">
<h2>Synopsis</h2>
<pre class="literal-block">
unsigned int DisplayImages( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
</div>
<div class="section" id="id25">
<h2>Description</h2>
<p>DisplayImages() displays an image sequence to any X window screen.  It
returns a value other than 0 if successful.  Check the exception member
of image to determine the reason for any failure.</p>
<p>The format of the DisplayImages method is:</p>
<pre class="literal-block">
unsigned int DisplayImages( const <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image_info:</dt>
<dd>The image info.</dd>
<dt>image:</dt>
<dd>The image.</dd>
</dl>
</div>
</div>
<div class="section" id="getimageclipmask">
<h1><a class="toc-backref" href="#id65">GetImageClipMask</a></h1>
<div class="section" id="id26">
<h2>Synopsis</h2>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *GetImageClipMask( const <a class="reference external" href="../api/types.html#image">Image</a> *image, <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
</div>
<div class="section" id="id27">
<h2>Description</h2>
<p>GetImageClipMask returns a reference-counted copy of the current image
clip mask. This copy must be deallocated using DestroyImage() once it is
no longer needed.  If the image does not have an associated clip mask,
then NULL is returned.  Use SetImageClipMask() to add a clip mask to an
image, or remove a clip mask.</p>
<p>If a component of the clip mask is set to TransparentOpacity (maximum
value) then the corresponding image pixel component will not be updated
when SyncImagePixels() is applied. The clip mask may be used to constrain
the results of an image processing operation to a region of the image.
Regions outside those allowed by the clip mask may be processed, but only
pixel quantums allowed by the clip mask will actually be updated.</p>
<p>The clip mask protects the DirectClass pixels and PseudoClass pixel indexes
from modification. The clip mask does <em>not</em> protect the image colormap since
the image colormap is globally shared by all pixels in a PseudoClass image.</p>
<p>The format of the GetImageClipMask method is</p>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *GetImageClipMask( const <a class="reference external" href="../api/types.html#image">Image</a> *image, <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
<p>A descripton of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
<dt>exception:</dt>
<dd>Reason for failure.</dd>
</dl>
</div>
</div>
<div class="section" id="getimageexception">
<h1><a class="toc-backref" href="#id66">GetImageException</a></h1>
<div class="section" id="id28">
<h2>Synopsis</h2>
<pre class="literal-block">
void GetImageException( <a class="reference external" href="../api/types.html#image">Image</a> *image, <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
</div>
<div class="section" id="id29">
<h2>Description</h2>
<p>GetImageException() traverses an image sequence and returns any
error more severe than noted by the exception parameter.</p>
<p>The format of the GetImageException method is:</p>
<pre class="literal-block">
void GetImageException( <a class="reference external" href="../api/types.html#image">Image</a> *image, <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>Specifies a pointer to a list of one or more images.</dd>
<dt>exception:</dt>
<dd>return the highest severity exception.</dd>
</dl>
</div>
</div>
<div class="section" id="getimagegeometry">
<h1><a class="toc-backref" href="#id67">GetImageGeometry</a></h1>
<div class="section" id="id30">
<h2>Synopsis</h2>
<pre class="literal-block">
int GetImageGeometry( const <a class="reference external" href="../api/types.html#image">Image</a> *image, const char *geometry,
                      const unsigned int size_to_fit, <a class="reference external" href="../api/types.html#rectangleinfo">RectangleInfo</a> *region_info );
</pre>
</div>
<div class="section" id="id31">
<h2>Description</h2>
<p>GetImageGeometry() returns a region as defined by the geometry string with
respect to the image and its gravity.</p>
<p>The format of the GetImageGeometry method is:</p>
<pre class="literal-block">
int GetImageGeometry( const <a class="reference external" href="../api/types.html#image">Image</a> *image, const char *geometry,
                      const unsigned int size_to_fit, <a class="reference external" href="../api/types.html#rectangleinfo">RectangleInfo</a> *region_info );
</pre>
<dl class="docutils">
<dt>flags:</dt>
<dd>Method GetImageGeometry returns a bitmask that indicates
which of the four values were located in the geometry string.</dd>
<dt>geometry:</dt>
<dd>The geometry (e.g. 100x100+10+10).</dd>
<dt>size_to_fit:</dt>
<dd>A value other than 0 means to scale the region so it
fits within the specified width and height.</dd>
<dt>region_info:</dt>
<dd>The region as defined by the geometry string with
respect to the image and its gravity.</dd>
</dl>
</div>
</div>
<div class="section" id="getimageinfo">
<h1><a class="toc-backref" href="#id68">GetImageInfo</a></h1>
<div class="section" id="id32">
<h2>Synopsis</h2>
<pre class="literal-block">
void GetImageInfo( <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info );
</pre>
</div>
<div class="section" id="id33">
<h2>Description</h2>
<p>GetImageInfo() initializes image_info to default values.</p>
<p>The format of the GetImageInfo method is:</p>
<pre class="literal-block">
void GetImageInfo( <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image_info:</dt>
<dd>The image info.</dd>
</dl>
</div>
</div>
<div class="section" id="istaintimage">
<h1><a class="toc-backref" href="#id69">IsTaintImage</a></h1>
<div class="section" id="id34">
<h2>Synopsis</h2>
<pre class="literal-block">
unsigned int IsTaintImage( const <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
</div>
<div class="section" id="id35">
<h2>Description</h2>
<p>IsTaintImage() returns a value other than 0 if any pixel in the image
has been altered since it was first constituted.</p>
<p>The format of the IsTaintImage method is:</p>
<pre class="literal-block">
unsigned int IsTaintImage( const <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
</dl>
</div>
</div>
<div class="section" id="modifyimage">
<h1><a class="toc-backref" href="#id70">ModifyImage</a></h1>
<div class="section" id="id36">
<h2>Synopsis</h2>
<pre class="literal-block">
ModifyImage( <a class="reference external" href="../api/types.html#image">Image</a> *image, <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
</div>
<div class="section" id="id37">
<h2>Description</h2>
<p>ModifyImage() ensures that there is only a single reference to the image
to be modified, updating the provided image pointer to point to a clone of
the original image if necessary.</p>
<p>The format of the ModifyImage method is:</p>
<pre class="literal-block">
ModifyImage( <a class="reference external" href="../api/types.html#image">Image</a> *image, <a class="reference external" href="../api/types.html#exceptioninfo">ExceptionInfo</a> *exception );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
<dt>exception:</dt>
<dd>Return any errors or warnings in this structure.</dd>
</dl>
</div>
</div>
<div class="section" id="referenceimage">
<h1><a class="toc-backref" href="#id71">ReferenceImage</a></h1>
<div class="section" id="id38">
<h2>Synopsis</h2>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *ReferenceImage( <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
</div>
<div class="section" id="id39">
<h2>Description</h2>
<p>ReferenceImage() increments the reference count associated with an image
returning a pointer to the image.</p>
<p>The format of the ReferenceImage method is:</p>
<pre class="literal-block">
<a class="reference external" href="../api/types.html#image">Image</a> *ReferenceImage( <a class="reference external" href="../api/types.html#image">Image</a> *image );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
</dl>
</div>
</div>
<div class="section" id="removedefinitions">
<h1><a class="toc-backref" href="#id72">RemoveDefinitions</a></h1>
<div class="section" id="id40">
<h2>Synopsis</h2>
<pre class="literal-block">
void RemoveDefinitions( <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, const char *options );
</pre>
</div>
<div class="section" id="id41">
<h2>Description</h2>
<p>RemoveDefinitions() removes definitions from the current map of definitions
in ImageInfo. Definitions may be used by coders/decoders that read and
write images. RemoveDefinitions() returns true only if the specified keys
are present in the map and are actually removed.</p>
<p>The format of the RemoveDefinitions method is:</p>
<pre class="literal-block">
void RemoveDefinitions( <a class="reference external" href="../api/types.html#imageinfo">ImageInfo</a> *image_info, const char *options );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image_info:</dt>
<dd>The image info.</dd>
<dt>keys:</dt>
<dd>List of keys to remove from the definitions map. The
format of the string is &quot;key1,key2,...&quot;. A special key, '*', removes
all the key/value pairs in the definitions map. This key always
succeeds.</dd>
<dt>exception:</dt>
<dd>Errors result in updates to this structure.</dd>
</dl>
</div>
</div>
<div class="section" id="setimage">
<h1><a class="toc-backref" href="#id73">SetImage</a></h1>
<div class="section" id="id42">
<h2>Synopsis</h2>
<pre class="literal-block">
void SetImage( <a class="reference external" href="../api/types.html#image">Image</a> *image, const <a class="reference external" href="../api/types.html#quantum">Quantum</a> opacity );
</pre>
</div>
<div class="section" id="id43">
<h2>Description</h2>
<p>SetImage() sets the red, green, and blue components of each pixel to
the image background color and the opacity component to the specified
level of transparency.  The background color is defined by the
background_color member of the image.</p>
<p>The format of the SetImage method is:</p>
<pre class="literal-block">
void SetImage( <a class="reference external" href="../api/types.html#image">Image</a> *image, const <a class="reference external" href="../api/types.html#quantum">Quantum</a> opacity );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
<dt>opacity:</dt>
<dd>Set each pixel to this level of transparency.</dd>
</dl>
</div>
</div>
<div class="section" id="setimageclipmask">
<h1><a class="toc-backref" href="#id74">SetImageClipMask</a></h1>
<div class="section" id="id44">
<h2>Synopsis</h2>
<pre class="literal-block">
unsigned int SetImageClipMask( <a class="reference external" href="../api/types.html#image">Image</a> *image, const <a class="reference external" href="../api/types.html#image">Image</a> *clip_mask );
</pre>
</div>
<div class="section" id="id45">
<h2>Description</h2>
<p>SetImageClipMask() associates a clip mask with the image.  The clip mask
must be the same dimensions as the image.</p>
<p>If a component of the clip mask is set to TransparentOpacity (maximum
value) then the corresponding image pixel component will not be updated
when SyncImagePixels() is applied. The clip mask may be used to constrain
the results of an image processing operation to a region of the image.
Regions outside those allowed by the clip mask may be processed, but only
pixel quantums allowed by the clip mask will actually be updated.</p>
<p>The clip mask protects the DirectClass pixels and PseudoClass pixel indexes
from modification. The clip mask does <em>not</em> protect the image colormap since
the image colormap is globally shared by all pixels in a PseudoClass image.</p>
<p>The format of the SetImageClipMask method is:</p>
<pre class="literal-block">
unsigned int SetImageClipMask( <a class="reference external" href="../api/types.html#image">Image</a> *image, const <a class="reference external" href="../api/types.html#image">Image</a> *clip_mask );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
<dt>clip_mask:</dt>
<dd>The image clip mask.</dd>
</dl>
</div>
</div>
<div class="section" id="setimagedepth">
<h1><a class="toc-backref" href="#id75">SetImageDepth</a></h1>
<div class="section" id="id46">
<h2>Synopsis</h2>
<pre class="literal-block">
unsigned int SetImageDepth( <a class="reference external" href="../api/types.html#image">Image</a> *image, const unsigned long depth );
</pre>
</div>
<div class="section" id="id47">
<h2>Description</h2>
<p>SetImageDepth() translates the pixel quantums across all of the channels
so that if they are later divided to fit within the specified bit
depth, that no additional information is lost (i.e. no remainder will
result from the division).  Note that any subsequent image processing is
likely to increase the effective depth of the image channels. A non-zero
value is returned if the operation is successful. Check the exception
member of image to determine the cause for any failure.</p>
<p>The format of the SetImageDepth method is:</p>
<pre class="literal-block">
unsigned int SetImageDepth( <a class="reference external" href="../api/types.html#image">Image</a> *image, const unsigned long depth );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image to update.</dd>
<dt>depth:</dt>
<dd>Desired image depth (range 1 to QuantumDepth)</dd>
</dl>
</div>
</div>
<div class="section" id="setimageopacity">
<h1><a class="toc-backref" href="#id76">SetImageOpacity</a></h1>
<div class="section" id="id48">
<h2>Synopsis</h2>
<pre class="literal-block">
void SetImageOpacity( <a class="reference external" href="../api/types.html#image">Image</a> *image, const unsigned int opacity );
</pre>
</div>
<div class="section" id="id49">
<h2>Description</h2>
<p>SetImageOpacity() attenuates the opacity channel of an image.  If the
image pixels are opaque, they are set to the specified opacity level.
Otherwise, the pixel opacity values are blended with the supplied
transparency value.</p>
<p>The format of the SetImageOpacity method is:</p>
<pre class="literal-block">
void SetImageOpacity( <a class="reference external" href="../api/types.html#image">Image</a> *image, const unsigned int opacity );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
<dt>opacity:</dt>
<dd>The level of transparency: 0 is fully opaque and MaxRGB is
fully transparent.</dd>
</dl>
</div>
</div>
<div class="section" id="setimagetype">
<h1><a class="toc-backref" href="#id77">SetImageType</a></h1>
<div class="section" id="id50">
<h2>Synopsis</h2>
<pre class="literal-block">
( void )SetImageType( <a class="reference external" href="../api/types.html#image">Image</a> *image, const <a class="reference external" href="../api/types.html#imagetype">ImageType</a> image_type );
</pre>
</div>
<div class="section" id="id51">
<h2>Description</h2>
<p>(void) SetImageType() sets the type of image.  Choose from these types:</p>
<p>Bilevel        Grayscale       GrayscaleMatte
Palette        PaletteMatte    TrueColor
TrueColorMatte ColorSeparation ColorSeparationMatte
OptimizeType</p>
<p>The format of the (void) SetImageType method is:</p>
<pre class="literal-block">
( void )SetImageType( <a class="reference external" href="../api/types.html#image">Image</a> *image, const <a class="reference external" href="../api/types.html#imagetype">ImageType</a> image_type );
</pre>
<p>A description of each parameter follows:</p>
<dl class="docutils">
<dt>image:</dt>
<dd>The image.</dd>
<dt>image_type:</dt>
<dd>Image type.</dd>
</dl>
</div>
</div>
</div>
<div class="footer">
<hr class="footer" />
Generated on: 2010-03-07 19:17 UTC.

</div>
</body>
</html>