Learning Processing -  Daniel Shiffman

Learning Processing (eBook)

A Beginner's Guide to Programming Images, Animation, and Interaction
eBook Download: PDF | EPUB
2009 | 1. Auflage
472 Seiten
Elsevier Science (Verlag)
978-0-08-092006-1 (ISBN)
Systemvoraussetzungen
Systemvoraussetzungen
40,95 inkl. MwSt
  • Download sofort lieferbar
  • Zahlungsarten anzeigen
This book teaches you the basic building blocks of programming needed to create cutting-edge graphics applications including interactive art, live video processing, and data visualization.

A unique lab-style manual, the book gives graphic and web designers, artists, and illustrators of all stripes a jumpstart on working with the Processing programming environment by providing instruction on the basic principles of the language, followed by careful explanations of select advanced techniques.

Within these pages, ITP (Tisch School of the Arts, New York University) professor Daniel Shiffman demonstrates the fundamentals of programming that will expand your understanding of what is possible in the world of computer graphics. By travelling beyond the confines of proprietary software, you will be empowered to create your own custom design tools.

* A friendly start-up guide to Processing, the visual artist's free, open-source alternative to expensive software and daunting programming languages.

* No previous experience required-this book is for the true programming beginner!

* Step-by-step examples, thorough explanations, hands-on exercises, and simple code samples support your learning curve. Source code and supplemental tutorials are also available through an online companion site.
The free, open-source Processing programming language environment was created at MIT for people who want to develop images, animation, and sound. Based on the ubiquitous Java, it provides an alternative to daunting languages and expensive proprietary software. This book gives graphic designers, artists and illustrators of all stripes a jump start to working with processing by providing detailed information on the basic principles of programming with the language, followed by careful, step-by-step explanations of select advanced techniques.The author teaches computer graphics at NYU's Tisch School of the Arts, and his book has been developed with a supportive learning experience at its core. From algorithms and data mining to rendering and debugging, it teaches object-oriented programming from the ground up within the fascinating context of interactive visual media.Previously announced as "e;Pixels, Patterns, and Processing"e; A guided journey from the very basics of computer programming through to creating custom interactive 3D graphics Step-by-step examples, approachable language, exercises, and LOTS of sample code support the reader's learning curve Includes lessons on how to program live video, animated images and interactive sound

