2) Max Concepts

Due date: Wednesday January 31 before class.


The following exercises will require you to make use of the information from the tutorials we reviewed and the concepts discussed in class.

Create a single patch file (ONE) containing all your solutions. Use comments to label the sections of your patch (e.g. "part 1", "part 2b", etc.) You may also encapsulate the different answers in sub-patches if you like.

  1. Building and sending messages:

    1. Button, clear, and draw in LCD: Create a patch from scratch in which, when one Button object is clicked, two messages are sent to an LCD object: the first tells the LCD to clear itself, and the second tells the LCD to draw a blue rectangle (look in the LCD help patch, "basic_shapes" subpatch, to review proper message syntax.)

    2. Number boxes with pak: Make a patch which draws a blue rectangle in an LCD object, but this time use four number boxes to allow the user to interactively set the positions of the rectangle's sides. Use a "pak" object to create the rectangle message. You will need to clear the LCD before drawing each new rectangle.

  2. Slider values:

    1. Circle: For this part, start drawing a circle instead of a rectangle.

    2. Sliders and value remapping: Create one slider and use it to move your circle left and right, and other slider to move the circle up and down.

    3. Diameter: Add a third slider to adjust the diameter of the circle. Make sure the center of the circle stays put when its size changes. This will require that you make the circle wider AND taller by calculating four new numbers whenever the slider outputs a new desired circle size.

  3. Sub-patches and Iteration:

    1. Patcher and Encapsulation: Make a copy of your circle drawing patch. Manually or using the "encapsulate" menu option, move the body of your patch into a "patcher" object. Your sliders should send their messages into this subpatch, and drawing messages should come out and go into your LCD.

    2. Many Circles: Make a copy of the previous subpatch and use "Uzi" and "random" objects to draw 20 small circles at random positions and sizes in your LCD whenever a button is pushed. You'll need to modify your copy of the circle drawing sub-patch so that it doesn't clear the LCD after each circle is drawn. It also will need to wait until all of a circle's numbers are set before it sends out it's "paintoval" drawing message.

  4. Drawing:

    1. Consulting the three Max drawing tutorials ("Mouse", "Random", and "Procedural"), make a patch that has:

      • an animated interactive brush
      • a non-interactive animated brush
      • an evident relationship in how these two change
    2. Suggested properties to animate include the color, motion, shape, and/or size of the brush.

    3. Make it very clear (i.e. documented via comments) what parts of your patch were copied from the tutorials vs what you've added.