1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164
|
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
"http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">
<refentry id="libgimp-gimptile">
<refmeta>
<refentrytitle role="top_of_page">gimptile</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>LIBGIMP Library</refmiscinfo>
</refmeta>
<refnamediv>
<refname>gimptile</refname>
<refpurpose>Functions for working with tiles.</refpurpose>
<!--[<xref linkend="desc" endterm="desc.title"/>]-->
</refnamediv>
<refsynopsisdiv role="synopsis">
<title role="synopsis.title">Synopsis</title>
<synopsis>
<link linkend="GimpTile">GimpTile</link>;
<link linkend="void">void</link> <link linkend="gimp-tile-ref">gimp_tile_ref</link> (<link linkend="GimpTile">GimpTile</link> *tile);
<link linkend="void">void</link> <link linkend="gimp-tile-ref-zero">gimp_tile_ref_zero</link> (<link linkend="GimpTile">GimpTile</link> *tile);
<link linkend="void">void</link> <link linkend="gimp-tile-unref">gimp_tile_unref</link> (<link linkend="GimpTile">GimpTile</link> *tile,
<link linkend="gboolean">gboolean</link> dirty);
<link linkend="void">void</link> <link linkend="gimp-tile-flush">gimp_tile_flush</link> (<link linkend="GimpTile">GimpTile</link> *tile);
<link linkend="void">void</link> <link linkend="gimp-tile-cache-size">gimp_tile_cache_size</link> (<link linkend="gulong">gulong</link> kilobytes);
<link linkend="void">void</link> <link linkend="gimp-tile-cache-ntiles">gimp_tile_cache_ntiles</link> (<link linkend="gulong">gulong</link> ntiles);
</synopsis>
</refsynopsisdiv>
<refsect1 role="desc">
<title role="desc.title">Description</title>
<para>
Functions for working with tiles.
</para>
</refsect1>
<refsect1 role="details">
<title role="details.title">Details</title>
<refsect2>
<title><anchor id="GimpTile" role="struct"/>GimpTile</title>
<indexterm><primary>GimpTile</primary></indexterm><programlisting>typedef struct {
guint ewidth; /* the effective width of the tile */
guint eheight; /* the effective height of the tile */
guint bpp; /* the bytes per pixel (1, 2, 3 or 4 ) */
guint tile_num; /* the number of this tile within the drawable */
guint16 ref_count; /* reference count for the tile */
guint dirty : 1; /* is the tile dirty? has it been modified? */
guint shadow: 1; /* is this a shadow tile */
guchar *data; /* the pixel data for the tile */
GimpDrawable *drawable; /* the drawable this tile came from */
} GimpTile;
</programlisting>
<para>
</para></refsect2>
<refsect2>
<title><anchor id="gimp-tile-ref" role="function"/>gimp_tile_ref ()</title>
<indexterm><primary>gimp_tile_ref</primary></indexterm><programlisting><link linkend="void">void</link> gimp_tile_ref (<link linkend="GimpTile">GimpTile</link> *tile);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>tile</parameter> :</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gimp-tile-ref-zero" role="function"/>gimp_tile_ref_zero ()</title>
<indexterm><primary>gimp_tile_ref_zero</primary></indexterm><programlisting><link linkend="void">void</link> gimp_tile_ref_zero (<link linkend="GimpTile">GimpTile</link> *tile);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>tile</parameter> :</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gimp-tile-unref" role="function"/>gimp_tile_unref ()</title>
<indexterm><primary>gimp_tile_unref</primary></indexterm><programlisting><link linkend="void">void</link> gimp_tile_unref (<link linkend="GimpTile">GimpTile</link> *tile,
<link linkend="gboolean">gboolean</link> dirty);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>tile</parameter> :</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>dirty</parameter> :</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gimp-tile-flush" role="function"/>gimp_tile_flush ()</title>
<indexterm><primary>gimp_tile_flush</primary></indexterm><programlisting><link linkend="void">void</link> gimp_tile_flush (<link linkend="GimpTile">GimpTile</link> *tile);</programlisting>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>tile</parameter> :</term>
<listitem><simpara>
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gimp-tile-cache-size" role="function"/>gimp_tile_cache_size ()</title>
<indexterm><primary>gimp_tile_cache_size</primary></indexterm><programlisting><link linkend="void">void</link> gimp_tile_cache_size (<link linkend="gulong">gulong</link> kilobytes);</programlisting>
<para>
Sets the size of the tile cache on the plug-in side. The tile cache
is used to reduce the number of tiles exchanged between the GIMP core
and the plug-in. See also <link linkend="gimp-tile-cache-ntiles"><function>gimp_tile_cache_ntiles()</function></link>.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>kilobytes</parameter> :</term>
<listitem><simpara> new cache size in kilobytes
</simpara></listitem></varlistentry>
</variablelist></refsect2>
<refsect2>
<title><anchor id="gimp-tile-cache-ntiles" role="function"/>gimp_tile_cache_ntiles ()</title>
<indexterm><primary>gimp_tile_cache_ntiles</primary></indexterm><programlisting><link linkend="void">void</link> gimp_tile_cache_ntiles (<link linkend="gulong">gulong</link> ntiles);</programlisting>
<para>
Sets the size of the tile cache on the plug-in side. This function
is similar to <link linkend="gimp-tile-cache-size"><function>gimp_tile_cache_size()</function></link> but allows to specify the
number of tiles directly.
</para>
<para>
If your plug-in access pixels tile-by-tile, it doesn't need a tile
cache at all. If however the plug-in accesses drawable pixel data
row-by-row, it should set the tile cache large enough to hold the
number of tiles per row. Double this size if your plug-in uses
shadow tiles.</para>
<para>
</para><variablelist role="params">
<varlistentry><term><parameter>ntiles</parameter> :</term>
<listitem><simpara> number of tiles that should fit into the cache
</simpara></listitem></varlistentry>
</variablelist></refsect2>
</refsect1>
</refentry>
|