search for books and compare prices
Tables of Contents for Graphics Programming With Perl
Chapter/Section Title
Page #
Page Count
preface
xiii
About this book
xiii
Who should read this book?
xiv
Coding practices
xv
Source code downloads
xvi
author online
xvii
acknowledgments
xix
about the cover illustration
xxi
Part 1 Foundations
1
34
Overview of graphics
3
12
Perl and graphics
4
1
The bits and pieces in graphics programming
5
2
Color spaces and palettes
7
7
RGB
7
1
CMY and CMYK
8
1
HSV and HLS
9
3
YUV, YIQ and YCbCr
12
1
Grayscale
12
1
Color distance
13
1
Reducing the number of colors in an image
13
1
Summary
14
1
Overview of graphics file formats
15
12
Some graphics formats
16
4
GIF
17
1
JPEG, JFIF
18
1
PNG
18
1
MNG
19
1
SVG
19
1
TIFF
19
1
Finding the size and type of an image
20
4
Image::Size
20
1
Image::Magick
21
1
Do it yourself
22
2
More on file size and information
24
1
Conversion of graphics formats
24
2
Summary
26
1
Overview of tools and modules
27
8
CPAN
28
1
The tools
29
5
The Chart::* modules
29
1
Gnuplot
29
1
GD
29
1
GD::Graph, GIFgraph and Chart::PNGgraph
30
1
GD::Text
30
1
The Gimp
30
1
Image::Magick
30
1
Image::Size
31
1
Inline
31
1
OpenGL
32
1
PGPLOT
32
1
RenderMan
33
1
Term::Gnuplot
33
1
A note on module versions
34
1
Summary
34
1
Part 2 Creating graphics
35
138
Drawing
37
23
Drawing with GD
39
7
An example drawing
40
2
Filling objects
42
1
Drawing text with GD
43
1
GD's built-in fonts
44
1
TrueType fonts and GD
45
1
Drawing with Image::Magick
46
7
An example drawing
46
1
Anti-alias and fuzz
47
1
Drawing by combining images
48
2
Drawing with paths
50
1
Drawing text with Image::Magick
51
2
Combining GD and Image::Magick
53
2
Drawing with Term::Gnuplot
55
4
PostScript and SVG
59
1
Summary
59
1
Creating charts
60
30
GD::Graph and friends
62
12
Preparing your data sets for GD::Graph
63
2
Controlling the look of your chart
65
1
GD::Graph and fonts
65
1
Saving your chart co a file
66
2
Bar and area charts
68
2
Lines, Points and Linespoints charts
70
2
Mixed charts
72
2
The Chart distribution
74
2
Pareto charts
75
1
PGPLOT
76
9
PGPLOT devices
76
1
Example: A simple X-Y plot
77
4
Example: A contour plot
81
3
Example: Plotting a galaxy
84
1
Interfacing with gnuplot
85
4
Summary
89
1
Graphics and the Web
90
32
The Common Gateway Interface
91
1
HTTP and CGI
91
1
Suitable image formats
92
2
Web safe color palettes
92
2
CGI and dynamically generated graphics
94
2
Forms and encapsulated graphics
96
4
Image collections and thumbnailing
100
21
Thumbnails with Image::Magick
101
1
Thumbnails with GD
102
1
Contact sheets with Image::Magick's visual directory
103
1
Contact sheets with Image::Magick::Montage
104
1
An example application: A web photo album
105
2
Designing the data
107
14
Summary
121
1
Animations for the Web
122
16
Animation file formats
123
2
GIF
123
1
MNG
124
1
Macromedia Flash
124
1
SVG
125
1
GIF animations
125
1
Perl and animations
126
1
Repeatedly applying a filter
127
4
Example: making objects appear
127
2
Example: Zooming in on an object
129
2
Animated text
131
1
Animated charts
132
2
Animations with the Gimp
134
3
Summary
137
1
Resizing and combining images
138
15
Scaling and cropping an image
139
1
Image::Magick geometry specification
139
1
Cropping an image
140
1
Combining Images
140
11
Combining GD images
140
2
Combining Image::Magick images
142
3
Adding a watermark to an image
145
6
Summary
151
2
Three-dimensional graphics
153
20
OpenGL
154
10
OpenGL library functions in Perl
155
2
Capturing your OpenGL output
157
3
Example: a planetary system
160
4
OpenGL summary
164
1
RenderMan
164
8
How to use the module and the BMRT
165
1
The RenderMan language binding for Perl
166
1
Example: A rotating cube of cubes
167
5
Summary
172
1
Part 3 Special topics
173
66
Writing your own graphics modules
175
15
Interface design
176
10
Coordinate transformation
180
1
Choosing your drawing primitives
181
1
Implementing the interface
182
4
An OO implementation of a clock
186
2
Summary
188
2
Controlling text placement
190
20
Determining text size
191
3
Text sizes in GD
191
1
Text sizes in Image::Magick
192
2
Aligning text in graphics
194
3
Aligning text with GD
194
2
Aligning text with Image::Magick
196
1
Wrapping text
197
12
The GD::Text modules
207
2
Summary
209
1
Manipulating pixels and transparency
210
29
GD and pixels
211
2
Example: rotating RGB values
211
1
Removing duplicate color palette entries
212
1
Image::Magick and pixels
213
2
Rotating RGB values
214
1
Convolution
215
14
Convolution with Image::Magick
217
7
Using Image::Magick's Convolve() method
224
2
Convolution with PDL
226
3
Alpha channels and transparency
229
4
Transparency and the GD module
229
1
Transparency and Image::Magick
230
3
How to view partially transparent images
233
1
Fast manipulation of image pixels
233
5
Using Inline::C
234
4
Summary
238
1
Part 4 Appendices
239
54
A Image::Magick introduction & reference
241
43
B Color space conversion algorithms
284
4
C Module code
288
5
references
293
2
index
295
<