Front Cover 1
Learning Processing 4
Copyright Page 5
Contents 6
Acknowledgments 8
Introduction 10
What is this book? 10
Who is this book for? 10
What is Processing ? 10
But shouldn’t I be Learning __________ ? 12
Write in this book! 13
How should I read this book? 13
Is this a textbook? 14
Will this be on the test? 15
Do you have a web site? 15
Take It One Step at a Time 16
Algorithms 17
Lesson 1: The Beginning 20
Chapter 1: Pixels 22
1.1 Graph Paper 22
1.2 Simple Shapes 24
1.3 Grayscale Color 28
1.4 RGB Color 31
1.5 Color Transparency 33
1.6 Custom Color Ranges 33
Chapter 2: Processing 36
2.1 Processing to the Rescue 36
2.2 How do I get Processing? 37
2.3 The Processing Application 37
2.4 The Sketchbook 38
2.5 Coding in Processing 39
2.6 Errors 41
2.7 The Processing Reference 43
2.8 The "Play" Button 44
2.9 Your First Sketch 45
2.10 Publishing Your Program 47
Chapter 3: Interaction 50
3.1 Go with the flow 50
3.2 Our Good Friends, setup() and draw() 51
3.3 Variation with the Mouse 54
3.4 Mouse Clicks and Key Presses 58
Lesson One Project 61
Lesson 2: Everything You Need to Know 62
Chapter 4: Variables 64
4.1 What is a Variable? 64
4.2 Variable Declaration and Initialization 66
4.3 Using a Variable 68
4.4 Many Variables 71
4.5 System Variables 72
4.6 Random: Variety is the spice of life 74
4.7 Variable Zoog 76
Chapter 5: Conditionals 78
5.1 Boolean Expressions 78
5.2 Conditionals: If, Else, Else If 79
5.3 Conditionals in a Sketch 82
5.4 Logical Operators 85
5.5 Multiple Rollovers 88
5.6 Boolean Variables 89
5.7 A Bouncing Ball 92
5.8 Physics 101 97
Chapter 6: Loops 100
6.1 What is iteration? I mean, what is iteration? Seriously, what is iteration? 100
6.2 "WHILE" Loop, the Only Loop You Really Need 102
6.3 "Exit" Conditions 105
6.4 "FOR" Loop 106
6.5 Local vs. Global Variables (AKA "Variable Scope") 109
6.6 Loop Inside the Main Loop 112
6.7 Zoog grows arms 114
Lesson Two Project 117
Lesson 3: Organization 118
Chapter 7: Functions 120
7.1 Break It Down 120
7.2 "User Defined" Functions 122
7.3 Defining a Function 122
7.4 Simple Modularity 123
7.5 Arguments 126
7.6 Passing a Copy 131
7.7 Return Type 133
7.8 Zoog Reorganization 136
Chapter 8: Objects 140
8.1 I'm down with OOP 140
8.2 Using an Object 141
8.3 Writing the Cookie Cutter 143
8.4 Using an Object: The Details 145
8.5 Putting It Together with a Tab 146
8.6 Constructor Arguments 149
8.7 Objects are data types too! 153
8.8 Object-Oriented Zoog 153
Lesson Three Project 156
Lesson 4: More of the Same 158
Chapter 9: Arrays 160
9.1 Arrays, why do we care? 160
9.2 What is an array? 163
9.3 Declaring and Creating an Array 164
9.4 Initializing an Array 166
9.5 Array Operations 167
9.6 Simple Array Example: The Snake 169
9.7 Arrays of Objects 172
9.8 Interactive Objects 174
9.9 Processing's Array Functions 177
9.10 One Thousand and One Zoogs 179
Lesson Four Project 181
Lesson 5: Putting It All Together 182
Chapter 10: Algorithms 184
10.1 Where have we been? Where are we going? 184
10.2 Algorithm: Dance to the beat of your own drum 185
10.3 From Idea to Parts 186
10.4 Part 1: The Catcher 187
10.5 Part 2: Intersection 189
10.6 Part 3: The Timer 194
10.7 Part 4: Raindrops 197
10.8 Integration: Puttin' on the Ritz 201
10.9 Getting Ready for Act II 207
Lesson Five Project 209
Chapter 11: Debugging 210
11.1 Tip #1: Take a break 210
11.2 Tip #2: Get another human being involved 210
11.3 Tip #3: Simplify 211
11.4 Tip #4: println() is your friend 212
Chapter 12: Libraries 214
12.1 Libraries 214
12.2 Built-in Libraries 215
12.3 Contributed Libraries 215
Lesson 6: The World Revolves Around You 218
Chapter 13: Mathematics 220
13.1 Mathematics and Programming 220
13.2 Modulus 221
13.3 Random Numbers 222
13.4 Probability Review 223
13.5 Event Probability in Code 224
13.6 Perlin Noise 226
13.7 Angles 229
13.8 Trigonometry 231
13.9 Oscillation 233
13.10 Recursion 235
13.11 Two-Dimensional Arrays 239
Chapter 14: Translation and Rotation (in 3D!) 246
14.1 The Z-Axis 246
14.2 P3D vs. OPENGL 251
14.3 Vertex Shapes 252
14.4 Custom 3D Shapes 254
14.5 Simple Rotation 256
14.6 Rotation Around Different Axes 258
14.7 Scale 261
14.8 The Matrix: Pushing and Popping 261
14.9 A Processing Solar System 268
Lesson Six Project 271
Lesson 7: Pixels Under a Microscope 272
Chapter 15: Images 274
15.1 Getting Started with Images 274
15.2 Animation with an Image 276
15.3 My Very First Image Processing Filter 278
15.4 An Array of Images 279
15.5 Pixels, Pixels, and More Pixels 281
15.6 Intro to Image Processing 284
15.7 Our Second Image Processing Filter, Making Our Own Tint() 285
15.8 Writing to Another PImage Object's Pixels 286
15.9 Level II: Pixel Group Processing 288
15.10 Creative Visualization 291
Chapter 16: Video 294
16.1 Before Processing 294
16.2 Live Video 101 295
16.3 Recorded Video 300
16.4 Software Mirrors 302
16.5 Video as Sensor, Computer Vision 308
16.6 Background Removal 312
16.7 Motion Detection 315
16.8 Computer Vision Libraries 318
16.9 The Sandbox 319
Lesson Seven Project 320
Lesson 8: The Outside World 322
Chapter 17: Text 324
17.1 Where do Strings come from? 324
17.2 What is a String? 325
17.3 Displaying Text 328
17.4 Text Animation 330
17.5 Text Mosaic 333
17.6 Rotating Text 335
17.7 Display text character by character 337
Chapter 18: Data Input 344
18.1 Manipulating Strings 344
18.2 Splitting and Joining 345
18.3 Reading and Writing Text Files 348
18.4 Text Parsing 354
18.5 Text Analysis 359
18.6 Asynchronous Requests 360
18.7 Beginner XML 363
18.8 Using the Processing XML Library 368
18.9 The Yahoo API 371
18.10 Sandbox 373
Chapter 19: Data Streams 376
19.1 Synchronous vs. Asynchronous 376
19.2 Creating a Server 377
19.3 Creating a Client 380
19.4 Broadcasting 382
19.5 Multi-User Communication, Part 1: The Server 385
19.6 Multi-User Communication, Part 2: The Client 388
19.7 Multi-User Communication, Part 3: All Together Now 390
19.8 Serial Communication 391
19.9 Serial communication with handshaking 393
19.10 Serial Communication with Strings 395
Lesson Eight Project 397
Lesson 9: Making Noise 398
Chapter 20: Sound 400
20.1 Really Simple Sound 400
20.2 Getting Started with Sonia and Minim 401
20.3 Basic Sound Playback 402
20.4 A Bit Fancier Sound Playback 408
20.5 Live input 410
20.6 Sound Thresholding 412
Chapter 21: Exporting 416
21.1 Web Applets 416
21.2 Stand-Alone Applications 416
21.3 High-Resolution PDFs 418
21.4 Images/saveFrame() 421
21.5 MovieMaker 422
Lesson Nine Project 425
Lesson 10: Beyond Processing 426
Chapter 22: Advanced Object-Oriented Programming 428
22.1 Encapsulation 428
22.2 Inheritance 431
22.3 An Inheritance Example: SHAPES 434
22.4 Polymorphism 437
22.5 Overloading 440
Chapter 23: Java 442
23.1 Revealing the Wizard 442
23.2 If we did not have Processing, what would our code look like? 442
23.3 Exploring the Java API 444
23.4 Other Useful Java Classes: ArrayList 447
23.5 Other Useful Java Classes: Rectangle 451
23.6 Exception (Error) Handling 453
23.7 Java Outside of Processing 455
Appendix: Common Errors 458
Index 466
A 466
B 466
C 466
D 467
E 467
F 467
G 468
H 468
I 468
J 468
K 469
L 469
M 469
N 469
O 469
P 470
Q 470
R 470
S 470
T 471
U 472
V 472
W 472
X 472
Y 472
Z 472

