~ubuntu-branches/ubuntu/jaunty/gimp/jaunty-security

« back to all changes in this revision

Viewing changes to devel-docs/libgimpmath/xml/gimpmath.xml

  • Committer: Bazaar Package Importer
  • Author(s): Daniel Holbach
  • Date: 2007-05-02 16:33:03 UTC
  • mfrom: (1.1.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20070502163303-bvzhjzbpw8qglc4y
Tags: 2.3.16-1ubuntu1
* Resynchronized with Debian, remaining Ubuntu changes:
  - debian/rules: i18n magic.
* debian/control.in:
  - Maintainer: Ubuntu Core Developers <ubuntu-devel@lists.ubuntu.com>
* debian/patches/02_help-message.patch,
  debian/patches/03_gimp.desktop.in.in.patch,
  debian/patches/10_dont_show_wizard.patch: updated.
* debian/patches/04_composite-signedness.patch,
  debian/patches/05_add-letter-spacing.patch: dropped, used upstream.

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
 
5
5
<refentry id="libgimpmath-GimpMath">
6
6
<refmeta>
7
 
<refentrytitle>GimpMath</refentrytitle>
 
7
<refentrytitle role="top_of_page">GimpMath</refentrytitle>
8
8
<manvolnum>3</manvolnum>
9
9
<refmiscinfo>LIBGIMPMATH Library</refmiscinfo>
10
10
</refmeta>
11
11
 
12
12
<refnamediv>
13
 
<refname>GimpMath</refname><refpurpose>Mathematical definitions and macros.</refpurpose>
 
13
<refname>GimpMath</refname>
 
14
<refpurpose>Mathematical definitions and macros.</refpurpose>
 
15
<!--[<xref linkend="desc" endterm="desc.title"/>]-->
14
16
</refnamediv>
15
17
 
16
 
<refsynopsisdiv><title>Synopsis</title>
 
18
<refsynopsisdiv role="synopsis">
 
19
<title role="synopsis.title">Synopsis</title>
17
20
 
18
21
<synopsis>
19
22
 
20
23
 
21
24
 
22
 
#define     <link linkend="RINT:CAPS">RINT</link>                            (x)
23
 
#define     <link linkend="ROUND:CAPS">ROUND</link>                           (x)
24
 
#define     <link linkend="SQR:CAPS">SQR</link>                             (x)
25
 
#define     <link linkend="MAX255:CAPS">MAX255</link>                          (a)
26
 
#define     <link linkend="CLAMP0255:CAPS">CLAMP0255</link>                       (a)
27
 
#define     <link linkend="gimp-deg-to-rad">gimp_deg_to_rad</link>                 (angle)
28
 
#define     <link linkend="gimp-rad-to-deg">gimp_rad_to_deg</link>                 (angle)
 
25
#define             <link linkend="RINT:CAPS">RINT</link>                                (x)
 
26
#define             <link linkend="ROUND:CAPS">ROUND</link>                               (x)
 
27
#define             <link linkend="SQR:CAPS">SQR</link>                                 (x)
 
28
#define             <link linkend="MAX255:CAPS">MAX255</link>                              (a)
 
29
#define             <link linkend="CLAMP0255:CAPS">CLAMP0255</link>                           (a)
 
30
#define             <link linkend="gimp-deg-to-rad">gimp_deg_to_rad</link>                     (angle)
 
31
#define             <link linkend="gimp-rad-to-deg">gimp_rad_to_deg</link>                     (angle)
29
32
</synopsis>
30
33
</refsynopsisdiv>
31
34
 
37
40
 
38
41
 
39
42
 
40
 
<refsect1>
41
 
<title>Description</title>
 
43
<refsect1 role="desc">
 
44
<title role="desc.title">Description</title>
42
45
<para>
43
46
Mathematical definitions and macros. These macros should be used
44
47
rather than the ones from math.h for enhanced portability.
45
48
</para>
46
49
</refsect1>
47
50
 
48
 
<refsect1>
49
 
<title>Details</title>
 
51
<refsect1 role="details">
 
52
<title role="details.title">Details</title>
50
53
<refsect2>
51
 
<title><anchor id="RINT:CAPS"/>RINT()</title>
52
 
<indexterm><primary>RINT</primary></indexterm><programlisting>#define     RINT(x)</programlisting>
 
54
<title><anchor id="RINT:CAPS" role="macro"/>RINT()</title>
 
55
<indexterm><primary>RINT</primary></indexterm><programlisting>#define             RINT(x)</programlisting>
53
56
<para>
54
57
This macro rounds its argument <parameter>x</parameter> to an integer value in floating point
55
58
format.
61
64
</simpara></listitem></varlistentry>
62
65
</variablelist></refsect2>
63
66
<refsect2>
64
 
<title><anchor id="ROUND:CAPS"/>ROUND()</title>
 
67
<title><anchor id="ROUND:CAPS" role="macro"/>ROUND()</title>
65
68
<indexterm><primary>ROUND</primary></indexterm><programlisting>#define ROUND(x) ((int) ((x) + 0.5))
66
69
</programlisting>
67
70
<para>
74
77
</simpara></listitem></varlistentry>
75
78
</variablelist></refsect2>
76
79
<refsect2>
77
 
<title><anchor id="SQR:CAPS"/>SQR()</title>
 
80
<title><anchor id="SQR:CAPS" role="macro"/>SQR()</title>
78
81
<indexterm><primary>SQR</primary></indexterm><programlisting>#define SQR(x) ((x) * (x))
79
82
</programlisting>
80
83
<para>
87
90
</simpara></listitem></varlistentry>
88
91
</variablelist></refsect2>
89
92
<refsect2>
90
 
<title><anchor id="MAX255:CAPS"/>MAX255()</title>
 
93
<title><anchor id="MAX255:CAPS" role="macro"/>MAX255()</title>
91
94
<indexterm><primary>MAX255</primary></indexterm><programlisting>#define MAX255(a)  ((a) | (((a) &amp; 256) - (((a) &amp; 256) &gt;&gt; 8)))
92
95
</programlisting>
93
96
<para>
100
103
</simpara></listitem></varlistentry>
101
104
</variablelist></refsect2>
102
105
<refsect2>
103
 
<title><anchor id="CLAMP0255:CAPS"/>CLAMP0255()</title>
 
106
<title><anchor id="CLAMP0255:CAPS" role="macro"/>CLAMP0255()</title>
104
107
<indexterm><primary>CLAMP0255</primary></indexterm><programlisting>#define CLAMP0255(a)  CLAMP(a,0,255)
105
108
</programlisting>
106
109
<para>
114
117
</simpara></listitem></varlistentry>
115
118
</variablelist></refsect2>
116
119
<refsect2>
117
 
<title><anchor id="gimp-deg-to-rad"/>gimp_deg_to_rad()</title>
 
120
<title><anchor id="gimp-deg-to-rad" role="macro"/>gimp_deg_to_rad()</title>
118
121
<indexterm><primary>gimp_deg_to_rad</primary></indexterm><programlisting>#define gimp_deg_to_rad(angle) ((angle) * (2.0 * G_PI) / 360.0)
119
122
</programlisting>
120
123
<para>
127
130
</simpara></listitem></varlistentry>
128
131
</variablelist></refsect2>
129
132
<refsect2>
130
 
<title><anchor id="gimp-rad-to-deg"/>gimp_rad_to_deg()</title>
 
133
<title><anchor id="gimp-rad-to-deg" role="macro"/>gimp_rad_to_deg()</title>
131
134
<indexterm><primary>gimp_rad_to_deg</primary></indexterm><programlisting>#define gimp_rad_to_deg(angle) ((angle) * 360.0 / (2.0 * G_PI))
132
135
</programlisting>
133
136
<para>