Fractal Plants Project
ECS175: Computer Graphics

Due 10 pm Mon April 30

A lupine, by Karoline Hayes.

In this project we will draw two-dimensional fractal plants. Part of the project is implementing and using transformation matrices. The basic project described below is worth a B, if done well. A program which draws something interesting, attractive or realistic is worth an A.

You may work with a partner on this project.


Your plant should be defined using recursive functions, as described in the lecture notes. The "turtle" should be a 3x3 2D transformation matrix. To draw a leaf or other object with the position and orientation represented by the turtle matrix, you should load the matrix into the m_transform uniform matrix in the vertex program.

The plant should include at least leaves and stems, and its structure should include branching as well as rotation and translation.

Please construct the turtle matrix by defining your own 2D transformation matrices and multiplying them together as necessary. Do not use the glm functions to generate the rotation, scale or translation matrices. You may, if you want, use the glm matrix multiplication functions.

Getting started

Here is the code we looked at in class, that brings up an OpenGL window and draws a rotated leaf.