Erscheint lt. Verlag 17.4.2009
Sprache englisch
Themenwelt Mathematik / Informatik Informatik Grafik / Design
Mathematik / Informatik Informatik Programmiersprachen / -werkzeuge
ISBN-10 0-08-092006-3 / 0080920063
ISBN-13 978-0-08-092006-1 / 9780080920061
Haben Sie eine Frage zum Produkt?
PDFPDF (Adobe DRM)
Größe: 9,4 MB

Kopierschutz: Adobe-DRM
Adobe-DRM ist ein Kopierschutz, der das eBook vor Mißbrauch schützen soll. Dabei wird das eBook bereits beim Download auf Ihre persönliche Adobe-ID autorisiert. Lesen können Sie das eBook dann nur auf den Geräten, welche ebenfalls auf Ihre Adobe-ID registriert sind.
Details zum Adobe-DRM

Dateiformat: PDF (Portable Document Format)
Mit einem festen Seiten­layout eignet sich die PDF besonders für Fach­bücher mit Spalten, Tabellen und Abbild­ungen. Eine PDF kann auf fast allen Geräten ange­zeigt werden, ist aber für kleine Displays (Smart­phone, eReader) nur einge­schränkt geeignet.

Systemvoraussetzungen:
PC/Mac: Mit einem PC oder Mac können Sie dieses eBook lesen. Sie benötigen eine Adobe-ID und die Software Adobe Digital Editions (kostenlos). Von der Benutzung der OverDrive Media Console raten wir Ihnen ab. Erfahrungsgemäß treten hier gehäuft Probleme mit dem Adobe DRM auf.
eReader: Dieses eBook kann mit (fast) allen eBook-Readern gelesen werden. Mit dem amazon-Kindle ist es aber nicht kompatibel.
Smartphone/Tablet: Egal ob Apple oder Android, dieses eBook können Sie lesen. Sie benötigen eine Adobe-ID sowie eine kostenlose App.
Geräteliste und zusätzliche Hinweise

