rmagick 1.7.1 → 1.7.2
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 +3 -0
- data/README.html +387 -367
- data/README.txt +8 -8
- data/configure +132 -10
- data/configure.ac +9 -1
- data/doc/draw.html +2 -2
- data/ext/RMagick/MANIFEST +2 -1
- data/ext/RMagick/rmagick.h +9 -1
- data/ext/RMagick/rmagick_config.h.in +2 -0
- data/ext/RMagick/rmimage.c +22 -1
- data/ext/RMagick/rmmain.c +29 -12
- data/ext/RMagick/rmutil.c +46 -2
- data/rmagick.gemspec +1 -1
- metadata +3 -3
data/ChangeLog
CHANGED
data/README.html
CHANGED
@@ -1,124 +1,122 @@
|
|
1
|
-
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
2
|
-
"http://www.w3.org/TR/html4/loose.dtd">
|
1
|
+
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
3
2
|
<html>
|
4
3
|
<head>
|
5
|
-
<
|
6
|
-
"
|
7
|
-
<
|
8
|
-
<meta http-equiv="Content-Type" content=
|
9
|
-
"text/html; charset=ISO-8859-1">
|
10
|
-
<meta name="GENERATOR" content="Quanta Plus">
|
4
|
+
<title>RMagick 1.7.2 README</title>
|
5
|
+
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
6
|
+
<meta name="GENERATOR" content="BlueCloth">
|
11
7
|
</head>
|
12
8
|
<body>
|
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
|
-
|
9
|
+
<p>RMagick 1.7.2</p>
|
10
|
+
|
11
|
+
<pre><code>README
|
12
|
+
|
13
|
+
|
14
|
+
02/23/05
|
15
|
+
|
16
|
+
|
17
|
+
Table of Contents
|
18
|
+
|
19
|
+
* Introduction <#introduction>
|
20
|
+
* Contact information <#contact_information>
|
21
|
+
* Prerequisites <#prerequisites>
|
22
|
+
* Tips for installing and configuring ImageMagick and GraphicsMagick
|
23
|
+
<#tips>
|
24
|
+
* Installing RMagick <#installing_rmagick>
|
25
|
+
o Configuration options <#configuration_options>
|
26
|
+
o Running the configure and make scripts <#running>
|
27
|
+
* Things that can go wrong <#things_that_can_go_wrong>
|
28
|
+
* Upgrading <#upgrading>
|
29
|
+
* Uninstalling <#uninstalling>
|
30
|
+
* More samples <#more_samples>
|
31
|
+
* Undocumented features <#undocumented_features>
|
32
|
+
* Known issues <#known_issues>
|
33
|
+
* Reporting bugs <#reporting_bugs>
|
34
|
+
* Credits <#credits>
|
35
|
+
* License <#license>
|
36
|
+
|
37
|
+
|
38
|
+
Introduction
|
39
|
+
</code></pre>
|
40
|
+
|
41
|
+
<p>RMagick is an interface between the Ruby programming language and the
|
42
|
+
ImageMagick and GraphicsMagick image processing libraries.</p>
|
43
|
+
|
44
|
+
<pre><code>Contact Information
|
45
|
+
</code></pre>
|
46
|
+
|
47
|
+
<p><em>Author:</em> Tim Hunter
|
48
|
+
<em>Email:</em> rmagick@rubyforge.org <mailto:rmagick@rubyforge.org>
|
49
|
+
<em>RubyForge:</em> RMagick <a href="http://rubyforge.org/projects/rmagick">http://rubyforge.org/projects/rmagick</a></p>
|
50
|
+
|
51
|
+
<pre><code>Prerequisites
|
52
|
+
</code></pre>
|
53
|
+
|
54
|
+
<p><em>O/S</em>
|
55
|
+
Linux, Sun Solaris, Cygwin, FreeBSD, MS Windows 98 and later.
|
56
|
+
<em>Ruby</em>
|
57
|
+
Ruby 1.6.7 or later. You can get Ruby from www.ruby-lang.org
|
58
|
+
<a href="http://www.ruby-lang.org">http://www.ruby-lang.org</a></p>
|
59
|
+
|
60
|
+
<p>One of</p>
|
61
|
+
|
62
|
+
<p><em>ImageMagick</em>
|
63
|
+
ImageMagick 6.0.0 or later. You can get ImageMagick from
|
64
|
+
www.imagemagick.org <a href="http://www.imagemagick.org">http://www.imagemagick.org</a>.
|
65
|
+
<em>GraphicsMagick</em>
|
66
|
+
GraphicsMagick is a friendly fork of ImageMagick 5.5.1. You can get
|
67
|
+
GraphicsMagick from www.graphicsmagick.org
|
68
|
+
<a href="http://www.graphicsmagick.org">http://www.graphicsmagick.org</a>.</p>
|
69
|
+
|
70
|
+
<p>You only need one of ImageMagick or GraphicsMagick. RMagick works
|
71
|
+
equally well with both. Some RMagick methods may not be supported in one
|
72
|
+
or the other library.</p>
|
73
|
+
|
74
|
+
<pre><code>Tips for installing and configuring ImageMagick and GraphicsMagick
|
75
|
+
</code></pre>
|
76
|
+
|
77
|
+
<p>if you are installing RMagick by compiling the source code, I /strongly/
|
78
|
+
encourage you to install the latest version of ImageMagick or
|
79
|
+
GraphicsMagick /from source/. If you have never installed ImageMagick or
|
80
|
+
GraphicsMagick before, I also strongly encourage you to read the
|
81
|
+
README.txt file as many times as is necessary for you to understand how
|
82
|
+
to configure it. ImageMagick and GraphicsMagick are large and
|
83
|
+
complicated programs and can be difficult to configure. Follow these
|
84
|
+
tips to minimize the amount of time you'll spend and your frustration level.</p>
|
85
|
+
|
86
|
+
<p>Do /not/ simply type ./configure and expect the defaults to be correct
|
87
|
+
for you. Since you are installing ImageMagick/GraphicsMagick to use with
|
88
|
+
Ruby, consider whether you want to skip ImageMagick's/GraphicMagicks'
|
89
|
+
support for Perl and C++ by using the --without-perl and
|
90
|
+
--without-magick-plus-plus options. Doing so will speed up the
|
91
|
+
installation process and save some disk space. You will almost certainly
|
92
|
+
want to specify the --enable-shared and --disable-static options.</p>
|
93
|
+
|
94
|
+
<p>Determine which image formats you are interested in using and make sure
|
95
|
+
that you have installed the libraries that ImageMagick/GraphicsMagick
|
96
|
+
uses to process these formats. ImageMagick and GraphicsMagick use
|
97
|
+
additional libraries to support some image formats. If you do not
|
98
|
+
install those libraries you cannot read and write those image formats.
|
99
|
+
You will need to configure ImageMagick/GraphicsMagick to support the
|
100
|
+
JPG, PNG, TIFF, and WMF formats in order to execute all the RMagick
|
101
|
+
sample programs. See ImageMagick's or GraphicMagick's README.txt file
|
102
|
+
for more information.</p>
|
103
|
+
|
104
|
+
<p>Once you have determined the configuration options you need, run the
|
105
|
+
configure script. When it completes, read the summary output to see if
|
106
|
+
configuration worked the way you expected. Here's an example of the
|
107
|
+
summary output from ImageMagick's configure script. Notice that the
|
108
|
+
result of each option is listed in the "Configured value" column.</p>
|
109
|
+
|
110
|
+
<h2> Option Value</h2>
|
111
|
+
|
112
|
+
<p>Shared libraries --enable-shared=yes yes
|
115
113
|
Static libraries --enable-static=no no
|
116
114
|
Module support --with-modules=yes yes
|
117
115
|
GNU ld --with-gnu-ld=yes yes
|
118
116
|
LZW support --enable-lzw=yes yes
|
119
|
-
Quantum depth --with-quantum-depth=8 8
|
117
|
+
Quantum depth --with-quantum-depth=8 8</p>
|
120
118
|
|
121
|
-
Delegate Configuration:
|
119
|
+
<p>Delegate Configuration:
|
122
120
|
BZLIB --with-bzlib=yes yes
|
123
121
|
DPS --with-dps=yes yes
|
124
122
|
FlashPIX --with-fpx=yes no
|
@@ -139,266 +137,288 @@ Windows fonts --with-windows-font-dir=/mnt/windows/windows/fonts /mnt/win
|
|
139
137
|
WMF --with-wmf=yes yes
|
140
138
|
X11 --with-x= yes
|
141
139
|
XML --with-xml=yes yes
|
142
|
-
ZLIB --with-zlib=yes yes
|
140
|
+
ZLIB --with-zlib=yes yes</p>
|
143
141
|
|
144
|
-
X11 Configuration:
|
142
|
+
<p>X11 Configuration:
|
145
143
|
X_CFLAGS = -I/usr/X11R6/include
|
146
|
-
|
144
|
+
X<em>PRE</em>LIBS = -lSM -lICE
|
147
145
|
X_LIBS = -L/usr/X11R6/lib
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
|
217
|
-
|
146
|
+
X<em>EXTRA</em>LIBS =</p>
|
147
|
+
|
148
|
+
<p>If the results are not what you wanted, install any missing libraries,
|
149
|
+
choose new or different options, or whatever it takes, erase the
|
150
|
+
config.cache file, and re-run configure. Repeat as often as necessary
|
151
|
+
before moving to the <code>make' and</code>make install' steps.</p>
|
152
|
+
|
153
|
+
<p>Detailed information about all of ImageMagick's and GraphicsMagick's
|
154
|
+
configuration options may be found in their README.txt and INSTALL.txt
|
155
|
+
files.</p>
|
156
|
+
|
157
|
+
<pre><code> Windows Metafile Format
|
158
|
+
</code></pre>
|
159
|
+
|
160
|
+
<p>As noted in the ImageMagick and GraphicsMagick README.txt files, to
|
161
|
+
support images in the Windows Metafile format,
|
162
|
+
ImageMagick/GraphicsMagick requires an additional library. Without this
|
163
|
+
library some of the RMagick sample programs will not work. ImageMagick
|
164
|
+
and GraphicsMagick require libwmf 0.2.5, 0.2.7, or 0.2.2 to support the
|
165
|
+
WMF format. (Avoid libwmf 0.2.6!)</p>
|
166
|
+
|
167
|
+
<pre><code>Installing RMagick
|
168
|
+
</code></pre>
|
169
|
+
|
170
|
+
<p>Installing RMagick is much simpler than installing ImageMagick or
|
171
|
+
GraphicsMagick. Note that the /make/ step runs all the example programs.
|
172
|
+
This process both builds the example images used in the documentation
|
173
|
+
and validates your RMagick installation. This step can take 5-15 minutes
|
174
|
+
depending on the speed of your computer.</p>
|
175
|
+
|
176
|
+
<pre><code> Configuration options
|
177
|
+
</code></pre>
|
178
|
+
|
179
|
+
<p>Type |./configure --help| to see a list of configuration options. In
|
180
|
+
addition to the regular options, there are a few RMagick-specific options:</p>
|
181
|
+
|
182
|
+
<p>--with-doc-dir=directory
|
183
|
+
Specify the directory to install the RMagick documentation. By
|
184
|
+
default this is $prefix/share/RMagick, where $prefix is the prefix
|
185
|
+
specified by --prefix. For example, to install the documentation in
|
186
|
+
/home/user/RMagick, specify:</p>
|
187
|
+
|
188
|
+
<p>./configure --with-doc-dir=/home/user/RMagick</p>
|
189
|
+
|
190
|
+
<p>--enable-allow-example-errors
|
191
|
+
Normally the documentation installation terminates if 5 examples
|
192
|
+
fail. If you use this option, the installation does not check for
|
193
|
+
failing examples and will always complete. This option is useful if
|
194
|
+
you're having trouble installing RMagick and you want to see all the
|
195
|
+
failing examples.
|
196
|
+
--with-graphics-magick
|
197
|
+
If you have both ImageMagick and GraphicsMagick installed, this
|
198
|
+
option will force RMagick to be configured with GraphicsMagick.
|
199
|
+
--with-so-dir=directory
|
200
|
+
The directory for ruby extensions.
|
201
|
+
--with-ruby-path=directory
|
202
|
+
The path to set the !# line in Ruby scripts. The default is
|
203
|
+
|$prefix/bin/ruby|.
|
204
|
+
--with-ruby-prog=name
|
205
|
+
The name of the Ruby executable. The default is |ruby|.
|
206
|
+
--with-make-prog=name
|
207
|
+
The name of the |make| program.
|
208
|
+
--with-rbconfig=path
|
209
|
+
The path to the rbconfig.rb file to use. The default is Ruby's rbconfig.</p>
|
210
|
+
|
211
|
+
<pre><code> Running the |configure| and |make| scripts
|
212
|
+
</code></pre>
|
213
|
+
|
214
|
+
<p>De-compress the RMagick-1.7.2.tar.gz archive and enter the
|
215
|
+
top directory. Then type:</p>
|
216
|
+
|
217
|
+
<pre><code>$ ./configure <configuration options>
|
218
|
+
$ make
|
219
|
+
</code></pre>
|
220
|
+
|
221
|
+
<p>($ su)
|
218
222
|
$ make install
|
219
223
|
(optionally)
|
220
|
-
$ make clean
|
221
|
-
|
222
|
-
|
223
|
-
|
224
|
-
|
225
|
-
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
|
224
|
+
$ make clean</p>
|
225
|
+
|
226
|
+
<pre><code>Things that can go wrong
|
227
|
+
</code></pre>
|
228
|
+
|
229
|
+
<p><em>Cannot open shared object file</em></p>
|
230
|
+
|
231
|
+
<pre><code>When |make| is running the examples, if you get a message like this:
|
232
|
+
</code></pre>
|
233
|
+
|
234
|
+
<p>/home/you/RMagick-1.7.2/lib/RMagick.rb:11:in 'require': libMagick.so.0:
|
231
235
|
cannot open shared object file: No such file or directory -
|
232
|
-
/home/you/RMagick-1.7.
|
233
|
-
|
234
|
-
|
235
|
-
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
export
|
244
|
-
|
245
|
-
|
246
|
-
|
247
|
-
|
248
|
-
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
<
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
export TMPDIR=/home/me/tmp
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
268
|
-
|
269
|
-
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
276
|
-
|
277
|
-
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
290
|
-
|
291
|
-
|
292
|
-
|
293
|
-
|
294
|
-
|
295
|
-
|
296
|
-
|
297
|
-
|
298
|
-
|
299
|
-
|
300
|
-
|
301
|
-
</
|
302
|
-
|
303
|
-
|
304
|
-
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
|
327
|
-
|
328
|
-
|
329
|
-
|
330
|
-
|
331
|
-
|
332
|
-
|
333
|
-
|
334
|
-
|
335
|
-
|
336
|
-
|
337
|
-
<
|
338
|
-
|
339
|
-
|
340
|
-
|
341
|
-
|
342
|
-
|
343
|
-
|
344
|
-
|
345
|
-
<
|
346
|
-
|
347
|
-
</
|
348
|
-
|
349
|
-
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
357
|
-
|
358
|
-
|
359
|
-
|
360
|
-
|
361
|
-
|
362
|
-
|
363
|
-
|
364
|
-
|
365
|
-
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
377
|
-
|
378
|
-
|
379
|
-
|
380
|
-
|
381
|
-
|
382
|
-
|
383
|
-
|
384
|
-
|
385
|
-
|
386
|
-
|
387
|
-
|
388
|
-
|
389
|
-
|
390
|
-
|
391
|
-
|
392
|
-
|
393
|
-
|
394
|
-
|
395
|
-
|
396
|
-
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
402
|
-
|
236
|
+
/home/you/RMagick-1.7.2/ext/RMagick/RMagick.so (LoadError)</p>
|
237
|
+
|
238
|
+
<pre><code>you probably do not have the directory in which the ImageMagick or
|
239
|
+
GraphicsMagick library is installed in your load path. An easy way
|
240
|
+
to fix this is to define the directory in the LD_LIBRARY_PATH
|
241
|
+
environment variable. For example, suppose you installed the
|
242
|
+
GraphicsMagick library libGraphicsMagick.so in /usr/local/lib. (By
|
243
|
+
default this is where it is installed.) Create the LD_LIBRARY_PATH
|
244
|
+
variable like this:
|
245
|
+
</code></pre>
|
246
|
+
|
247
|
+
<p>export LD<em>LIBRARY</em>PATH=/usr/local/lib</p>
|
248
|
+
|
249
|
+
<pre><code>On Linux, see |ld(1)| and |ld.so(8)| for more information. On other
|
250
|
+
operating systems, see the documentation for the dynamic loading
|
251
|
+
facility.
|
252
|
+
</code></pre>
|
253
|
+
|
254
|
+
<p><em>No such file or directory - "/tmp/rmagick6872.6"</em></p>
|
255
|
+
|
256
|
+
<pre><code>When |make| is running the examples, if you get a message like this:
|
257
|
+
</code></pre>
|
258
|
+
|
259
|
+
<p>hook /home/me/src/RMagick-1.7.2/./post-setup.rb failed:
|
260
|
+
No such file or directory - "/tmp/rmagick6872.6"</p>
|
261
|
+
|
262
|
+
<pre><code>you probably do not have a temporary directory environment variable
|
263
|
+
set. Set the TMPDIR environment variable to your temporary
|
264
|
+
directory. For example:
|
265
|
+
</code></pre>
|
266
|
+
|
267
|
+
<p>export TMPDIR=/home/me/tmp</p>
|
268
|
+
|
269
|
+
<pre><code>Upgrading
|
270
|
+
</code></pre>
|
271
|
+
|
272
|
+
<p>If you upgrade to a newer release of ImageMagick or GraphicsMagick, make
|
273
|
+
sure you're using a release of RMagick that supports that release.
|
274
|
+
Usually I put out a new release of RMagick with every new release of
|
275
|
+
ImageMagick. It's safe to install a newer release of RMagick over an
|
276
|
+
earlier release.</p>
|
277
|
+
|
278
|
+
<pre><code>Uninstalling
|
279
|
+
</code></pre>
|
280
|
+
|
281
|
+
<p>The 'uninstall' target will uninstall RMagick completely:</p>
|
282
|
+
|
283
|
+
<pre><code>|make uninstall|
|
284
|
+
|
285
|
+
|
286
|
+
More samples
|
287
|
+
</code></pre>
|
288
|
+
|
289
|
+
<p>You can find more sample RMagick programs in the /example directory.
|
290
|
+
These programs are not installed in the RMagick documentation tree.</p>
|
291
|
+
|
292
|
+
<pre><code>Undocumented features
|
293
|
+
</code></pre>
|
294
|
+
|
295
|
+
<p>This release includes an extra feature that isn't in the documentation.
|
296
|
+
The Magick module defines two methods that control ImageMagick's logging
|
297
|
+
function. This function is not officially documented by ImageMagick, so
|
298
|
+
I have decided not to add them to RMagick's documentation. However, you
|
299
|
+
may find them helpful for debugging your application. (Caveat: these two
|
300
|
+
methods may change behavior or be removed without advance notice! You
|
301
|
+
are on your own!)</p>
|
302
|
+
|
303
|
+
<p>/Magick::set<em>log</em>event_mask(event [,...]) -> Magick/</p>
|
304
|
+
|
305
|
+
<p>The arguments are one or more "event domains". The set<em>log</em>event_mask
|
306
|
+
method recognizes these event domains: "all", "annotate", "blob",
|
307
|
+
"cache", "coder", "configure", "deprecate", "draw", "locale", "none",
|
308
|
+
"resource", "transform", "user", and "x11". ImageMagick events that
|
309
|
+
match the mask are logged. The default domain is "none". For example,</p>
|
310
|
+
|
311
|
+
<pre><code> Magick::set_log_event_mask("render")
|
312
|
+
</code></pre>
|
313
|
+
|
314
|
+
<p>Logging is controlled by the log.mgk file, which may be found in the
|
315
|
+
same directory as the delegates.mgk files. (See ImageMagick's README.txt
|
316
|
+
file.) The purpose of the entries in this file is undocumented, so your
|
317
|
+
guess is as good as mine. Also, the meaning of the event domains and
|
318
|
+
exactly what events are logged are undocumented.</p>
|
319
|
+
|
320
|
+
<p>/Magick::set<em>log</em>format(format) -> Magick/</p>
|
321
|
+
|
322
|
+
<p>The default log format is described in the log.mgk file. This method
|
323
|
+
allows you to redefine the format at run-time. The format argument is a
|
324
|
+
string similar to an fprintf format string. Each line in the log has the
|
325
|
+
format described by the format string. Characters that are not control
|
326
|
+
characters are printed as-is. The control characters are:</p>
|
327
|
+
|
328
|
+
<pre><code> %t - the current time
|
329
|
+
%r - the elapsed time
|
330
|
+
%u - the user time
|
331
|
+
%p - the pid (process id)
|
332
|
+
%m - the name of the ImageMagick source file that contains the
|
333
|
+
function that generated the event
|
334
|
+
%f - the name of the ImageMagick function that generated the
|
335
|
+
event
|
336
|
+
%l - the line number in the source file
|
337
|
+
%d - the event domain (one of the event mask strings listed above)
|
338
|
+
%e - the event name
|
339
|
+
</code></pre>
|
340
|
+
|
341
|
+
<p>For example, the default log format is:</p>
|
342
|
+
|
343
|
+
<pre><code> Magick::set_log_format("%t %r %u %p %m/%f/%l/%d:\n %e")
|
344
|
+
|
345
|
+
|
346
|
+
Known issues
|
347
|
+
</code></pre>
|
348
|
+
|
349
|
+
<ol>
|
350
|
+
<li>gcc 3.2, during the "install.rb setup" step, issues the warning:</li>
|
351
|
+
</ol>
|
352
|
+
|
353
|
+
<p>cc1: warning: changing search order for system directory "/usr/local/include"
|
354
|
+
cc1: warning: as it has already been specified as a non-system directory</p>
|
355
|
+
|
356
|
+
<pre><code> This does not indicate a problem.
|
357
|
+
</code></pre>
|
358
|
+
|
359
|
+
<ol>
|
360
|
+
<li>With older releases of ImageMagick you may see the warning:</li>
|
361
|
+
</ol>
|
362
|
+
|
363
|
+
<p>/usr/include/sys/ipc.h:25:3: warning: #warning "Files using this header must be compiled with <em>SVID</em>SOURCE or <em>XOPEN</em>SOURCE"</p>
|
364
|
+
|
365
|
+
<pre><code> This is harmless.
|
366
|
+
|
367
|
+
|
368
|
+
Reporting bugs
|
369
|
+
</code></pre>
|
370
|
+
|
371
|
+
<p>Please report bugs in RMagick, its documentation, or its installation
|
372
|
+
programs to me via the bug tracker on the RMagick project page
|
373
|
+
<a href="http://rubyforge.org/projects/rmagick/">http://rubyforge.org/projects/rmagick/</a> at RubyForge. However, I cannot
|
374
|
+
help with Ruby installation and configuration or ImageMagick or
|
375
|
+
GraphicsMagick installation and configuration. Please report problems
|
376
|
+
with that software to their respective authors or distributors.</p>
|
377
|
+
|
378
|
+
<pre><code>Credits
|
379
|
+
</code></pre>
|
380
|
+
|
381
|
+
<p>Thanks to</p>
|
382
|
+
|
383
|
+
<pre><code>* Akinori MUSHA, for his work making RMagick available on FreeBSD.
|
384
|
+
* Tom Payne, for reporting bugs, sending me the Ruby 1.8.0 patches,
|
385
|
+
and for the Gentoo ebuild.
|
386
|
+
* Bob Friesenhahn, for GraphicsMagick. Also for his help with the
|
387
|
+
RMagick installation and many other things.
|
388
|
+
* Simple Systems, for hosting the RMagick documentation online.
|
389
|
+
* Mike Williams, for the RMagick Debian package
|
390
|
+
* ImageMagick Studio LLC, for ImageMagick and for hosting the
|
391
|
+
RMagick documentation.
|
392
|
+
* Kaspar Schiess, for the MS Windows gem.
|
393
|
+
|
394
|
+
|
395
|
+
License
|
396
|
+
</code></pre>
|
397
|
+
|
398
|
+
<p>Copyright � 2004 by Timothy P. Hunter</p>
|
399
|
+
|
400
|
+
<p>Permission is hereby granted, free of charge, to any person obtaining a
|
401
|
+
copy of this software and associated documentation files (the
|
402
|
+
"Software"), to deal in the Software without restriction, including
|
403
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
404
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
405
|
+
permit persons to whom the Software is furnished to do so, subject to
|
406
|
+
the following conditions:</p>
|
407
|
+
|
408
|
+
<p>The above copyright notice and this permission notice shall be included
|
409
|
+
in all copies or substantial portions of the Software.</p>
|
410
|
+
|
411
|
+
<p>THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
412
|
+
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
413
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
414
|
+
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
415
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
416
|
+
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
417
|
+
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.</p>
|
418
|
+
|
419
|
+
<p><a href="http://www.opensource.org/docs/definition.php">http://www.opensource.org/docs/definition.php</a></p>
|
420
|
+
|
421
|
+
<p>*This software is OSI Certified Open Source Software.
|
422
|
+
OSI Certified is a certification mark of the Open Source Initiative.*</p>
|
403
423
|
</body>
|
404
424
|
</html>
|