The lab specifications are tentative at this point and will be finalized as the quarter progresses. The 'Not finalized' label will be changed to 'finalized' when the lab has been finalized. The due date will either be posted here or announced in the class.
This quarter, the labs will be demoed to the grader, not electronically submitted.
You will not be given sample labs; you are expected to design and implement your own lab.
You will have to demo your lab to the grader in order to have it evaluated.
Labs count for 35% of the final grade.
Contents:
Implement the following
curve generation procedures in your Lab 1. Allow the user to select one of
the techniques and generate a new wire from an existing wire by selecting
the number of points (on a slider) and a curve generation technique (radio
buttons.) Your initial
set of points may be input as a set of ordered points in plane.
Allow the user to generate a curve, go back and edit a point on the
control wire, and then regenerate a new curve replacing the original curve.
Extra credit will be assigned for doing the more involved items or more of the simpler ones. (Extra credit percentage is the maximum given and usually requires supportive interface.)
Write a program that can generate basic
geometric models. Your program should provide reasonable user interaction.
Using
Lab1 generate surfaces implementing the
following techniques:
surfaces of revolution
The user should draw an open or closed curve. The curve is drawn relative to an axis in the display image; you can use either a default axis or a user-specified one). The user should be able to set the number of slices. check for overlap of contour and axis of revolution and issue a warning to the user.
extrusion
The user should draw one open or closed wire (curve) and be able to set the z-depth of the extrusion. the wire should be considered to lie in the x-y plane and the extrusion to occur in the z direction. Optional extension: you can generalize this to include a user-specified extrusion direction. Optional extension: you can generate multiple extruded wires.
sweep operators
User input of an open or closed generator wire and an open or closed trajectory wire. Consider the generator wire to lie in the x-y plane. Consider the trajectory wire to lie in the y-z plane.
output ASCII vertex-face file
Use counterclockwise face definitions and use the following format:
#-of-vertices=n #-of-faces=m
x1y1z1
x2y2z2
...
xnynzn
#-of-vertices-in-first-face=k1v11v12...
v1k1
#-of-vertices-in-second-face=k2v21v22...
v2k2
....
#-of-vertices-in-mth-face=kmvm1vm2...
vmkm
For example, a cube looks like:
8 6
-1 1 1
1 1 1
1 -1 1
-1 -1 1
-1 1 -1
1 1 -1
1 -1 -1
-1 -1 -1
4 3 2 1 0
4 4 5 6 7
4 5 4 0 1
4 6 5 1 2
4 7 6 2 3
4 4 7 3 0
You are encouraged to use this C++ mesh code mesh.cpp mesh.h for constructing your solids.
· This code will maintain all of the connectivity/adjacency information that is required when doing subdivision surfaces in Lab 3.
· This code will NOT compute any solids or subdivision, Bezier, or b-spline surfaces - you will still need to compute the actual solids and surfaces with your own code.
· The basic way to construct a mesh (e.g. when building a solid in Lab 2):
Mesh m
For each facet in solid
Add facet to m
end for
· After constructing the mesh, you will be able to access the vertex-facet, vertex-edge, etc connectivity that is needed for subdivision surfaces
· For more information, visit here
Extra Credit:
Generate control polyhedron using Lab 2. You should generate surfaces
with boundary and without boundary.
Do the following surface types:
1. (7%)
You must generate .det objects as final output by polygonizing the surfaces using equally spaced u,v coordinates.
2. (8%) (subdivision surfaces. Use some
examples where the initial control polyhedron is not a regular rectangular
mesh)
You will be graded on the design of the user interface and the generation power of your program.
To receive top grade you will have to enhance the functionality and user
interface in a significant manner other than the
basic ones. For example, you can choose to do:
You are encouraged to use mesh.cpp and mesh.h for constructing your solids.
· This code will maintain all of the connectivity/adjacency information that is required when doing subdivision surfaces in Lab 3.
· This code will NOT compute any solids or subdivision, Bezier, or b-spline surfaces - you will still need to compute the actual solids and surfaces with your own code.
· The basic way to construct a mesh (e.g. when building a solid in Lab 2 or during a subdivision iteration in Lab 3):
Mesh m
for each facet in solid
Add facet to m
end for
· After constructing the mesh, you will be able to access the vertex-facet, vertex-edge, etc connectivity that is needed for subdivision surfaces
You can choose to do something else that interests you as long as the complexity is comparable to the basic lab and you clear it with me first. Such as:
I would like examples of interesting objects that I can put up on the class web site.
Last updated