Book description
An Artist's Guide to Programming teaches computer programming with the aid of 100 example programs, each of which integrates graphical or sound output. The Processing-language-based examples range from drawing a circle and animating bouncing balls to 3D graphics, audio visualization, and interactive games.
Readers learn core programming concepts like conditions, loops, arrays, strings and functions, as well as how to use Processing to draw lines, shapes, and 3D objects. They’ll learn key computer graphics concepts like manipulating images, animating text, mapping textures onto objects, and working with video. Advanced examples include sound effects and audio visualization, network communication, 3D geometry and animation, simulations of snow and smoke, predator-prey populations, and interactive games.
Table of contents
- Title Page
- Copyright
- About the Author
- Author’s Note
- Introduction
-
Part 1: The Fundamentals of Drawing
- Sketch 1: A Circle
- Sketch 2: Colors
- Sketch 3: if Statements—Changing Colors Conditionally
- Sketch 4: Loops—Drawing 20 Circles
- Sketch 5: Lines
- Sketch 6: Arrays—Drawing Many Circles
- Sketch 7: Lines with Rubber Banding
- Sketch 8: Random Circles
- Sketch 9: A Rectangle
- Sketch 10: Triangles and Motion
- Sketch 11: Displaying Text
- Sketch 12: Manipulating Text Strings
-
Part 2: Working with Preexisting Images
- Sketch 13: Loading and Displaying an Image
- Sketch 14: Images—Theory and Practice
- Sketch 15: Manipulating Images I—Aspect Ratio
- Sketch 16: Manipulating Images II—Cropping
- Sketch 17: Manipulating Images III—Magnifier
- Sketch 18: Rotation
- Sketch 19: Rotating About Any Point—Translation
- Sketch 20: Rotating an Image
- Sketch 21: Getting the Value of a Pixel
- Sketch 22: Setting and Changing the Values of Pixels
- Sketch 23: Changing the Values of Pixels—Thresholding
- Sketch 24: User-Defined Functions
- Sketch 25: Elements of Programming Style
- Sketch 26: Duplicating Images—More Functions
- Part 3: 2D Graphics and Animation
- Part 4: Working with Text and Files
- Part 5: Creating User Interfaces and Widgets
- Part 6: Network Communications
-
Part 7: 3D Graphics and Animation
- Sketch 51: Basic 3D Objects
- Sketch 52: 3D Geometry—Viewpoints, Projections
- Sketch 53: 3D Illumination
- Sketch 54: Bouncing a Ball in 3D
- Sketch 55: Constructing 3D Objects Using Planes
- Sketch 56: Texture Mapping
- Sketch 57: Billboards—Simulating a Tree
- Sketch 58: Moving the Viewpoint in 3D
- Sketch 59: Spotlights
- Sketch 60: A Driving Simulation
-
Part 8: Advanced Graphics and Animation
- Sketch 61: Layering
- Sketch 62: Seeing the World Through a Window
- Sketch 63: The PShape Object—A Rotating Planet
- Sketch 64: Splines—Drawing Curves
- Sketch 65: A Driving Simulation with Waypoints
- Sketch 66: Many Small Objects—A Snowstorm
- Sketch 67: Particle Graphics—Smoke
- Sketch 68: Saving a State—A Spinning Propeller
- Sketch 69: L-Systems—Drawing Plants
- Sketch 70: Warping an Image
-
Part 9: Working with Sound
- Sketch 71: Playing a Sound File
- Sketch 72: Displaying a Sound’s Volume
- Sketch 73: Bouncing a Ball with Sound Effects
- Sketch 74: Mixing Two Sounds
- Sketch 75: Displaying Audio Waveforms
- Sketch 76: Controlling a Graphic with Sound
- Sketch 77: Positional Sound
- Sketch 78: Synthetic Sounds
- Sketch 79: Recording and Saving Sound
- Part 10: Working with Video
- Part 11: Measuring and Simulating Time
-
Part 12: Creating Simulations and Games
- Sketch 89: Predator-Prey Simulation
- Sketch 90: Flocking Behavior
- Sketch 91: Simulating the Aurora
- Sketch 92: A Dynamic Advertisement
- Sketch 93: Nim
- Sketch 94: Pathfinding
- Sketch 95: Metaballs—A Lava Lamp
- Sketch 96: A Robot Arm
- Sketch 97: Lightning
- Sketch 98: The Computer Game Breakout
- Sketch 99: Midpoint Displacement—Simulating Terrain
- Part 13: Making Your Work Public
Product information
- Title: An Artist's Guide to Programming
- Author(s):
- Release date: May 2022
- Publisher(s): No Starch Press
- ISBN: 9781718501645
You might also like
book
Design It!
Don't engineer by coincidence-design it like you mean it! Filled with practical techniques, Design It! is …
audiobook
The Design of Everyday Things
First, businesses discovered quality as a key competitive edge; next came science. Now, Donald A. Norman, …
book
The Secret Life of Programs
Computer programming is not abstract and programs run on a machine. Knowing how computers work and …
book
The Programmer's Brain
Your brain responds in a predictable way when it encounters new or difficult tasks. This unique …