-
Book Overview & Buying
-
Table Of Contents
Multimedia Programming with Pure Data
By :
Before exploring more advanced properties of the window, we start working on 2D graphics. The GEM library comes with a number of 2D primitives such as circle, curve, polygon, rectangle, square, and triangle.
Create a new Pd patch. Save it to your folder with name gem002.pd. Clear the console window by choosing Edit | Clear. Create a default graphics window with the gemwin object, create message, destroy message, and the toggle render box as shown in the last section.
We will first create a 2D square in this exercise. Put an object named square onto the patch window. If you switch to the Run mode and create the window to start rendering, nothing happens. In order to render the square object, we need one more GEM object, gemhead:

The gemhead object defines the path that GEM library uses to produce the graphics. When the GEM window starts to render any graphics, it searches all the gemhead objects in the patch. Starting from each gemhead object, it goes down the connection...
Change the font size
Change margin width
Change background colour