Zusätzliches Feature: Online Lesen
Dieses eBook können Sie zusätzlich zum Download auch online im Webbrowser lesen.

Buying eBooks from abroad
For tax law reasons we can sell eBooks just within Germany and Switzerland. Regrettably we cannot fulfill eBook-orders from other countries.

EPUBEPUB (Adobe DRM)
Größe: 7,6 MB

Kopierschutz: Adobe-DRM
Adobe-DRM ist ein Kopierschutz, der das eBook vor Mißbrauch schützen soll. Dabei wird das eBook bereits beim Download auf Ihre persönliche Adobe-ID autorisiert. Lesen können Sie das eBook dann nur auf den Geräten, welche ebenfalls auf Ihre Adobe-ID registriert sind.
Details zum Adobe-DRM

Dateiformat: EPUB (Electronic Publication)
EPUB ist ein offener Standard für eBooks und eignet sich besonders zur Darstellung von Belle­tristik und Sach­büchern. Der Fließ­text wird dynamisch an die Display- und Schrift­größe ange­passt. Auch für mobile Lese­geräte ist EPUB daher gut geeignet.

Systemvoraussetzungen:
PC/Mac: Mit einem PC oder Mac können Sie dieses eBook lesen. Sie benötigen eine Adobe-ID und die Software Adobe Digital Editions (kostenlos). Von der Benutzung der OverDrive Media Console raten wir Ihnen ab. Erfahrungsgemäß treten hier gehäuft Probleme mit dem Adobe DRM auf.
eReader: Dieses eBook kann mit (fast) allen eBook-Readern gelesen werden. Mit dem amazon-Kindle ist es aber nicht kompatibel.
Smartphone/Tablet: Egal ob Apple oder Android, dieses eBook können Sie lesen. Sie benötigen eine Adobe-ID sowie eine kostenlose App.
Geräteliste und zusätzliche Hinweise

Zusätzliches Feature: Online Lesen
Dieses eBook können Sie zusätzlich zum Download auch online im Webbrowser lesen.

Buying eBooks from abroad
For tax law reasons we can sell eBooks just within Germany and Switzerland. Regrettably we cannot fulfill eBook-orders from other countries.

Mehr entdecken
aus dem Bereich
Das umfassende Handbuch

von Christian Denzler

eBook Download (2023)
Rheinwerk Design (Verlag)
44,90
Schritt für Schritt zu Vektorkunst, Illustration und Screendesign

von Anke Goldbach

eBook Download (2023)
Rheinwerk Design (Verlag)
39,90
Das umfassende Handbuch

von Jürgen Wolf

eBook Download (2024)
Rheinwerk Fotografie (Verlag)
49,90