Files
gimp/devel-docs/libgimp/html/libgimp-gimpimage.html
2010-08-11 01:18:40 -04:00

3442 lines
107 KiB
HTML

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<title>gimpimage</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.68.1">
<link rel="start" href="index.html" title="GIMP Library Reference Manual">
<link rel="up" href="libgimp-image.html" title="Manupulating Images and all their Properties">
<link rel="prev" href="libgimp-gimpguides.html" title="gimpguides">
<link rel="next" href="libgimp-gimplayer.html" title="gimplayer">
<meta name="generator" content="GTK-Doc V1.4 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
<link rel="part" href="gimpdefinitions.html" title="Part&#160;I.&#160;GIMP Constants">
<link rel="part" href="libgimp.html" title="Part&#160;II.&#160;GIMP Library">
<link rel="chapter" href="libgimp-general.html" title="Functions not Related to Specific Images">
<link rel="chapter" href="libgimp-image.html" title="Manupulating Images and all their Properties">
<link rel="chapter" href="libgimp-data.html" title="Data Objects">
<link rel="chapter" href="libgimp-selectors.html" title="Controlling the Core's Selection Dialogs">
<link rel="part" href="libgimpui.html" title="Part&#160;III.&#160;GIMP User Interface Library">
<link rel="chapter" href="libgimpui-hierarchy.html" title="Object Hierarchy">
<link rel="index" href="ix01.html" title="Index">
<link rel="index" href="ix02.html" title="Index of new symbols in GIMP 2.2">
<link rel="index" href="ix03.html" title="Index of new symbols in GIMP 2.4">
<link rel="index" href="ix04.html" title="Index of deprecated symbols">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" width="100%" summary="Navigation header" cellpadding="2" cellspacing="2"><tr valign="middle">
<td><a accesskey="p" href="libgimp-gimpguides.html"><img src="left.png" width="24" height="24" border="0" alt="Prev"></a></td>
<td><a accesskey="u" href="libgimp-image.html"><img src="up.png" width="24" height="24" border="0" alt="Up"></a></td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="24" height="24" border="0" alt="Home"></a></td>
<th width="100%" align="center">GIMP Library Reference Manual</th>
<td><a accesskey="n" href="libgimp-gimplayer.html"><img src="right.png" width="24" height="24" border="0" alt="Next"></a></td>
</tr></table>
<div class="refentry" lang="en">
<a name="libgimp-gimpimage"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle">gimpimage</span></h2>
<p>gimpimage &#8212; Operations on complete images.</p>
</td>
<td valign="top" align="right"></td>
</tr></table></div>
<div class="refsynopsisdiv">
<h2>Synopsis</h2>
<pre class="synopsis">
gint* <a href="libgimp-gimpimage.html#gimp-image-list">gimp_image_list</a> (gint *num_images);
gint32 <a href="libgimp-gimpimage.html#gimp-image-new">gimp_image_new</a> (gint width,
gint height,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpImageBaseType"
>GimpImageBaseType</a> type);
gint32 <a href="libgimp-gimpimage.html#gimp-image-duplicate">gimp_image_duplicate</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-delete">gimp_image_delete</a> (gint32 image_ID);
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpImageBaseType"
>GimpImageBaseType</a> <a href="libgimp-gimpimage.html#gimp-image-base-type">gimp_image_base_type</a> (gint32 image_ID);
gint <a href="libgimp-gimpimage.html#gimp-image-width">gimp_image_width</a> (gint32 image_ID);
gint <a href="libgimp-gimpimage.html#gimp-image-height">gimp_image_height</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-free-shadow">gimp_image_free_shadow</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-flip">gimp_image_flip</a> (gint32 image_ID,
<a href="libgimp-gimpenums.html#GimpOrientationType">GimpOrientationType</a> flip_type);
gboolean <a href="libgimp-gimpimage.html#gimp-image-rotate">gimp_image_rotate</a> (gint32 image_ID,
<a href="libgimp-gimpenums.html#GimpRotationType">GimpRotationType</a> rotate_type);
gboolean <a href="libgimp-gimpimage.html#gimp-image-resize">gimp_image_resize</a> (gint32 image_ID,
gint new_width,
gint new_height,
gint offx,
gint offy);
gboolean <a href="libgimp-gimpimage.html#gimp-image-resize-to-layers">gimp_image_resize_to_layers</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-scale">gimp_image_scale</a> (gint32 image_ID,
gint new_width,
gint new_height);
gboolean <a href="libgimp-gimpimage.html#gimp-image-crop">gimp_image_crop</a> (gint32 image_ID,
gint new_width,
gint new_height,
gint offx,
gint offy);
gint* <a href="libgimp-gimpimage.html#gimp-image-get-layers">gimp_image_get_layers</a> (gint32 image_ID,
gint *num_layers);
gint* <a href="libgimp-gimpimage.html#gimp-image-get-channels">gimp_image_get_channels</a> (gint32 image_ID,
gint *num_channels);
gint32 <a href="libgimp-gimpimage.html#gimp-image-get-active-drawable">gimp_image_get_active_drawable</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-unset-active-channel">gimp_image_unset_active_channel</a> (gint32 image_ID);
gint32 <a href="libgimp-gimpimage.html#gimp-image-get-floating-sel">gimp_image_get_floating_sel</a> (gint32 image_ID);
gint32 <a href="libgimp-gimpimage.html#gimp-image-floating-sel-attached-to">gimp_image_floating_sel_attached_to</a>
(gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-pick-color">gimp_image_pick_color</a> (gint32 image_ID,
gint32 drawable_ID,
gdouble x,
gdouble y,
gboolean sample_merged,
gboolean sample_average,
gdouble average_radius,
<a
href="../libgimpcolor/libgimpcolor-GimpRGB.html#GimpRGB"
>GimpRGB</a> *color);
gint32 <a href="libgimp-gimpimage.html#gimp-image-pick-correlate-layer">gimp_image_pick_correlate_layer</a> (gint32 image_ID,
gint x,
gint y);
gboolean <a href="libgimp-gimpimage.html#gimp-image-add-layer">gimp_image_add_layer</a> (gint32 image_ID,
gint32 layer_ID,
gint position);
gboolean <a href="libgimp-gimpimage.html#gimp-image-remove-layer">gimp_image_remove_layer</a> (gint32 image_ID,
gint32 layer_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-raise-layer">gimp_image_raise_layer</a> (gint32 image_ID,
gint32 layer_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-lower-layer">gimp_image_lower_layer</a> (gint32 image_ID,
gint32 layer_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-raise-layer-to-top">gimp_image_raise_layer_to_top</a> (gint32 image_ID,
gint32 layer_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-lower-layer-to-bottom">gimp_image_lower_layer_to_bottom</a>
(gint32 image_ID,
gint32 layer_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-add-channel">gimp_image_add_channel</a> (gint32 image_ID,
gint32 channel_ID,
gint position);
gboolean <a href="libgimp-gimpimage.html#gimp-image-remove-channel">gimp_image_remove_channel</a> (gint32 image_ID,
gint32 channel_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-raise-channel">gimp_image_raise_channel</a> (gint32 image_ID,
gint32 channel_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-lower-channel">gimp_image_lower_channel</a> (gint32 image_ID,
gint32 layer_ID);
gint32 <a href="libgimp-gimpimage.html#gimp-image-flatten">gimp_image_flatten</a> (gint32 image_ID);
gint32 <a href="libgimp-gimpimage.html#gimp-image-merge-visible-layers">gimp_image_merge_visible_layers</a> (gint32 image_ID,
<a href="libgimp-gimpenums.html#GimpMergeType">GimpMergeType</a> merge_type);
gint32 <a href="libgimp-gimpimage.html#gimp-image-merge-down">gimp_image_merge_down</a> (gint32 image_ID,
gint32 merge_layer_ID,
<a href="libgimp-gimpenums.html#GimpMergeType">GimpMergeType</a> merge_type);
gboolean <a href="libgimp-gimpimage.html#gimp-image-clean-all">gimp_image_clean_all</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-is-dirty">gimp_image_is_dirty</a> (gint32 image_ID);
gint32 <a href="libgimp-gimpimage.html#gimp-image-get-active-layer">gimp_image_get_active_layer</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-active-layer">gimp_image_set_active_layer</a> (gint32 image_ID,
gint32 active_layer_ID);
gint32 <a href="libgimp-gimpimage.html#gimp-image-get-active-channel">gimp_image_get_active_channel</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-active-channel">gimp_image_set_active_channel</a> (gint32 image_ID,
gint32 active_channel_ID);
gint32 <a href="libgimp-gimpimage.html#gimp-image-get-selection">gimp_image_get_selection</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-get-component-active">gimp_image_get_component_active</a> (gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpChannelType"
>GimpChannelType</a> component);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-component-active">gimp_image_set_component_active</a> (gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpChannelType"
>GimpChannelType</a> component,
gboolean active);
gboolean <a href="libgimp-gimpimage.html#gimp-image-get-component-visible">gimp_image_get_component_visible</a>
(gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpChannelType"
>GimpChannelType</a> component);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-component-visible">gimp_image_set_component_visible</a>
(gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpChannelType"
>GimpChannelType</a> component,
gboolean visible);
gchar* <a href="libgimp-gimpimage.html#gimp-image-get-filename">gimp_image_get_filename</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-filename">gimp_image_set_filename</a> (gint32 image_ID,
const gchar *filename);
gchar* <a href="libgimp-gimpimage.html#gimp-image-get-name">gimp_image_get_name</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-get-resolution">gimp_image_get_resolution</a> (gint32 image_ID,
gdouble *xresolution,
gdouble *yresolution);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-resolution">gimp_image_set_resolution</a> (gint32 image_ID,
gdouble xresolution,
gdouble yresolution);
<a
href="../libgimpbase/libgimpbase-gimpunit.html#GimpUnit"
>GimpUnit</a> <a href="libgimp-gimpimage.html#gimp-image-get-unit">gimp_image_get_unit</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-unit">gimp_image_set_unit</a> (gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpunit.html#GimpUnit"
>GimpUnit</a> unit);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-tattoo-state">gimp_image_set_tattoo_state</a> (gint32 image_ID,
gint tattoo_state);
gint <a href="libgimp-gimpimage.html#gimp-image-get-tattoo-state">gimp_image_get_tattoo_state</a> (gint32 image_ID);
gint32 <a href="libgimp-gimpimage.html#gimp-image-get-layer-by-tattoo">gimp_image_get_layer_by_tattoo</a> (gint32 image_ID,
gint tattoo);
gint32 <a href="libgimp-gimpimage.html#gimp-image-get-channel-by-tattoo">gimp_image_get_channel_by_tattoo</a>
(gint32 image_ID,
gint tattoo);
guchar* <a href="libgimp-gimpimage.html#gimp-image-get-cmap">gimp_image_get_cmap</a> (gint32 image_ID,
gint *num_colors);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-cmap">gimp_image_set_cmap</a> (gint32 image_ID,
const guchar *cmap,
gint num_colors);
guchar* <a href="libgimp-gimpimage.html#gimp-image-get-colormap">gimp_image_get_colormap</a> (gint32 image_ID,
gint *num_colors);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-colormap">gimp_image_set_colormap</a> (gint32 image_ID,
const guchar *colormap,
gint num_colors);
gint* <a href="libgimp-gimpimage.html#gimp-image-get-vectors">gimp_image_get_vectors</a> (gint32 image_ID,
gint *num_vectors);
guchar* <a href="libgimp-gimpimage.html#gimp-image-get-thumbnail-data">gimp_image_get_thumbnail_data</a> (gint32 image_ID,
gint *width,
gint *height,
gint *bpp);
<a
href="../libgimpbase/libgimpbase-gimpparasite.html#GimpParasite"
>GimpParasite</a>* <a href="libgimp-gimpimage.html#gimp-image-parasite-find">gimp_image_parasite_find</a> (gint32 image_ID,
const gchar *name);
gboolean <a href="libgimp-gimpimage.html#gimp-image-parasite-list">gimp_image_parasite_list</a> (gint32 image_ID,
gint *num_parasites,
gchar ***parasites);
gboolean <a href="libgimp-gimpimage.html#gimp-image-parasite-attach">gimp_image_parasite_attach</a> (gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpparasite.html#GimpParasite"
>GimpParasite</a> *parasite);
gboolean <a href="libgimp-gimpimage.html#gimp-image-parasite-detach">gimp_image_parasite_detach</a> (gint32 image_ID,
const gchar *name);
gboolean <a href="libgimp-gimpimage.html#gimp-image-attach-new-parasite">gimp_image_attach_new_parasite</a> (gint32 image_ID,
const gchar *name,
gint flags,
gint size,
gconstpointer data);
gboolean <a href="libgimp-gimpimage.html#gimp-image-add-vectors">gimp_image_add_vectors</a> (gint32 image_ID,
gint32 vectors_ID,
gint position);
gboolean <a href="libgimp-gimpimage.html#gimp-image-remove-vectors">gimp_image_remove_vectors</a> (gint32 image_ID,
gint32 vectors_ID);
gint32 <a href="libgimp-gimpimage.html#gimp-image-get-active-vectors">gimp_image_get_active_vectors</a> (gint32 image_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-set-active-vectors">gimp_image_set_active_vectors</a> (gint32 image_ID,
gint32 active_vectors_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-lower-vectors">gimp_image_lower_vectors</a> (gint32 image_ID,
gint32 vectors_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-raise-vectors">gimp_image_raise_vectors</a> (gint32 image_ID,
gint32 vectors_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-lower-vectors-to-bottom">gimp_image_lower_vectors_to_bottom</a>
(gint32 image_ID,
gint32 vectors_ID);
gboolean <a href="libgimp-gimpimage.html#gimp-image-raise-vectors-to-top">gimp_image_raise_vectors_to_top</a> (gint32 image_ID,
gint32 vectors_ID);
</pre>
</div>
<div class="refsect1" lang="en">
<a name="id2607552"></a><h2>Description</h2>
<p>
Operations on complete images: creation, resizing/rescaling,
and operations involving multiple layers.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2607564"></a><h2>Details</h2>
<div class="refsect2" lang="en">
<a name="id2607569"></a><h3>
<a name="gimp-image-list"></a>gimp_image_list ()</h3>
<a class="indexterm" name="id2607577"></a><pre class="programlisting">gint* gimp_image_list (gint *num_images);</pre>
<p>
Returns the list of images currently open.
</p>
<p>
This procedure returns the list of images currently open in the
GIMP.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>num_images</code></em>&#160;:</span></td>
<td> The number of images currently open.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The list of images currently open.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2607638"></a><h3>
<a name="gimp-image-new"></a>gimp_image_new ()</h3>
<a class="indexterm" name="id2607646"></a><pre class="programlisting">gint32 gimp_image_new (gint width,
gint height,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpImageBaseType"
>GimpImageBaseType</a> type);</pre>
<p>
Creates a new image with the specified width, height, and type.
</p>
<p>
Creates a new image, undisplayed with the specified extents and
type. A layer should be created and added before this image is
displayed, or subsequent calls to 'gimp_display_new' with this image
as an argument will fail. Layers can be created using the
'gimp_layer_new' commands. They can be added to an image using the
'gimp_image_add_layer' command.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>width</code></em>&#160;:</span></td>
<td> The width of the image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>height</code></em>&#160;:</span></td>
<td> The height of the image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>type</code></em>&#160;:</span></td>
<td> The type of image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The ID of the newly created image.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2607748"></a><h3>
<a name="gimp-image-duplicate"></a>gimp_image_duplicate ()</h3>
<a class="indexterm" name="id2607757"></a><pre class="programlisting">gint32 gimp_image_duplicate (gint32 image_ID);</pre>
<p>
Duplicate the specified image
</p>
<p>
This procedure duplicates the specified image, copying all layers,
channels, and image information.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The new, duplicated image.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2607817"></a><h3>
<a name="gimp-image-delete"></a>gimp_image_delete ()</h3>
<a class="indexterm" name="id2607825"></a><pre class="programlisting">gboolean gimp_image_delete (gint32 image_ID);</pre>
<p>
Delete the specified image.
</p>
<p>
If there are no displays associated with this image it will be
deleted. This means that you can not delete an image through the PDB
that was created by the user. If the associated display was however
created through the PDB and you know the display ID, you may delete
the display. Removal of the last associated display will then delete
the image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2607888"></a><h3>
<a name="gimp-image-base-type"></a>gimp_image_base_type ()</h3>
<a class="indexterm" name="id2607897"></a><pre class="programlisting"><a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpImageBaseType"
>GimpImageBaseType</a> gimp_image_base_type (gint32 image_ID);</pre>
<p>
Get the base type of the image.
</p>
<p>
This procedure returns the image's base type. Layers in the image
must be of this subtype, but can have an optional alpha channel.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The image's base type.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2607956"></a><h3>
<a name="gimp-image-width"></a>gimp_image_width ()</h3>
<a class="indexterm" name="id2607964"></a><pre class="programlisting">gint gimp_image_width (gint32 image_ID);</pre>
<p>
Return the width of the image
</p>
<p>
This procedure returns the image's width. This value is independent
of any of the layers in this image. This is the \"canvas\" width.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The image's width.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608024"></a><h3>
<a name="gimp-image-height"></a>gimp_image_height ()</h3>
<a class="indexterm" name="id2608032"></a><pre class="programlisting">gint gimp_image_height (gint32 image_ID);</pre>
<p>
Return the height of the image
</p>
<p>
This procedure returns the image's height. This value is independent
of any of the layers in this image. This is the \"canvas\" height.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The image's height.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608092"></a><h3>
<a name="gimp-image-free-shadow"></a>gimp_image_free_shadow ()</h3>
<a class="indexterm" name="id2608100"></a><pre class="programlisting">gboolean gimp_image_free_shadow (gint32 image_ID);</pre>
<p>
Free the specified image's shadow data (if it exists).
</p>
<p>
This procedure is intended as a memory saving device. If any shadow
memory has been allocated, it will be freed automatically on a call
to 'gimp_image_delete'.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608161"></a><h3>
<a name="gimp-image-flip"></a>gimp_image_flip ()</h3>
<a class="indexterm" name="id2608169"></a><pre class="programlisting">gboolean gimp_image_flip (gint32 image_ID,
<a href="libgimp-gimpenums.html#GimpOrientationType">GimpOrientationType</a> flip_type);</pre>
<p>
Flips the image horizontally or vertically.
</p>
<p>
This procedure flips (mirrors) the image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>flip_type</code></em>&#160;:</span></td>
<td> Type of flip.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608246"></a><h3>
<a name="gimp-image-rotate"></a>gimp_image_rotate ()</h3>
<a class="indexterm" name="id2608255"></a><pre class="programlisting">gboolean gimp_image_rotate (gint32 image_ID,
<a href="libgimp-gimpenums.html#GimpRotationType">GimpRotationType</a> rotate_type);</pre>
<p>
Rotates the image by the specified degrees.
</p>
<p>
This procedure rotates the image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>rotate_type</code></em>&#160;:</span></td>
<td> Angle of rotation.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608332"></a><h3>
<a name="gimp-image-resize"></a>gimp_image_resize ()</h3>
<a class="indexterm" name="id2608340"></a><pre class="programlisting">gboolean gimp_image_resize (gint32 image_ID,
gint new_width,
gint new_height,
gint offx,
gint offy);</pre>
<p>
Resize the image to the specified extents.
</p>
<p>
This procedure resizes the image so that it's new width and height
are equal to the supplied parameters. Offsets are also provided
which describe the position of the previous image's content. No
bounds checking is currently provided, so don't supply parameters
that are out of bounds. All channels within the image are resized
according to the specified parameters; this includes the image
selection mask. All layers within the image are repositioned
according to the specified offsets.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>new_width</code></em>&#160;:</span></td>
<td> New image width.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>new_height</code></em>&#160;:</span></td>
<td> New image height.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>offx</code></em>&#160;:</span></td>
<td> x offset between upper left corner of old and new images: (new - old).
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>offy</code></em>&#160;:</span></td>
<td> y offset between upper left corner of old and new images: (new - old).
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608484"></a><h3>
<a name="gimp-image-resize-to-layers"></a>gimp_image_resize_to_layers ()</h3>
<a class="indexterm" name="id2608493"></a><pre class="programlisting">gboolean gimp_image_resize_to_layers (gint32 image_ID);</pre>
<p>
Resize the image to fit all layers.
</p>
<p>
This procedure resizes the image to the bounding box of all layers
of the image. All channels within the image are resized to the new
size; this includes the image selection mask. All layers within the
image are repositioned to the new image area.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
<p>Since GIMP 2.2
</p>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608559"></a><h3>
<a name="gimp-image-scale"></a>gimp_image_scale ()</h3>
<a class="indexterm" name="id2608568"></a><pre class="programlisting">gboolean gimp_image_scale (gint32 image_ID,
gint new_width,
gint new_height);</pre>
<p>
Scale the image to the specified extents.
</p>
<p>
This procedure scales the image so that its new width and height are
equal to the supplied parameters. Offsets are also provided which
describe the position of the previous image's content. No bounds
checking is currently provided, so don't supply parameters that are
out of bounds. All channels within the image are scaled according to
the specified parameters; this includes the image selection mask.
All layers within the image are repositioned according to the
specified offsets.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>new_width</code></em>&#160;:</span></td>
<td> New image width.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>new_height</code></em>&#160;:</span></td>
<td> New image height.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608671"></a><h3>
<a name="gimp-image-crop"></a>gimp_image_crop ()</h3>
<a class="indexterm" name="id2608679"></a><pre class="programlisting">gboolean gimp_image_crop (gint32 image_ID,
gint new_width,
gint new_height,
gint offx,
gint offy);</pre>
<p>
Crop the image to the specified extents.
</p>
<p>
This procedure crops the image so that it's new width and height are
equal to the supplied parameters. Offsets are also provided which
describe the position of the previous image's content. All channels
and layers within the image are cropped to the new image extents;
this includes the image selection mask. If any parameters are out of
range, an error is returned.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>new_width</code></em>&#160;:</span></td>
<td> New image width: (0 &lt; new_width &lt;= width).
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>new_height</code></em>&#160;:</span></td>
<td> New image height: (0 &lt; new_height &lt;= height).
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>offx</code></em>&#160;:</span></td>
<td> x offset: (0 &lt;= offx &lt;= (width - new_width)).
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>offy</code></em>&#160;:</span></td>
<td> y offset: (0 &lt;= offy &lt;= (height - new_height)).
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608822"></a><h3>
<a name="gimp-image-get-layers"></a>gimp_image_get_layers ()</h3>
<a class="indexterm" name="id2608831"></a><pre class="programlisting">gint* gimp_image_get_layers (gint32 image_ID,
gint *num_layers);</pre>
<p>
Returns the list of layers contained in the specified image.
</p>
<p>
This procedure returns the list of layers contained in the specified
image. The order of layers is from topmost to bottommost.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>num_layers</code></em>&#160;:</span></td>
<td> The number of layers contained in the image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The list of layers contained in the image.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2608912"></a><h3>
<a name="gimp-image-get-channels"></a>gimp_image_get_channels ()</h3>
<a class="indexterm" name="id2608920"></a><pre class="programlisting">gint* gimp_image_get_channels (gint32 image_ID,
gint *num_channels);</pre>
<p>
Returns the list of channels contained in the specified image.
</p>
<p>
This procedure returns the list of channels contained in the
specified image. This does not include the selection mask, or layer
masks. The order is from topmost to bottommost.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>num_channels</code></em>&#160;:</span></td>
<td> The number of channels contained in the image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The list of channels contained in the image.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609002"></a><h3>
<a name="gimp-image-get-active-drawable"></a>gimp_image_get_active_drawable ()</h3>
<a class="indexterm" name="id2609012"></a><pre class="programlisting">gint32 gimp_image_get_active_drawable (gint32 image_ID);</pre>
<p>
Get the image's active drawable
</p>
<p>
This procedure returns the ID of the image's active drawable. This
can be either a layer, a channel, or a layer mask. The active
drawable is specified by the active image channel. If that is -1,
then by the active image layer. If the active image layer has a
layer mask and the layer mask is in edit mode, then the layer mask
is the active drawable.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The active drawable.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609076"></a><h3>
<a name="gimp-image-unset-active-channel"></a>gimp_image_unset_active_channel ()</h3>
<a class="indexterm" name="id2609086"></a><pre class="programlisting">gboolean gimp_image_unset_active_channel (gint32 image_ID);</pre>
<p>
Unsets the active channel in the specified image.
</p>
<p>
If an active channel exists, it is unset. There then exists no
active channel, and if desired, one can be set through a call to
'Set Active Channel'. No error is returned in the case of no
existing active channel.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609148"></a><h3>
<a name="gimp-image-get-floating-sel"></a>gimp_image_get_floating_sel ()</h3>
<a class="indexterm" name="id2609158"></a><pre class="programlisting">gint32 gimp_image_get_floating_sel (gint32 image_ID);</pre>
<p>
Return the floating selection of the image.
</p>
<p>
This procedure returns the image's floating selection, if it exists.
If it doesn't exist, -1 is returned as the layer ID.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The image's floating selection.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609225"></a><h3>
<a name="gimp-image-floating-sel-attached-to"></a>gimp_image_floating_sel_attached_to ()</h3>
<a class="indexterm" name="id2609237"></a><pre class="programlisting">gint32 gimp_image_floating_sel_attached_to
(gint32 image_ID);</pre>
<p>
Return the drawable the floating selection is attached to.
</p>
<p>
This procedure returns the drawable the image's floating selection
is attached to, if it exists. If it doesn't exist, -1 is returned as
the drawable ID.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The drawable the floating selection is attached to.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609306"></a><h3>
<a name="gimp-image-pick-color"></a>gimp_image_pick_color ()</h3>
<a class="indexterm" name="id2609317"></a><pre class="programlisting">gboolean gimp_image_pick_color (gint32 image_ID,
gint32 drawable_ID,
gdouble x,
gdouble y,
gboolean sample_merged,
gboolean sample_average,
gdouble average_radius,
<a
href="../libgimpcolor/libgimpcolor-GimpRGB.html#GimpRGB"
>GimpRGB</a> *color);</pre>
<p>
Determine the color at the given drawable coordinates
</p>
<p>
This tool determines the color at the specified coordinates. The
returned color is an RGB triplet even for grayscale and indexed
drawables. If the coordinates lie outside of the extents of the
specified drawable, then an error is returned. If the drawable has
an alpha channel, the algorithm examines the alpha value of the
drawable at the coordinates. If the alpha value is completely
transparent (0), then an error is returned. If the sample_merged
parameter is non-zero, the data of the composite image will be used
instead of that for the specified drawable. This is equivalent to
sampling for colors after merging all visible layers. In the case of
a merged sampling, the supplied drawable is ignored except for
finding the image it belongs to.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>drawable_ID</code></em>&#160;:</span></td>
<td> The drawable to pick from.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>x</code></em>&#160;:</span></td>
<td> x coordinate of upper-left corner of rectangle.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>y</code></em>&#160;:</span></td>
<td> y coordinate of upper-left corner of rectangle.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>sample_merged</code></em>&#160;:</span></td>
<td> Use the composite image, not the drawable.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>sample_average</code></em>&#160;:</span></td>
<td> Average the color of all the pixels in a specified radius.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>average_radius</code></em>&#160;:</span></td>
<td> The radius of pixels to average.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>color</code></em>&#160;:</span></td>
<td> The return color.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609547"></a><h3>
<a name="gimp-image-pick-correlate-layer"></a>gimp_image_pick_correlate_layer ()</h3>
<a class="indexterm" name="id2609558"></a><pre class="programlisting">gint32 gimp_image_pick_correlate_layer (gint32 image_ID,
gint x,
gint y);</pre>
<p>
Find the layer visible at the specified coordinates.
</p>
<p>
This procedure finds the layer which is visible at the specified
coordinates. Layers which do not qualify are those whose extents do
not pass within the specified coordinates, or which are transparent
at the specified coordinates. This procedure will return -1 if no
layer is found.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>x</code></em>&#160;:</span></td>
<td> The x coordinate for the pick.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>y</code></em>&#160;:</span></td>
<td> The y coordinate for the pick.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The layer found at the specified coordinates.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609671"></a><h3>
<a name="gimp-image-add-layer"></a>gimp_image_add_layer ()</h3>
<a class="indexterm" name="id2609683"></a><pre class="programlisting">gboolean gimp_image_add_layer (gint32 image_ID,
gint32 layer_ID,
gint position);</pre>
<p>
Add the specified layer to the image.
</p>
<p>
This procedure adds the specified layer to the gimage at the given
position. If the position is specified as -1, then the layer is
inserted at the top of the layer stack. If the layer to be added has
no alpha channel, it must be added at position 0. The layer type
must be compatible with the image base type.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>layer_ID</code></em>&#160;:</span></td>
<td> The layer.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>position</code></em>&#160;:</span></td>
<td> The layer position.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609796"></a><h3>
<a name="gimp-image-remove-layer"></a>gimp_image_remove_layer ()</h3>
<a class="indexterm" name="id2609807"></a><pre class="programlisting">gboolean gimp_image_remove_layer (gint32 image_ID,
gint32 layer_ID);</pre>
<p>
Remove the specified layer from the image.
</p>
<p>
This procedure removes the specified layer from the image. If the
layer doesn't exist, an error is returned. If there are no layers
left in the image, this call will fail. If this layer is the last
layer remaining, the image will become empty and have no active
layer.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>layer_ID</code></em>&#160;:</span></td>
<td> The layer.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609898"></a><h3>
<a name="gimp-image-raise-layer"></a>gimp_image_raise_layer ()</h3>
<a class="indexterm" name="id2609909"></a><pre class="programlisting">gboolean gimp_image_raise_layer (gint32 image_ID,
gint32 layer_ID);</pre>
<p>
Raise the specified layer in the image's layer stack
</p>
<p>
This procedure raises the specified layer one step in the existing
layer stack. It will not move the layer if there is no layer above
it, or the layer has no alpha channel.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>layer_ID</code></em>&#160;:</span></td>
<td> The layer to raise.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2609999"></a><h3>
<a name="gimp-image-lower-layer"></a>gimp_image_lower_layer ()</h3>
<a class="indexterm" name="id2610010"></a><pre class="programlisting">gboolean gimp_image_lower_layer (gint32 image_ID,
gint32 layer_ID);</pre>
<p>
Lower the specified layer in the image's layer stack
</p>
<p>
This procedure lowers the specified layer one step in the existing
layer stack. It will not move the layer if there is no layer below
it, or the layer has no alpha channel.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>layer_ID</code></em>&#160;:</span></td>
<td> The layer to lower.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2610100"></a><h3>
<a name="gimp-image-raise-layer-to-top"></a>gimp_image_raise_layer_to_top ()</h3>
<a class="indexterm" name="id2610112"></a><pre class="programlisting">gboolean gimp_image_raise_layer_to_top (gint32 image_ID,
gint32 layer_ID);</pre>
<p>
Raise the specified layer in the image's layer stack to top of stack
</p>
<p>
This procedure raises the specified layer to top of the existing
layer stack. It will not move the layer if there is no layer above
it, or the layer has no alpha channel.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>layer_ID</code></em>&#160;:</span></td>
<td> The layer to raise to top.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2610201"></a><h3>
<a name="gimp-image-lower-layer-to-bottom"></a>gimp_image_lower_layer_to_bottom ()</h3>
<a class="indexterm" name="id2610213"></a><pre class="programlisting">gboolean gimp_image_lower_layer_to_bottom
(gint32 image_ID,
gint32 layer_ID);</pre>
<p>
Lower the specified layer in the image's layer stack to bottom of
stack
</p>
<p>
This procedure lowers the specified layer to bottom of the existing
layer stack. It will not move the layer if there is no layer below
it, or the layer has no alpha channel.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>layer_ID</code></em>&#160;:</span></td>
<td> The layer to lower to bottom.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2610304"></a><h3>
<a name="gimp-image-add-channel"></a>gimp_image_add_channel ()</h3>
<a class="indexterm" name="id2610316"></a><pre class="programlisting">gboolean gimp_image_add_channel (gint32 image_ID,
gint32 channel_ID,
gint position);</pre>
<p>
Add the specified channel to the image.
</p>
<p>
This procedure adds the specified channel to the image. The position
channel is not currently used, so the channel is always inserted at
the top of the channel stack.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>channel_ID</code></em>&#160;:</span></td>
<td> The channel.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>position</code></em>&#160;:</span></td>
<td> The channel position.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2610426"></a><h3>
<a name="gimp-image-remove-channel"></a>gimp_image_remove_channel ()</h3>
<a class="indexterm" name="id2610438"></a><pre class="programlisting">gboolean gimp_image_remove_channel (gint32 image_ID,
gint32 channel_ID);</pre>
<p>
Remove the specified channel from the image.
</p>
<p>
This procedure removes the specified channel from the image. If the
channel doesn't exist, an error is returned.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>channel_ID</code></em>&#160;:</span></td>
<td> The channel.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2610526"></a><h3>
<a name="gimp-image-raise-channel"></a>gimp_image_raise_channel ()</h3>
<a class="indexterm" name="id2610537"></a><pre class="programlisting">gboolean gimp_image_raise_channel (gint32 image_ID,
gint32 channel_ID);</pre>
<p>
Raise the specified channel in the image's channel stack
</p>
<p>
This procedure raises the specified channel one step in the existing
channel stack. It will not move the channel if there is no channel
above it.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>channel_ID</code></em>&#160;:</span></td>
<td> The channel to raise.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2610626"></a><h3>
<a name="gimp-image-lower-channel"></a>gimp_image_lower_channel ()</h3>
<a class="indexterm" name="id2610638"></a><pre class="programlisting">gboolean gimp_image_lower_channel (gint32 image_ID,
gint32 layer_ID);</pre>
<p>
Lower the specified layer in the image's layer stack
</p>
<p>
This procedure lowers the specified layer one step in the existing
layer stack. It will not move the layer if there is no layer below
it, or the layer has no alpha channel.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>layer_ID</code></em>&#160;:</span></td>
<td> The layer to lower.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2610727"></a><h3>
<a name="gimp-image-flatten"></a>gimp_image_flatten ()</h3>
<a class="indexterm" name="id2610739"></a><pre class="programlisting">gint32 gimp_image_flatten (gint32 image_ID);</pre>
<p>
Flatten all visible layers into a single layer. Discard all
invisible layers.
</p>
<p>
This procedure combines the visible layers in a manner analogous to
merging with the CLIP_TO_IMAGE merge type. Non-visible layers are
discarded, and the resulting image is stripped of its alpha channel.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The resulting layer.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2610807"></a><h3>
<a name="gimp-image-merge-visible-layers"></a>gimp_image_merge_visible_layers ()</h3>
<a class="indexterm" name="id2610819"></a><pre class="programlisting">gint32 gimp_image_merge_visible_layers (gint32 image_ID,
<a href="libgimp-gimpenums.html#GimpMergeType">GimpMergeType</a> merge_type);</pre>
<p>
Merge the visible image layers into one.
</p>
<p>
This procedure combines the visible layers into a single layer using
the specified merge type. A merge type of EXPAND_AS_NECESSARY
expands the final layer to encompass the areas of the visible
layers. A merge type of CLIP_TO_IMAGE clips the final layer to the
extents of the image. A merge type of CLIP_TO_BOTTOM_LAYER clips the
final layer to the size of the bottommost layer.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>merge_type</code></em>&#160;:</span></td>
<td> The type of merge.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The resulting layer.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2610912"></a><h3>
<a name="gimp-image-merge-down"></a>gimp_image_merge_down ()</h3>
<a class="indexterm" name="id2610924"></a><pre class="programlisting">gint32 gimp_image_merge_down (gint32 image_ID,
gint32 merge_layer_ID,
<a href="libgimp-gimpenums.html#GimpMergeType">GimpMergeType</a> merge_type);</pre>
<p>
Merge the layer passed and the first visible layer below.
</p>
<p>
This procedure combines the passed layer and the first visible layer
below it using the specified merge type. A merge type of
EXPAND_AS_NECESSARY expands the final layer to encompass the areas
of the visible layers. A merge type of CLIP_TO_IMAGE clips the final
layer to the extents of the image. A merge type of
CLIP_TO_BOTTOM_LAYER clips the final layer to the size of the
bottommost layer.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>merge_layer_ID</code></em>&#160;:</span></td>
<td> The layer to merge down from.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>merge_type</code></em>&#160;:</span></td>
<td> The type of merge.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The resulting layer.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611039"></a><h3>
<a name="gimp-image-clean-all"></a>gimp_image_clean_all ()</h3>
<a class="indexterm" name="id2611051"></a><pre class="programlisting">gboolean gimp_image_clean_all (gint32 image_ID);</pre>
<p>
Set the image dirty count to 0.
</p>
<p>
This procedure sets the specified image's dirty count to 0, allowing
operations to occur without having a 'dirtied' image. This is
especially useful for creating and loading images which should not
initially be considered dirty, even though layers must be created,
filled, and installed in the image. Note that save plug-ins must NOT
call this function themselves after saving the image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611122"></a><h3>
<a name="gimp-image-is-dirty"></a>gimp_image_is_dirty ()</h3>
<a class="indexterm" name="id2611133"></a><pre class="programlisting">gboolean gimp_image_is_dirty (gint32 image_ID);</pre>
<p>
Checks if the image has unsaved changes.
</p>
<p>
This procedure checks the specified image's dirty count to see if it
needs to be saved. Note that saving the image does not automatically
set the dirty count to 0, you need to call gimp-image-clean-all
after calling a save procedure to make the image clean.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> True if the image has unsaved changes.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611202"></a><h3>
<a name="gimp-image-get-active-layer"></a>gimp_image_get_active_layer ()</h3>
<a class="indexterm" name="id2611214"></a><pre class="programlisting">gint32 gimp_image_get_active_layer (gint32 image_ID);</pre>
<p>
Returns the specified image's active layer.
</p>
<p>
If there is an active layer, its ID will be returned, otherwise, -1.
If a channel is currently active, then no layer will be. If a layer
mask is active, then this will return the associated layer.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The active layer.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611282"></a><h3>
<a name="gimp-image-set-active-layer"></a>gimp_image_set_active_layer ()</h3>
<a class="indexterm" name="id2611294"></a><pre class="programlisting">gboolean gimp_image_set_active_layer (gint32 image_ID,
gint32 active_layer_ID);</pre>
<p>
Sets the specified image's active layer.
</p>
<p>
If the layer exists, it is set as the active layer in the image. Any
previous active layer or channel is set to inactive. An exception is
a previously existing floating selection, in which case this
procedure will return an execution error.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>active_layer_ID</code></em>&#160;:</span></td>
<td> The new image active layer.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611384"></a><h3>
<a name="gimp-image-get-active-channel"></a>gimp_image_get_active_channel ()</h3>
<a class="indexterm" name="id2611396"></a><pre class="programlisting">gint32 gimp_image_get_active_channel (gint32 image_ID);</pre>
<p>
Returns the specified image's active channel.
</p>
<p>
If there is an active channel, this will return the channel ID,
otherwise, -1.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The active channel.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611462"></a><h3>
<a name="gimp-image-set-active-channel"></a>gimp_image_set_active_channel ()</h3>
<a class="indexterm" name="id2611474"></a><pre class="programlisting">gboolean gimp_image_set_active_channel (gint32 image_ID,
gint32 active_channel_ID);</pre>
<p>
Sets the specified image's active channel.
</p>
<p>
If the channel exists, it is set as the active channel in the image.
Any previous active channel or channel is set to inactive. An
exception is a previously existing floating selection, in which case
this procedure will return an execution error.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>active_channel_ID</code></em>&#160;:</span></td>
<td> The new image active channel.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611565"></a><h3>
<a name="gimp-image-get-selection"></a>gimp_image_get_selection ()</h3>
<a class="indexterm" name="id2611576"></a><pre class="programlisting">gint32 gimp_image_get_selection (gint32 image_ID);</pre>
<p>
Returns the specified image's selection.
</p>
<p>
This will always return a valid ID for a selection -- which is
represented as a channel internally.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The selection channel.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611643"></a><h3>
<a name="gimp-image-get-component-active"></a>gimp_image_get_component_active ()</h3>
<a class="indexterm" name="id2611654"></a><pre class="programlisting">gboolean gimp_image_get_component_active (gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpChannelType"
>GimpChannelType</a> component);</pre>
<p>
Returns if the specified image's image component is active.
</p>
<p>
This procedure returns if the specified image's image component
(i.e. Red, Green, Blue intensity channels in an RGB image) is active
or inactive -- whether or not it can be modified. If the specified
component is not valid for the image type, an error is returned.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>component</code></em>&#160;:</span></td>
<td> The image component.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> Component is active.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611746"></a><h3>
<a name="gimp-image-set-component-active"></a>gimp_image_set_component_active ()</h3>
<a class="indexterm" name="id2611758"></a><pre class="programlisting">gboolean gimp_image_set_component_active (gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpChannelType"
>GimpChannelType</a> component,
gboolean active);</pre>
<p>
Sets if the specified image's image component is active.
</p>
<p>
This procedure sets if the specified image's image component (i.e.
Red, Green, Blue intensity channels in an RGB image) is active or
inactive -- whether or not it can be modified. If the specified
component is not valid for the image type, an error is returned.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>component</code></em>&#160;:</span></td>
<td> The image component.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>active</code></em>&#160;:</span></td>
<td> Component is active.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611870"></a><h3>
<a name="gimp-image-get-component-visible"></a>gimp_image_get_component_visible ()</h3>
<a class="indexterm" name="id2611882"></a><pre class="programlisting">gboolean gimp_image_get_component_visible
(gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpChannelType"
>GimpChannelType</a> component);</pre>
<p>
Returns if the specified image's image component is visible.
</p>
<p>
This procedure returns if the specified image's image component
(i.e. Red, Green, Blue intensity channels in an RGB image) is
visible or invisible -- whether or not it can be seen. If the
specified component is not valid for the image type, an error is
returned.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>component</code></em>&#160;:</span></td>
<td> The image component.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> Component is visible.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2611974"></a><h3>
<a name="gimp-image-set-component-visible"></a>gimp_image_set_component_visible ()</h3>
<a class="indexterm" name="id2611986"></a><pre class="programlisting">gboolean gimp_image_set_component_visible
(gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpbaseenums.html#GimpChannelType"
>GimpChannelType</a> component,
gboolean visible);</pre>
<p>
Sets if the specified image's image component is visible.
</p>
<p>
This procedure sets if the specified image's image component (i.e.
Red, Green, Blue intensity channels in an RGB image) is visible or
invisible -- whether or not it can be seen. If the specified
component is not valid for the image type, an error is returned.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>component</code></em>&#160;:</span></td>
<td> The image component.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>visible</code></em>&#160;:</span></td>
<td> Component is visible.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612100"></a><h3>
<a name="gimp-image-get-filename"></a>gimp_image_get_filename ()</h3>
<a class="indexterm" name="id2612111"></a><pre class="programlisting">gchar* gimp_image_get_filename (gint32 image_ID);</pre>
<p>
Returns the specified image's filename.
</p>
<p>
This procedure returns the specified image's filename in the
filesystem encoding. The image has a filename only if it was loaded
or has since been saved. Otherwise, this function returns <code class="literal">NULL</code>.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The filename.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612185"></a><h3>
<a name="gimp-image-set-filename"></a>gimp_image_set_filename ()</h3>
<a class="indexterm" name="id2612197"></a><pre class="programlisting">gboolean gimp_image_set_filename (gint32 image_ID,
const gchar *filename);</pre>
<p>
Sets the specified image's filename.
</p>
<p>
This procedure sets the specified image's filename. The filename
should be in the filesystem encoding.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>filename</code></em>&#160;:</span></td>
<td> The new image filename.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612285"></a><h3>
<a name="gimp-image-get-name"></a>gimp_image_get_name ()</h3>
<a class="indexterm" name="id2612297"></a><pre class="programlisting">gchar* gimp_image_get_name (gint32 image_ID);</pre>
<p>
Returns the specified image's name.
</p>
<p>
This procedure returns the specified image's name.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The name.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612362"></a><h3>
<a name="gimp-image-get-resolution"></a>gimp_image_get_resolution ()</h3>
<a class="indexterm" name="id2612374"></a><pre class="programlisting">gboolean gimp_image_get_resolution (gint32 image_ID,
gdouble *xresolution,
gdouble *yresolution);</pre>
<p>
Returns the specified image's resolution.
</p>
<p>
This procedure returns the specified image's resolution in dots per
inch. This value is independent of any of the layers in this image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>xresolution</code></em>&#160;:</span></td>
<td> The resolutionin the x-axis, in dots per inch.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>yresolution</code></em>&#160;:</span></td>
<td> The resolutionin the y-axis, in dots per inch.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612484"></a><h3>
<a name="gimp-image-set-resolution"></a>gimp_image_set_resolution ()</h3>
<a class="indexterm" name="id2612496"></a><pre class="programlisting">gboolean gimp_image_set_resolution (gint32 image_ID,
gdouble xresolution,
gdouble yresolution);</pre>
<p>
Sets the specified image's resolution.
</p>
<p>
This procedure sets the specified image's resolution in dots per
inch. This value is independent of any of the layers in this image.
No scaling or resizing is performed.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>xresolution</code></em>&#160;:</span></td>
<td> The new image resolution in the x-axis, in dots per inch.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>yresolution</code></em>&#160;:</span></td>
<td> The new image resolution in the y-axis, in dots per inch.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612607"></a><h3>
<a name="gimp-image-get-unit"></a>gimp_image_get_unit ()</h3>
<a class="indexterm" name="id2612619"></a><pre class="programlisting"><a
href="../libgimpbase/libgimpbase-gimpunit.html#GimpUnit"
>GimpUnit</a> gimp_image_get_unit (gint32 image_ID);</pre>
<p>
Returns the specified image's unit.
</p>
<p>
This procedure returns the specified image's unit. This value is
independent of any of the layers in this image. See the gimp_unit_*
procedure definitions for the valid range of unit IDs and a
description of the unit system.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The unit.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612687"></a><h3>
<a name="gimp-image-set-unit"></a>gimp_image_set_unit ()</h3>
<a class="indexterm" name="id2612699"></a><pre class="programlisting">gboolean gimp_image_set_unit (gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpunit.html#GimpUnit"
>GimpUnit</a> unit);</pre>
<p>
Sets the specified image's unit.
</p>
<p>
This procedure sets the specified image's unit. No scaling or
resizing is performed. This value is independent of any of the
layers in this image. See the gimp_unit_* procedure definitions for
the valid range of unit IDs and a description of the unit system.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>unit</code></em>&#160;:</span></td>
<td> The new image unit.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612788"></a><h3>
<a name="gimp-image-set-tattoo-state"></a>gimp_image_set_tattoo_state ()</h3>
<a class="indexterm" name="id2612800"></a><pre class="programlisting">gboolean gimp_image_set_tattoo_state (gint32 image_ID,
gint tattoo_state);</pre>
<p>
Set the tattoo state associated with the image.
</p>
<p>
This procedure sets the tattoo state of the image. Use only by
save/load plugins that wish to preserve an images tattoo state.
Using this function at other times will produce unexpected results.
A full check of uniqueness of states in layers, channels and paths
will be performed by this procedure and a execution failure will be
returned if this fails. A failure will also be returned if the new
tattoo state value is less than the maximum tattoo value from all of
the tattoos from the paths, layers and channels. After the image
data has been loaded and all the tattoos have been set then this is
the last procedure that should be called. If effectively does a
status check on the tattoo values that have been set to make sure
that all is OK.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>tattoo_state</code></em>&#160;:</span></td>
<td> The new image tattoo_state.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612899"></a><h3>
<a name="gimp-image-get-tattoo-state"></a>gimp_image_get_tattoo_state ()</h3>
<a class="indexterm" name="id2612911"></a><pre class="programlisting">gint gimp_image_get_tattoo_state (gint32 image_ID);</pre>
<p>
Returns the tattoo state associated with the image.
</p>
<p>
This procedure returns the tattoo state of the image. Use only by
save/load plugins that wish to preserve an images tattoo state.
Using this function at other times will produce unexpected results.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The tattoo_state.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2612979"></a><h3>
<a name="gimp-image-get-layer-by-tattoo"></a>gimp_image_get_layer_by_tattoo ()</h3>
<a class="indexterm" name="id2612990"></a><pre class="programlisting">gint32 gimp_image_get_layer_by_tattoo (gint32 image_ID,
gint tattoo);</pre>
<p>
Find a layer with a given tattoo in an image.
</p>
<p>
This procedure returns the layer with the given tattoo in the
specified image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>tattoo</code></em>&#160;:</span></td>
<td> The tattoo of the layer to find.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The layer with the specified tattoo.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2613078"></a><h3>
<a name="gimp-image-get-channel-by-tattoo"></a>gimp_image_get_channel_by_tattoo ()</h3>
<a class="indexterm" name="id2613090"></a><pre class="programlisting">gint32 gimp_image_get_channel_by_tattoo
(gint32 image_ID,
gint tattoo);</pre>
<p>
Find a channel with a given tattoo in an image.
</p>
<p>
This procedure returns the channel with the given tattoo in the
specified image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>tattoo</code></em>&#160;:</span></td>
<td> The tattoo of the channel to find.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The channel with the specified tattoo.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2613180"></a><h3>
<a name="gimp-image-get-cmap"></a>gimp_image_get_cmap ()</h3>
<a class="indexterm" name="id2613191"></a><pre class="programlisting">guchar* gimp_image_get_cmap (gint32 image_ID,
gint *num_colors);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gimp_image_get_cmap</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This procedure is deprecated! Use <a href="libgimp-gimpimage.html#gimp-image-get-colormap"><code class="function">gimp_image_get_colormap()</code></a> instead.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>num_colors</code></em>&#160;:</span></td>
<td> Number of colors in the colormap array.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The image's colormap.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2613296"></a><h3>
<a name="gimp-image-set-cmap"></a>gimp_image_set_cmap ()</h3>
<a class="indexterm" name="id2613308"></a><pre class="programlisting">gboolean gimp_image_set_cmap (gint32 image_ID,
const guchar *cmap,
gint num_colors);</pre>
<div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;">
<h3 class="title">Warning</h3>
<p><code class="literal">gimp_image_set_cmap</code> is deprecated and should not be used in newly-written code.</p>
</div>
<p>
This procedure is deprecated! Use <a href="libgimp-gimpimage.html#gimp-image-set-colormap"><code class="function">gimp_image_set_colormap()</code></a> instead.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>cmap</code></em>&#160;:</span></td>
<td> The new colormap values.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>num_colors</code></em>&#160;:</span></td>
<td> Number of colors in the colormap array.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2613435"></a><h3>
<a name="gimp-image-get-colormap"></a>gimp_image_get_colormap ()</h3>
<a class="indexterm" name="id2613446"></a><pre class="programlisting">guchar* gimp_image_get_colormap (gint32 image_ID,
gint *num_colors);</pre>
<p>
Returns the image's colormap
</p>
<p>
This procedure returns an actual pointer to the image's colormap, as
well as the number of colors contained in the colormap. If the image
is not of base type INDEXED, this pointer will be NULL.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>num_colors</code></em>&#160;:</span></td>
<td> Number of colors in the colormap array.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The image's colormap.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2613536"></a><h3>
<a name="gimp-image-set-colormap"></a>gimp_image_set_colormap ()</h3>
<a class="indexterm" name="id2613547"></a><pre class="programlisting">gboolean gimp_image_set_colormap (gint32 image_ID,
const guchar *colormap,
gint num_colors);</pre>
<p>
Sets the entries in the image's colormap.
</p>
<p>
This procedure sets the entries in the specified image's colormap.
The number of colors is specified by the \"num_colors\" parameter
and corresponds to the number of INT8 triples that must be contained
in the \"cmap\" array.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>colormap</code></em>&#160;:</span></td>
<td> The new colormap values.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>num_colors</code></em>&#160;:</span></td>
<td> Number of colors in the colormap array.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2613659"></a><h3>
<a name="gimp-image-get-vectors"></a>gimp_image_get_vectors ()</h3>
<a class="indexterm" name="id2613671"></a><pre class="programlisting">gint* gimp_image_get_vectors (gint32 image_ID,
gint *num_vectors);</pre>
<p>
Returns the list of vectors contained in the specified image.
</p>
<p>
This procedure returns the list of vectors contained in the
specified image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>num_vectors</code></em>&#160;:</span></td>
<td> The number of vectors contained in the image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The list of vectors contained in the image.
</td>
</tr>
</tbody>
</table></div>
<p>Since GIMP 2.4
</p>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2613764"></a><h3>
<a name="gimp-image-get-thumbnail-data"></a>gimp_image_get_thumbnail_data ()</h3>
<a class="indexterm" name="id2613776"></a><pre class="programlisting">guchar* gimp_image_get_thumbnail_data (gint32 image_ID,
gint *width,
gint *height,
gint *bpp);</pre>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>width</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>height</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>bpp</code></em>&#160;:</span></td>
<td>
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2613896"></a><h3>
<a name="gimp-image-parasite-find"></a>gimp_image_parasite_find ()</h3>
<a class="indexterm" name="id2613908"></a><pre class="programlisting"><a
href="../libgimpbase/libgimpbase-gimpparasite.html#GimpParasite"
>GimpParasite</a>* gimp_image_parasite_find (gint32 image_ID,
const gchar *name);</pre>
<p>
Finds the named parasite in an image
</p>
<p>
Finds and returns the named parasite that was previously attached to
an image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>name</code></em>&#160;:</span></td>
<td> The name of the parasite to find.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The found parasite.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2613996"></a><h3>
<a name="gimp-image-parasite-list"></a>gimp_image_parasite_list ()</h3>
<a class="indexterm" name="id2614008"></a><pre class="programlisting">gboolean gimp_image_parasite_list (gint32 image_ID,
gint *num_parasites,
gchar ***parasites);</pre>
<p>
List all parasites.
</p>
<p>
Returns a list of all currently attached parasites.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>num_parasites</code></em>&#160;:</span></td>
<td> The number of attached parasites.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>parasites</code></em>&#160;:</span></td>
<td> The names of currently attached parasites.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2614117"></a><h3>
<a name="gimp-image-parasite-attach"></a>gimp_image_parasite_attach ()</h3>
<a class="indexterm" name="id2614129"></a><pre class="programlisting">gboolean gimp_image_parasite_attach (gint32 image_ID,
<a
href="../libgimpbase/libgimpbase-gimpparasite.html#GimpParasite"
>GimpParasite</a> *parasite);</pre>
<p>
Add a parasite to an image.
</p>
<p>
This procedure attaches a parasite to an image. It has no return
values.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>parasite</code></em>&#160;:</span></td>
<td> The parasite to attach to an image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2614216"></a><h3>
<a name="gimp-image-parasite-detach"></a>gimp_image_parasite_detach ()</h3>
<a class="indexterm" name="id2614228"></a><pre class="programlisting">gboolean gimp_image_parasite_detach (gint32 image_ID,
const gchar *name);</pre>
<p>
Removes a parasite from an image.
</p>
<p>
This procedure detaches a parasite from an image. It has no return
values.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>name</code></em>&#160;:</span></td>
<td> The name of the parasite to detach from an image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2614316"></a><h3>
<a name="gimp-image-attach-new-parasite"></a>gimp_image_attach_new_parasite ()</h3>
<a class="indexterm" name="id2614328"></a><pre class="programlisting">gboolean gimp_image_attach_new_parasite (gint32 image_ID,
const gchar *name,
gint flags,
gint size,
gconstpointer data);</pre>
<p>
Convenience function that creates a parasite and attaches it
to the GIMP.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> the ID of the image to attach the <a
href="../libgimpbase/libgimpbase-gimpparasite.html#GimpParasite"
><span class="type">GimpParasite</span></a> to.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>name</code></em>&#160;:</span></td>
<td> the name of the <a
href="../libgimpbase/libgimpbase-gimpparasite.html#GimpParasite"
><span class="type">GimpParasite</span></a> to create and attach.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>flags</code></em>&#160;:</span></td>
<td> the flags set on the <a
href="../libgimpbase/libgimpbase-gimpparasite.html#GimpParasite"
><span class="type">GimpParasite</span></a>.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>size</code></em>&#160;:</span></td>
<td> the size of the parasite data in bytes.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>data</code></em>&#160;:</span></td>
<td> a pointer to the data attached with the <a
href="../libgimpbase/libgimpbase-gimpparasite.html#GimpParasite"
><span class="type">GimpParasite</span></a>.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on successful creation and attachment of
the new parasite.
See Also: <a href="libgimp-gimpimage.html#gimp-image-parasite-attach"><code class="function">gimp_image_parasite_attach()</code></a>
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2614517"></a><h3>
<a name="gimp-image-add-vectors"></a>gimp_image_add_vectors ()</h3>
<a class="indexterm" name="id2614528"></a><pre class="programlisting">gboolean gimp_image_add_vectors (gint32 image_ID,
gint32 vectors_ID,
gint position);</pre>
<p>
Add the specified vectors object to the image.
</p>
<p>
This procedure adds the specified vectors object to the gimage at
the given position. If the position is specified as -1, then the
vectors object is inserted at the top of the vectors stack.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>vectors_ID</code></em>&#160;:</span></td>
<td> The vectors object.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>position</code></em>&#160;:</span></td>
<td> The vectors objects position.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2614639"></a><h3>
<a name="gimp-image-remove-vectors"></a>gimp_image_remove_vectors ()</h3>
<a class="indexterm" name="id2614651"></a><pre class="programlisting">gboolean gimp_image_remove_vectors (gint32 image_ID,
gint32 vectors_ID);</pre>
<p>
Remove the specified path from the image.
</p>
<p>
This procedure removes the specified path from the image. If the
path doesn't exist, an error is returned.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>vectors_ID</code></em>&#160;:</span></td>
<td> The vectors object.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
<p>Since GIMP 2.4
</p>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2614743"></a><h3>
<a name="gimp-image-get-active-vectors"></a>gimp_image_get_active_vectors ()</h3>
<a class="indexterm" name="id2614755"></a><pre class="programlisting">gint32 gimp_image_get_active_vectors (gint32 image_ID);</pre>
<p>
Returns the specified image's active vectors.
</p>
<p>
If there is an active path, its ID will be returned, otherwise, -1.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> The active vectors.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2614822"></a><h3>
<a name="gimp-image-set-active-vectors"></a>gimp_image_set_active_vectors ()</h3>
<a class="indexterm" name="id2614834"></a><pre class="programlisting">gboolean gimp_image_set_active_vectors (gint32 image_ID,
gint32 active_vectors_ID);</pre>
<p>
Sets the specified image's active vectors.
</p>
<p>
If the path exists, it is set as the active path in the image.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>active_vectors_ID</code></em>&#160;:</span></td>
<td> The new image active vectors.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2614922"></a><h3>
<a name="gimp-image-lower-vectors"></a>gimp_image_lower_vectors ()</h3>
<a class="indexterm" name="id2614933"></a><pre class="programlisting">gboolean gimp_image_lower_vectors (gint32 image_ID,
gint32 vectors_ID);</pre>
<p>
Lower the specified vectors in the image's vectors stack
</p>
<p>
This procedure lowers the specified vectors one step in the existing
vectors stack. It will not move the vectors if there is no vectors
below it.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>vectors_ID</code></em>&#160;:</span></td>
<td> The vectors object to lower.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
<p>Since GIMP 2.4
</p>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2615027"></a><h3>
<a name="gimp-image-raise-vectors"></a>gimp_image_raise_vectors ()</h3>
<a class="indexterm" name="id2615039"></a><pre class="programlisting">gboolean gimp_image_raise_vectors (gint32 image_ID,
gint32 vectors_ID);</pre>
<p>
Raise the specified vectors in the image's vectors stack
</p>
<p>
This procedure raises the specified vectors one step in the existing
vectors stack. It will not move the vectors if there is no vectors
above it.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>vectors_ID</code></em>&#160;:</span></td>
<td> The vectors object to raise.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
<p>Since GIMP 2.4
</p>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2615132"></a><h3>
<a name="gimp-image-lower-vectors-to-bottom"></a>gimp_image_lower_vectors_to_bottom ()</h3>
<a class="indexterm" name="id2615145"></a><pre class="programlisting">gboolean gimp_image_lower_vectors_to_bottom
(gint32 image_ID,
gint32 vectors_ID);</pre>
<p>
Lower the specified vectors in the image's vectors stack to bottom
of stack
</p>
<p>
This procedure lowers the specified vectors to bottom of the
existing vectors stack. It will not move the vectors if there is no
vectors below it.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>vectors_ID</code></em>&#160;:</span></td>
<td> The vectors object to lower to bottom.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
<p>Since GIMP 2.4
</p>
</div>
<hr>
<div class="refsect2" lang="en">
<a name="id2615240"></a><h3>
<a name="gimp-image-raise-vectors-to-top"></a>gimp_image_raise_vectors_to_top ()</h3>
<a class="indexterm" name="id2615252"></a><pre class="programlisting">gboolean gimp_image_raise_vectors_to_top (gint32 image_ID,
gint32 vectors_ID);</pre>
<p>
Raise the specified vectors in the image's vectors stack to top of
stack
</p>
<p>
This procedure raises the specified vectors to top of the existing
vectors stack. It will not move the vectors if there is no vectors
above it.</p>
<p>
</p>
<div class="variablelist"><table border="0">
<col align="left" valign="top">
<tbody>
<tr>
<td>
<span class="term"><em class="parameter"><code>image_ID</code></em>&#160;:</span></td>
<td> The image.
</td>
</tr>
<tr>
<td>
<span class="term"><em class="parameter"><code>vectors_ID</code></em>&#160;:</span></td>
<td> The vectors object to raise to top.
</td>
</tr>
<tr>
<td>
<span class="term"><span class="emphasis"><em>Returns</em></span>&#160;:</span></td>
<td> TRUE on success.
</td>
</tr>
</tbody>
</table></div>
<p>Since GIMP 2.4
</p>
</div>
</div>
</div>
<table class="navigation" width="100%" summary="Navigation footer" cellpadding="2" cellspacing="0"><tr valign="middle">
<td align="left"><a accesskey="p" href="libgimp-gimpguides.html"><b>&lt;&lt;&#160;gimpguides</b></a></td>
<td align="right"><a accesskey="n" href="libgimp-gimplayer.html"><b>gimplayer&#160;&gt;&gt;</b></a></td>
</tr></table>
</body>
</html>