CSCI 4530/6530 Advanced Computer Graphics Spring 2014 

Home
Announcements
Syllabus
Grading
Calendar
Homework
Final Project

Homework 0: Transformations & OpenGL WarmupThe goal of this warmup assignment is to get comfortable with the programming environment you will be using for this class and familiarize yourself with a simple library that we will use for linear algebra. It's also an opportunity for a crash course in C++ and OpenGL (if you're not already familiar with them). This assignment is only worth 1/4 of the points of a regular homework assignment. It will not be rigorously graded, but you are expected to work through and submit the exercises. Please try to finish this assignment by the end of the first week of classes; however, there is no firm deadline for this assignment. Here are a couple tutorials you may want to check out:
The incidental goal is also to have fun with bizarre fractal objects. IFS are selfsimilar fractals: a subpart of the object is similar to the whole. The classic example of an IFS is Barnsley's fern, where each subpart of the fern is exactly the same as the whole fern. IFS are described by a set of affine transformations (rotations, translations, scale, skew, etc.) These transformations capture the selfsimilarity of the object. IFS can be defined in any dimension, and we will play with both twodimensional and threedimensional ones. Formally, an IFS is defined by n affine transformations. Each transformation f_{i} must be contractive: The distance between points must be reduced. An attractor of the IFS is the object such that A = U f_{i} (A). A is unchanged by the set of transformations: It is a fixed point. We can render an IFS by iterating the transform on random input points from the unit square. We approximate the fixed point by applying the transformation many times. The algorithm is as follows: for "lots" of random points (x_{0}, y_{0}) for k=0 to num_iters_{ } pick a random transform f_{i} (x_{k+1}, y_{k+1}) = f_{i}(x_{k}, y_{k}) display a dot at (x_{k}, y_{k}) To minimize the number of points necessary to make an image of reasonable quality, probabilities are assigned to each transformation, instead of choosing a transformation with uniform probability. Tasks
Possible Extensions
Extra credit is available for creative extensions. Examples include:
Include a short paragraph in your README.txt file describing your extension(s). Hints
Provided Files: provided_files.zipNOTE: If you are using GLUT instead of GLFW/GLEW/GLM, see last year's page & last year's code.
Sample Results
./ifs input ../src/sierpinski_triangle.txt points 10000 iters 0 size 200 ./ifs input ../src/sierpinski_triangle.txt points 10000 iters 1 size 200 ./ifs input ../src/sierpinski_triangle.txt points 10000 iters 2 size 200 ./ifs input ../src/sierpinski_triangle.txt points 10000 iters 3 size 200 ./ifs input ../src/sierpinski_triangle.txt points 10000 iters 4 size 200 ./ifs input ../src/sierpinski_triangle.txt points 10000 iters 30 size 200
./ifs input ../src/fern.txt points 50000 iters 30 size 400
./ifs input ../src/giant_x.txt points 10000 size 400 iters 0 ./ifs input ../src/giant_x.txt points 10000 size 400 iters 1 ./ifs input ../src/giant_x.txt points 10000 size 400 iters 2 ./ifs input ../src/giant_x.txt points 10000 size 400 iters 3 ./ifs input ../src/giant_x.txt points 10000 size 400 iters 4 Now here's an example using the cubes argument. Each cube represents the bounding box of the cloud of random 3D points that are transformed in each iteration. There are a couple different ways to implement this rendering mode. ./ifs input ../src/giant_x.txt size 400 iters 0 cubes ./ifs input ../src/giant_x.txt size 400 iters 1 cubes ./ifs input ../src/giant_x.txt size 400 iters 2 cubes ./ifs input ../src/giant_x.txt size 400 iters 3 cubes ./ifs input ../src/giant_x.txt size 400 iters 4 cubes
Please read the homework information page again before submitting.
