rmagick 1.14.1 → 1.15.0
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of rmagick might be problematic. Click here for more details.
- data/ChangeLog +22 -0
- data/README.html +11 -63
- data/README.txt +8 -56
- data/configure +214 -787
- data/configure.ac +22 -24
- data/doc/comtasks.html +2 -2
- data/doc/constants.html +5 -6
- data/doc/draw.html +33 -14
- data/doc/ex/clip_path.rb +3 -0
- data/doc/ex/path.rb +1 -1
- data/doc/ex/polaroid.rb +23 -0
- data/doc/ex/tspan01.rb +2 -2
- data/doc/ex/tspan02.rb +2 -2
- data/doc/ex/tspan03.rb +3 -3
- data/doc/ex/wet_floor.rb +54 -0
- data/doc/ilist.html +83 -4
- data/doc/image1.html +4 -5
- data/doc/image2.html +395 -266
- data/doc/image3.html +104 -8
- data/doc/imageattrs.html +2 -2
- data/doc/imusage.html +2 -2
- data/doc/index.html +22 -18
- data/doc/info.html +28 -6
- data/doc/magick.html +125 -4
- data/doc/optequiv.html +196 -21
- data/doc/rvg.html +2 -2
- data/doc/rvgclip.html +2 -2
- data/doc/rvggroup.html +2 -2
- data/doc/rvgimage.html +2 -2
- data/doc/rvgpattern.html +2 -2
- data/doc/rvgshape.html +2 -2
- data/doc/rvgstyle.html +2 -2
- data/doc/rvgtext.html +2 -2
- data/doc/rvgtspan.html +2 -2
- data/doc/rvgtut.html +3 -3
- data/doc/rvguse.html +2 -2
- data/doc/rvgxform.html +2 -2
- data/doc/struct.html +2 -2
- data/doc/usage.html +26 -5
- data/ext/RMagick/MANIFEST +3 -1
- data/ext/RMagick/rmagick.h +46 -12
- data/ext/RMagick/rmagick_config.h.in +12 -2
- data/ext/RMagick/rmdraw.c +202 -62
- data/ext/RMagick/rmfill.c +36 -36
- data/ext/RMagick/rmilist.c +75 -31
- data/ext/RMagick/rmimage.c +640 -323
- data/ext/RMagick/rminfo.c +76 -15
- data/ext/RMagick/rmmain.c +107 -30
- data/ext/RMagick/rmutil.c +97 -68
- data/lib/RMagick.rb +11 -11
- data/lib/rvg/clippath.rb +38 -36
- data/lib/rvg/container.rb +120 -118
- data/lib/rvg/deep_equal.rb +44 -42
- data/lib/rvg/describable.rb +49 -47
- data/lib/rvg/embellishable.rb +399 -397
- data/lib/rvg/misc.rb +613 -603
- data/lib/rvg/paint.rb +38 -36
- data/lib/rvg/pathdata.rb +124 -122
- data/lib/rvg/rvg.rb +202 -198
- data/lib/rvg/stretchable.rb +132 -130
- data/lib/rvg/stylable.rb +101 -99
- data/lib/rvg/text.rb +173 -171
- data/lib/rvg/transformable.rb +120 -118
- data/lib/rvg/units.rb +60 -58
- data/rmagick.gemspec +1 -1
- metadata +5 -3
data/doc/rvg.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st December 2004), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: RVG Class</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: RVG Class</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -27,7 +27,7 @@
|
|
27
27
|
</head>
|
28
28
|
|
29
29
|
<body>
|
30
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
30
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
31
31
|
|
32
32
|
<div class="nav">
|
33
33
|
« <a href="rvgtut.html">Prev</a> | <a href=
|
data/doc/rvgclip.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: RVG::ClipPath Class</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: RVG::ClipPath Class</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -27,7 +27,7 @@
|
|
27
27
|
</head>
|
28
28
|
|
29
29
|
<body>
|
30
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
30
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
31
31
|
|
32
32
|
<div class="nav">
|
33
33
|
« <a href="rvgpattern.html">Prev</a> | <a href=
|
data/doc/rvggroup.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: RVG::Group Class</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: RVG::Group Class</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -27,7 +27,7 @@
|
|
27
27
|
</head>
|
28
28
|
|
29
29
|
<body>
|
30
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
30
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
31
31
|
|
32
32
|
<div class="nav">
|
33
33
|
« <a href="rvg.html">Prev</a> | <a href=
|
data/doc/rvgimage.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: RVG::Image Class</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: RVG::Image Class</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -27,7 +27,7 @@
|
|
27
27
|
</head>
|
28
28
|
|
29
29
|
<body>
|
30
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
30
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
31
31
|
|
32
32
|
<div class="nav">
|
33
33
|
« <a href="rvggroup.html">Prev</a> | <a href=
|
data/doc/rvgpattern.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: RVG::Pattern Class</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: RVG::Pattern Class</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -27,7 +27,7 @@
|
|
27
27
|
</head>
|
28
28
|
|
29
29
|
<body>
|
30
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
30
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
31
31
|
|
32
32
|
<div class="nav">
|
33
33
|
« <a href="rvgimage.html">Prev</a> | <a href=
|
data/doc/rvgshape.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: Shapes</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: Shapes</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -28,7 +28,7 @@
|
|
28
28
|
</head>
|
29
29
|
|
30
30
|
<body>
|
31
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
31
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
32
32
|
|
33
33
|
<div class="nav">
|
34
34
|
« <a href="rvgstyle.html">Prev</a> | <a href=
|
data/doc/rvgstyle.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: Styles</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: Styles</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -27,7 +27,7 @@
|
|
27
27
|
</head>
|
28
28
|
|
29
29
|
<body>
|
30
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
30
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
31
31
|
|
32
32
|
<div class="nav">
|
33
33
|
« <a href="rvguse.html">Prev</a> | <a href=
|
data/doc/rvgtext.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: RVG::Text Class</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: RVG::Text Class</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -33,7 +33,7 @@
|
|
33
33
|
</head>
|
34
34
|
|
35
35
|
<body>
|
36
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
36
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
37
37
|
|
38
38
|
<div class="nav">
|
39
39
|
« <a href="rvgclip.html">Prev</a> | <a href=
|
data/doc/rvgtspan.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: RVG::Tspan Class</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: RVG::Tspan Class</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -27,7 +27,7 @@
|
|
27
27
|
</head>
|
28
28
|
|
29
29
|
<body>
|
30
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
30
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
31
31
|
|
32
32
|
<div class="nav">
|
33
33
|
« <a href="rvgtext.html">Prev</a> | <a href=
|
data/doc/rvgtut.html
CHANGED
@@ -3,13 +3,13 @@
|
|
3
3
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
4
4
|
|
5
5
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
6
|
-
<!-- $Id: rvgtut.html,v 1.
|
6
|
+
<!-- $Id: rvgtut.html,v 1.11 2007/01/14 19:01:41 rmagick Exp $ -->
|
7
7
|
|
8
8
|
<head>
|
9
9
|
<meta name="generator" content=
|
10
10
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
11
11
|
|
12
|
-
<title>RMagick: RVG Tutorial</title>
|
12
|
+
<title>RMagick 1.15.0: RVG Tutorial</title>
|
13
13
|
<meta name="GENERATOR" content="Quanta Plus" />
|
14
14
|
<link rel="stylesheet" type="text/css" href="css/doc.css" />
|
15
15
|
<style type="text/css">
|
@@ -23,7 +23,7 @@
|
|
23
23
|
</head>
|
24
24
|
|
25
25
|
<body>
|
26
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
26
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
27
27
|
|
28
28
|
<div class="nav">
|
29
29
|
« <a href="constants.html">Prev</a> | <a href=
|
data/doc/rvguse.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: RVG::Use Class</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: RVG::Use Class</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -27,7 +27,7 @@
|
|
27
27
|
</head>
|
28
28
|
|
29
29
|
<body>
|
30
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
30
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
31
31
|
|
32
32
|
<div class="nav">
|
33
33
|
« <a href="rvgtspan.html">Prev</a> | <a href=
|
data/doc/rvgxform.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st December 2004), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: RVG Reference: Transforms</title>
|
9
|
+
<title>RMagick 1.15.0: RVG Reference: Transforms</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -28,7 +28,7 @@
|
|
28
28
|
</head>
|
29
29
|
|
30
30
|
<body>
|
31
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
31
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
32
32
|
|
33
33
|
<div class="nav">
|
34
34
|
« <a href="rvgshape.html">Prev</a> | <a href=
|
data/doc/struct.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st March 2005), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: Miscellaneous classes</title>
|
9
|
+
<title>RMagick 1.15.0: Miscellaneous classes</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -27,7 +27,7 @@
|
|
27
27
|
</head>
|
28
28
|
|
29
29
|
<body>
|
30
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
30
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
31
31
|
|
32
32
|
<div class="nav">
|
33
33
|
« <a href="draw.html">Prev</a> | <a href=
|
data/doc/usage.html
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
<meta name="generator" content=
|
7
7
|
"HTML Tidy for Linux/x86 (vers 1st December 2004), see www.w3.org" />
|
8
8
|
|
9
|
-
<title>RMagick: How to use RMagick</title>
|
9
|
+
<title>RMagick 1.15.0: How to use RMagick</title>
|
10
10
|
<meta http-equiv="Content-Type" content=
|
11
11
|
"text/html; charset=us-ascii" />
|
12
12
|
<meta name="GENERATOR" content="Quanta Plus" />
|
@@ -90,7 +90,7 @@
|
|
90
90
|
</head>
|
91
91
|
|
92
92
|
<body>
|
93
|
-
<h6 id="header">RMagick User's Guide and Reference</h6>
|
93
|
+
<h6 id="header">RMagick 1.15.0 User's Guide and Reference</h6>
|
94
94
|
|
95
95
|
<div class="nav">
|
96
96
|
« <a href="index.html">Prev</a> | <a href=
|
@@ -302,7 +302,7 @@ exit
|
|
302
302
|
</pre>
|
303
303
|
|
304
304
|
<p>Within the parameter block you must use <code>self</code> so
|
305
|
-
that Ruby
|
305
|
+
that Ruby knows that this statement is a method call, not an
|
306
306
|
assignment to a variable.</p>
|
307
307
|
|
308
308
|
<p>You can create an image by capturing it from the XWindow
|
@@ -603,8 +603,7 @@ exit
|
|
603
603
|
<dt><a href=
|
604
604
|
"image2.html#ordered_dither">ordered_dither</a></dt>
|
605
605
|
|
606
|
-
<dd>
|
607
|
-
technique</dd>
|
606
|
+
<dd>Dither the image to a predefined pattern</dd>
|
608
607
|
|
609
608
|
<dt><a href="image2.html#posterize">posterize</a></dt>
|
610
609
|
|
@@ -937,6 +936,11 @@ exit
|
|
937
936
|
<dd>Adjust the levels of one or more channels in the
|
938
937
|
image</dd>
|
939
938
|
|
939
|
+
<dt><a href=
|
940
|
+
"image2.html#linear_stretch">linear_stretch</a></dt>
|
941
|
+
|
942
|
+
<dd>Stretch with saturation the image contrast</dd>
|
943
|
+
|
940
944
|
<dt><a href=
|
941
945
|
"image2.html#median_filter">median_filter</a></dt>
|
942
946
|
|
@@ -1027,6 +1031,11 @@ exit
|
|
1027
1031
|
|
1028
1032
|
<dd>Apply a custom convolution kernel to the image</dd>
|
1029
1033
|
|
1034
|
+
<dt class="ilist"><a href="ilist.html#fx">fx</a></dt>
|
1035
|
+
|
1036
|
+
<dd class="ilist">apply a mathematical expression to an
|
1037
|
+
image</dd>
|
1038
|
+
|
1030
1039
|
<dt><a href="image3.html#segment">segment</a></dt>
|
1031
1040
|
|
1032
1041
|
<dd>Segment an image by analyzing the histograms of the color
|
@@ -1039,6 +1048,10 @@ exit
|
|
1039
1048
|
<dd>Change the value of individual pixels based on the
|
1040
1049
|
intensity of each pixel compared to a random threshold.</dd>
|
1041
1050
|
|
1051
|
+
<dt><a href="image3.html#recolor">recolor</a></dt>
|
1052
|
+
|
1053
|
+
<dd>translate, scale, shear, or rotate the image colors</dd>
|
1054
|
+
|
1042
1055
|
<dt><a href="image3.html#threshold">threshold</a></dt>
|
1043
1056
|
|
1044
1057
|
<dd>Change the value of individual pixels based on the
|
@@ -1078,6 +1091,10 @@ exit
|
|
1078
1091
|
|
1079
1092
|
<dd>Add an oil paint effect</dd>
|
1080
1093
|
|
1094
|
+
<dt><a href="image2.html#polaroid">polaroid</a></dt>
|
1095
|
+
|
1096
|
+
<dd>Simulate a Polaroid® instant picture</dd>
|
1097
|
+
|
1081
1098
|
<dt><a href="image3.html#sepiatone">sepiatone</a></dt>
|
1082
1099
|
|
1083
1100
|
<dd>Applies an effect similar to the effect achieved in a
|
@@ -1126,6 +1143,10 @@ exit
|
|
1126
1143
|
<dt><a href="image3.html#wave">wave</a></dt>
|
1127
1144
|
|
1128
1145
|
<dd>Add a ripple effect to the image</dd>
|
1146
|
+
|
1147
|
+
<dt><a href="image3.html#wet_floor">wet_floor</a></dt>
|
1148
|
+
|
1149
|
+
<dd>Create a "wet floor" reflection of the image</dd>
|
1129
1150
|
</dl>
|
1130
1151
|
|
1131
1152
|
<h4>Decorate</h4>
|
data/ext/RMagick/MANIFEST
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
MANIFEST for RMagick-1.
|
1
|
+
MANIFEST for RMagick-1.15.0 - 18:11:38 01/20/07
|
2
2
|
|
3
3
|
configure
|
4
4
|
README.html
|
@@ -84,6 +84,7 @@ doc/constants.html
|
|
84
84
|
doc/comtasks.html
|
85
85
|
doc/ex/writing_mode02.rb
|
86
86
|
doc/ex/writing_mode01.rb
|
87
|
+
doc/ex/wet_floor.rb
|
87
88
|
doc/ex/wave.rb
|
88
89
|
doc/ex/watermark.rb
|
89
90
|
doc/ex/vignette.rb
|
@@ -157,6 +158,7 @@ doc/ex/polyline01.rb
|
|
157
158
|
doc/ex/polyline.rb
|
158
159
|
doc/ex/polygon01.rb
|
159
160
|
doc/ex/polygon.rb
|
161
|
+
doc/ex/polaroid.rb
|
160
162
|
doc/ex/pattern2.rb
|
161
163
|
doc/ex/pattern1.rb
|
162
164
|
doc/ex/path.rb
|
data/ext/RMagick/rmagick.h
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
/* $Id: rmagick.h,v 1.
|
1
|
+
/* $Id: rmagick.h,v 1.152 2007/01/20 16:07:12 rmagick Exp $ */
|
2
2
|
/*=============================================================================
|
3
3
|
| Copyright (C) 2006 by Timothy P. Hunter
|
4
4
|
| Name: rmagick.h
|
@@ -27,9 +27,9 @@
|
|
27
27
|
#undef PACKAGE_STRING
|
28
28
|
#undef PACKAGE_BUGREPORT
|
29
29
|
#undef PACKAGE_TARNAME
|
30
|
-
#include "magick/api.h"
|
31
30
|
|
32
31
|
|
32
|
+
#include "magick/api.h"
|
33
33
|
|
34
34
|
// Undef ImageMagick's versions of these symbols
|
35
35
|
#undef PACKAGE_VERSION
|
@@ -37,6 +37,8 @@
|
|
37
37
|
#undef PACKAGE_STRING
|
38
38
|
#undef PACKAGE_BUGREPORT
|
39
39
|
#undef PACKAGE_TARNAME
|
40
|
+
|
41
|
+
|
40
42
|
#include "rmagick_config.h"
|
41
43
|
|
42
44
|
// Define a pair of macros that make it easier to code
|
@@ -80,6 +82,7 @@
|
|
80
82
|
#define LMAX(a,b) ((((long)(a))>((long)(b)))?((long)(a)):((long)(b)))
|
81
83
|
#define FMAX(a,b) ((((double)(a))>((double)(b)))?((double)(a)):((double)(b)))
|
82
84
|
#define FMIN(a,b) ((((double)(a))<=((double)(b)))?((double)(a)):((double)(b)))
|
85
|
+
#define RMAGICK_PI 3.14159265358979
|
83
86
|
|
84
87
|
typedef ImageInfo Info; // Make type name match class name
|
85
88
|
typedef PixelPacket Pixel;
|
@@ -100,9 +103,10 @@ struct TmpFile_Name
|
|
100
103
|
|
101
104
|
typedef struct
|
102
105
|
{
|
103
|
-
DrawInfo *info;
|
104
|
-
VALUE primitives;
|
106
|
+
DrawInfo *info; // the DrawInfo struct
|
107
|
+
VALUE primitives; // the primitive string
|
105
108
|
struct TmpFile_Name *tmpfile_ary;
|
109
|
+
PixelPacket shadow_color; // PolaroidOptions#shadow_color
|
106
110
|
} Draw; // make the type match the class name
|
107
111
|
|
108
112
|
// Enum
|
@@ -207,8 +211,15 @@ typedef enum _QuantumExpressionOperator
|
|
207
211
|
#endif
|
208
212
|
#endif
|
209
213
|
|
214
|
+
// IM < 6.2.0 and GM don't have MagickBooleanType
|
210
215
|
#if !defined(HAVE_MAGICKBOOLEANTYPE)
|
211
216
|
typedef unsigned int MagickBooleanType;
|
217
|
+
#if !defined(MagickTrue)
|
218
|
+
#define MagickTrue 1
|
219
|
+
#endif
|
220
|
+
#if !defined(MagickFalse)
|
221
|
+
#define MagickFalse 0
|
222
|
+
#endif
|
212
223
|
#endif
|
213
224
|
|
214
225
|
#if !defined(HAVE_UNDEFINEDGRAVITY)
|
@@ -249,6 +260,7 @@ EXTERN VALUE Module_Magick;
|
|
249
260
|
EXTERN VALUE Class_ImageList;
|
250
261
|
EXTERN VALUE Class_Info;
|
251
262
|
EXTERN VALUE Class_Draw;
|
263
|
+
EXTERN VALUE Class_DrawOptions;
|
252
264
|
EXTERN VALUE Class_Image;
|
253
265
|
EXTERN VALUE Class_Montage;
|
254
266
|
EXTERN VALUE Class_ImageMagickError;
|
@@ -262,6 +274,7 @@ EXTERN VALUE Class_Geometry;
|
|
262
274
|
EXTERN VALUE Class_GeometryValue; // Defined in RMagick.rb
|
263
275
|
EXTERN VALUE Class_Pixel;
|
264
276
|
EXTERN VALUE Class_Point;
|
277
|
+
EXTERN VALUE Class_PolaroidOptions;
|
265
278
|
EXTERN VALUE Class_Primary;
|
266
279
|
EXTERN VALUE Class_Rectangle;
|
267
280
|
EXTERN VALUE Class_Segment;
|
@@ -375,6 +388,9 @@ EXTERN ID ID_y; // "y"
|
|
375
388
|
#define DCL_ATTR_ACCESSOR(class, attr) \
|
376
389
|
DCL_ATTR_READER(class, attr) \
|
377
390
|
DCL_ATTR_WRITER(class, attr)
|
391
|
+
// Borrow another class' attribute writer definition
|
392
|
+
#define SHARE_ATTR_WRITER(to, from, attr) \
|
393
|
+
rb_define_method(Class_##to, #attr "=", from##_##attr##_eq, 1);
|
378
394
|
|
379
395
|
/*
|
380
396
|
Define simple attribute accessor methods (boolean, int, string, and double types)
|
@@ -462,9 +478,9 @@ Pixel_##_channel_##_eq(VALUE self, VALUE v) \
|
|
462
478
|
rm_check_frozen(self); \
|
463
479
|
Data_Get_Struct(self, Pixel, pixel); \
|
464
480
|
pixel->_channel_ = (Quantum) NUM2UINT(v); \
|
465
|
-
rb_funcall(self, ID_changed, 0); \
|
466
|
-
rb_funcall(self, ID_notify_observers, 1, self); \
|
467
|
-
return
|
481
|
+
(void) rb_funcall(self, ID_changed, 0); \
|
482
|
+
(void) rb_funcall(self, ID_notify_observers, 1, self); \
|
483
|
+
return UINT2NUM((unsigned int)(pixel->_channel_)); \
|
468
484
|
}
|
469
485
|
|
470
486
|
|
@@ -480,9 +496,9 @@ Pixel_##_cmyk_channel_##_eq(VALUE self, VALUE v) \
|
|
480
496
|
rm_check_frozen(self); \
|
481
497
|
Data_Get_Struct(self, Pixel, pixel); \
|
482
498
|
pixel->_rgb_channel_ = (Quantum) NUM2UINT(v); \
|
483
|
-
rb_funcall(self, ID_changed, 0); \
|
484
|
-
rb_funcall(self, ID_notify_observers, 1, self); \
|
485
|
-
return
|
499
|
+
(void) rb_funcall(self, ID_changed, 0); \
|
500
|
+
(void) rb_funcall(self, ID_notify_observers, 1, self); \
|
501
|
+
return UINT2NUM((unsigned int)pixel->_rgb_channel_); \
|
486
502
|
} \
|
487
503
|
\
|
488
504
|
extern VALUE \
|
@@ -567,10 +583,14 @@ extern VALUE Draw_initialize(VALUE);
|
|
567
583
|
extern VALUE Draw_inspect(VALUE);
|
568
584
|
#if defined(HAVE_RB_DEFINE_ALLOC_FUNC)
|
569
585
|
extern VALUE Draw_alloc(VALUE);
|
586
|
+
extern VALUE DrawOptions_alloc(VALUE);
|
570
587
|
#else
|
571
588
|
extern VALUE Draw_new(VALUE);
|
589
|
+
extern VALUE DrawOptions_new(VALUE);
|
572
590
|
#endif
|
573
591
|
extern VALUE Draw_primitive(VALUE, VALUE);
|
592
|
+
extern VALUE DrawOptions_initialize(VALUE);
|
593
|
+
|
574
594
|
|
575
595
|
ATTR_WRITER(Montage, background_color)
|
576
596
|
ATTR_WRITER(Montage, border_color)
|
@@ -598,6 +618,15 @@ extern VALUE Montage_new(VALUE);
|
|
598
618
|
extern VALUE rm_montage_new(void);
|
599
619
|
|
600
620
|
|
621
|
+
extern VALUE PolaroidOptions_alloc(VALUE);
|
622
|
+
#if !defined(HAVE_RB_DEFINE_ALLOC_FUNC)
|
623
|
+
extern VALUE PolaroidOptions_new(VALUE);
|
624
|
+
#endif
|
625
|
+
extern VALUE PolaroidOptions_initialize(VALUE);
|
626
|
+
extern VALUE rm_polaroid_new(void);
|
627
|
+
ATTR_WRITER(PolaroidOptions, shadow_color);
|
628
|
+
|
629
|
+
|
601
630
|
// rmmain.c
|
602
631
|
extern VALUE rm_montage_new(void);
|
603
632
|
|
@@ -610,6 +639,7 @@ extern VALUE ImageList_coalesce(VALUE);
|
|
610
639
|
extern VALUE ImageList_deconstruct(VALUE);
|
611
640
|
extern VALUE ImageList_display(VALUE);
|
612
641
|
extern VALUE ImageList_flatten_images(VALUE);
|
642
|
+
extern VALUE ImageList_fx(int, VALUE *, VALUE);
|
613
643
|
extern VALUE ImageList_map(int, VALUE *, VALUE);
|
614
644
|
extern VALUE ImageList_montage(VALUE);
|
615
645
|
extern VALUE ImageList_morph(VALUE, VALUE);
|
@@ -656,6 +686,7 @@ ATTR_WRITER(Info, monitor)
|
|
656
686
|
ATTR_ACCESSOR(Info, monochrome)
|
657
687
|
ATTR_ACCESSOR(Info, number_scenes)
|
658
688
|
ATTR_ACCESSOR(Info, orientation)
|
689
|
+
ATTR_ACCESSOR(Info, origin)
|
659
690
|
ATTR_ACCESSOR(Info, page)
|
660
691
|
ATTR_ACCESSOR(Info, pen)
|
661
692
|
// ATTR_ACCESSOR(Info, ping) obsolete
|
@@ -856,6 +887,7 @@ extern VALUE Image_init_copy(VALUE, VALUE);
|
|
856
887
|
extern VALUE Image_inspect(VALUE);
|
857
888
|
extern VALUE Image_level2(int, VALUE *, VALUE);
|
858
889
|
extern VALUE Image_level_channel(int, VALUE *, VALUE);
|
890
|
+
extern VALUE Image_linear_stretch(int, VALUE *, VALUE);
|
859
891
|
extern VALUE Image__load(VALUE, VALUE);
|
860
892
|
extern VALUE Image_magnify(VALUE);
|
861
893
|
extern VALUE Image_magnify_bang(VALUE);
|
@@ -878,7 +910,7 @@ extern VALUE Image_ordered_dither(int, VALUE *, VALUE);
|
|
878
910
|
extern VALUE Image_palette_q(VALUE);
|
879
911
|
extern VALUE Image_ping(VALUE, VALUE);
|
880
912
|
extern VALUE Image_pixel_color(int, VALUE *, VALUE);
|
881
|
-
|
913
|
+
extern VALUE Image_polaroid(int, VALUE *, VALUE);
|
882
914
|
extern VALUE Image_posterize(int, VALUE *, VALUE);
|
883
915
|
extern VALUE Image_preview(VALUE, VALUE);
|
884
916
|
extern VALUE Image_profile_bang(VALUE, VALUE, VALUE);
|
@@ -892,6 +924,7 @@ extern VALUE Image_random_channel_threshold(VALUE, VALUE, VALUE);
|
|
892
924
|
extern VALUE Image_random_threshold_channel(int, VALUE *, VALUE);
|
893
925
|
extern VALUE Image_read(VALUE, VALUE);
|
894
926
|
extern VALUE Image_read_inline(VALUE, VALUE);
|
927
|
+
extern VALUE Image_recolor(VALUE, VALUE);
|
895
928
|
extern VALUE Image_reduce_noise(VALUE, VALUE);
|
896
929
|
extern VALUE Image_resize(int, VALUE *, VALUE);
|
897
930
|
extern VALUE Image_resize_bang(int, VALUE *, VALUE);
|
@@ -945,6 +978,7 @@ extern VALUE Image_unsharp_mask_channel(int, VALUE *, VALUE);
|
|
945
978
|
extern VALUE Image_vignette(int, VALUE *, VALUE);
|
946
979
|
extern VALUE Image_watermark(int, VALUE *, VALUE);
|
947
980
|
extern VALUE Image_wave(int, VALUE *, VALUE);
|
981
|
+
extern VALUE Image_wet_floor(int, VALUE *, VALUE);
|
948
982
|
extern VALUE Image_white_threshold(int, VALUE *, VALUE);
|
949
983
|
extern VALUE Image_write(VALUE, VALUE);
|
950
984
|
|
@@ -1080,7 +1114,7 @@ extern char *rm_string_value_ptr(volatile VALUE *);
|
|
1080
1114
|
#endif
|
1081
1115
|
extern char *rm_string_value_ptr_len(volatile VALUE *, long *);
|
1082
1116
|
extern int rm_strcasecmp(const char *, const char *);
|
1083
|
-
extern void rm_check_ary_len(VALUE,
|
1117
|
+
extern void rm_check_ary_len(VALUE, long);
|
1084
1118
|
extern void rm_check_frozen(VALUE);
|
1085
1119
|
extern int rm_check_num2dbl(VALUE);
|
1086
1120
|
extern double rm_fuzz_to_dbl(VALUE);
|