User Tools

Site Tools


Sidebar

Programming Fundamentals with Processing

© 2012-2018 Mithat Konar.
All rights reserved.

Home

Part One

Part Two

Part Three

  • Action
  • Interaction
  • Bundling Stuff Up II

Misc and cruft

  • Needs a place
    • strings and string processing (Appendix?)
ch01-setting-up.html

This is an old revision of the document!


Setting Up

Installing Processing

Processing is available for all three major desktop operating systems: macOS, Windows, and Linux. To install Processing, go to the project's download page at https://processing.org/download/ and select the appropriate version for your computer.

There is more than one version for Windows and Linux! Make sure you get the right one for your computer.

On macOS, the archive is a standard app bundle, so just install it the way you normally install applications.

The Windows archive is FIXME TODO.

On Linux, decompress the archive, open a terminal, and run the install.sh script inside the archive.

Running Processing

Once you have successfully installed Processing, start the Integrated Development Environment (or IDE, the tool used to write and run you code) using the usual means you do so on your computer. Look for something called “Processing IDE.” FIXME TODO: Better instructions for launching.

The first time you run the Processing IDE, you should see something like the following.

The text entry area with the flashing cursor is where you will enter your Processing program statements. In that area, enter the following:

rect(20, 25, 20, 50);

Don't worry if you don't understand the text. Just type it in very carefully.

Once you have done that, click on the right-pointing arrow in the round circle (the Run button) in the toolbar. After a few moments you should see a new window.

To save your work, go back to the IDE, select File > Save or File > Save As… from the menu bar and give your program a name. By default, Processing saves your programs into a folder called “sketchbook.” (The exact location of this folder depends on your operating system. On macOS, look in FIXME and on Windows in FIXME.)

Processing uses the term sketch to identify what other languages typically call programs. The file extension for Processing sketches is .pde, When you create a new sketch, the Processing IDE will create a new folder the Processing program (i.e., sketch) inside your “sketchbook” folder. So, if you create a program named “KittenDance”, you will see a folder inside your sketchbook folder called “KittenDance”. And if you look inside the folder called “KittenDance”, you'll see a file called KittenDance.pde. That is your actual Processing program. To reopen the program, click on File > Open… in the IDE, navigate to the *.pde file, and select it.

You are now ready to start developing Processing programs.

ch01-setting-up.html.1503180161.txt.gz · Last modified: 2017/08/19 22:02 by mithat