This assignment is due by Thursday, October 13, 2016 by 11:59pm.
With your pet now loyal to you, you continue towards the city. The city lies at the base of a large mountain whose peak is obstructed by clouds. As you get closer, you think you see lightning bolts coming down from above.
After weeks of wandering and traveling, you finally have arrived in the city. This city is massive, much larger than the small village you
grew up in. People are everywhere and there is a constant murmer of people haggling for goods and trying to attract those just passing
by.
As you navigate the streets and explore different areas, you notice that the city is divided into smaller neighborhoods. You had noticed
from afar that the city seemed to be segregated since the architecture of the buildings were grouped into similar areas. As you cross the
street into a new neighborhood, all the ornamentation changes color and the store signs bear similar heraldry.
The streets all seem to be fanning out from a central point like spokes on a wheel and you realize the city is surrounded by a large circular wall. Each wedge
of the city makes up a different neighborhood, has their own color, and their own crest. At the center of the wheel, is a large gothic building.
You make your way down the street towards the building.
You quickly count the spires and realize there are twenty spires of equal height. As you walk the square surrounding the building, you notice there
are also twenty neighborhoods. There must be some connection.
You ascend the large stairs and look at the archway above the massive doors. Etched into the stone for all to see are the words:
GUILD HALL
You swing the door open and cautiously go inside. You pass into a circular entrance chamber with twenty two doors and above each door is a large shield. You recognize twenty of the crests on
the shields matching the neighborhoods you passed through. The other two shields, opposite the main door you entered from, are unpainted
with a shadow. On one the shadow is passing through a flame and the other the shadow is passing through a sun. In the center of the room is a raised platform, a tall robed woman sits atop, and beckons you to approach.
Her robe contains all the colors of each shield hung around her.
"Welcome, we have been expecting you. A caravan passed through earlier and made mention of your travels. You are
not the first to arrive and we have been waiting for you to begin. We must not waste any more time. Please, follow me and we
shall begin."
Before you have a chance to ask any questions, she turns and begins heading for the unpainted door. She reaches the door and realizes
you have not moved from where she first spoke to you. Again she beckons for you to follow sensing your hesitation. Her voice sounded familiar, but you have never seen her before or been in this city until now. In your mind
you hear
Go ahead. She will help you. I have been here before and seen many others gather here. If you are to
be the hero you want to be, you must get stronger, gain more knowledge, and rely on others for help. Go.
You recognize the voice instantly of your pet you had rescued outside the city. Before you entered the building, you placed
it into your pocket for safe keeping. Realizing your pet is right, you approach the door. A scroll hangs on the door stating
Lasciate ogni speranza, voi ch'entrate.
Part I - Training Days: Form Your Guild
You follow her through the door and find a crowd waiting. Quickly scanning the room, there are nearly thirty other adventurers gathered - and they were all on the boat with you! Why are they here too? You find
the last remaining open seat and wait for the woman to speak as she has already made her way to the podium.
"We have asked all of you here as you all have the same quest - to become a Hero and protect Mount Olympus. An evil is gathering in the lands.
Alone, none of you will ever be strong enough to defeat this great evil. But together, perhaps you can find a way to protect our great city and reclaim Olympus. You all have rebuilt your Temples and others have been gathering while you traveled.
Each neighborhood in our great city comprises a different guild, loyal to their faction and diety. As soon as you entered the town, our scouts
were following you and learning your skills. To join a guild, you must pass their training tests. If you pass all of their tests, then
they will grant you admission to their guild. Here, take one of these flyers and start right away. The guilds will be departing
shortly and you must go with one of them, if you pass their tests."
Realizing she is the woman that gave you the cloth, you quickly take one of the flyers as they go by and begin reading:
To gain entry to the guild, you must pass each of our tests. There are four in all, each testing a different skill
you have learned in your travels. You must choose some of your fellow adventurers to join you in your guild. Our city has nineteen guilds and each
have enrollment slots available. Eighteen guilds can accept three Heroes while the nineteenth can only accept two Heros.
The first part of your midterm project is to assemble into teams to petition entry into a guild. The guilds are extremely loyal, so you must make sure all members of your guild worship the same dieties (Gods or Titans). Our class will have
eighteen teams of three and one team of two. If you wish to be the team of two, you must contact the instructor for approval AND you will be a mixed guild (1 God and 1 Titan) - DO NOT ASSUME you are the team of two. With
only two team members, there will be more work per team member to be completed. Once you have formed your team, all members of your
team must email the following to the instructor by WEDNESDAY, SEPTEMBER 28 11:59PM:
- The Members of Your Guild
- Your Guild Name
- Your Diety
For the midterm project, you will create a track (think of a roller coaster track - try to mimic this type of layout. Hills/drops, turns, etc.) for your Heroes to train on. Two of your Heroes will be automatically racing along the track
while the third Hero is free to explore the world you create. Read on to understand how everything fits together.
The actual midterm project is comprised of several smaller parts, each focusing on one of the topics covered to this point. The requirements
for each section are described below.
Section A - Bézier Curves & Surfaces
Previously, we used a grid in the XZ-plane to denote our world. Now, you are to use a Bézier Surface as your ground. This curved surface
will now have changes in elevation and be more interesting to move around than a flat grid. You will need to specify the 16 contol points
that make up your world (control point specification is described below in Section D). If you wish, you may use more
than one Bézier Surface to give more detail to your world (if you do use multiple surfaces, make sure they are C1 continuous at the mesh point).
There needs to be at least one Bézier Surface. Your Surface will be solid (i.e. made up of triangles or quads) so be sure to traverse
your parameters correctly.
Choose one of your Heroes to be the wanderer. This Hero will be controlled by the WASD keys and can walk
around your Surfaced world. Three key points for the Wandering Hero movement:
- As the elevation changes, the Wandering Hero should follow these elevation changes. Specifically, the Wandering Hero should follow
the curves of the Surface and always stay "on top" of the Surface.
- The Wandering Hero should follow the slope of the Surface. As the Wandering Hero changes direction and moves uphill/downhill, the Wandering
Hero should always be oriented along the normal to the Surface at that point.
- The Wandering Hero is confined to the surface, i.e. the Wandering Hero cannot move off of the Surface and bounds checking must be performed to ensure this.
The other two Heroes will be moving along Bézier Curves. You will design a track, similar to a roller coaster, that the other two Heroes will travel along.
The overall curve will be specified by a control file and must be closed (the start point and end point must be the same) and therefore C0 continuous.
The curve must also be C1 continuous, you should assume the points provided will be C1 continuous and you do not need to enforce these continuities
in program. The two Heroes will travel along the curve in different manners.
- One Hero will travel along the curve at equal parametric intervals. This means the Hero will advance dt units, where dt is step
along the parameter t.
- The other Hero will travel along the curve at equal arc length intervals. This means the Hero will advance dS(t) units, where dS(t) is
a step along the curve's length.
These two Heroes will move automatically as your timer function is called. They will also be traveling at different rates so you should see them pass
and catch up to each other. Each Hero should be oriented with the tangent of the curve, so they are always facing the direction of motion. Feel free to bank
your turns and add in a roll component, in addition to the pitch and yaw you will already be doing.
HINTS:
- You are encouraged to use your Heroes + Pets from Assignment4.
- You may want to make a generic virtual Hero class and then have each of your individual Heroes inherit from the parent Hero class. Put these into a HeroBase.h
and <Hero1>.h, <Hero2>.h, etc. files.
- You may want to use a display list for your terrain.
Section B - 3D Drawing & Animation
As before, your Heroes should be made of solid GLUT 3D Primitives or GLU Quadrics. Your Bézier Surface must be comprised of triangles
or quads. Your track must also be made of solid 3D objects. Beyond the ground, track, and Heroes, you must also have two different
objects scattered around your world. Their locations will be specified by the control file (again, see below).
Whenever any of your Heroes are moving, they must be animated while they move. The other two objects may be stationary or could be animated
(think a tree swaying in the wind for instance).
Section C - Cameras, Menus, Text, & Viewports
Users will be able to experience your program from one of many view points:
- From an arcball camera that can rotate around and follows a Hero
- From a free cam that can move about the scene
- From a first person camera attached to one of your Heroes
The user should be able to toggle between camera modes through a menu tied to the right mouse button. When the first person point-of-view camera is
turned on, it must appear as a picture-in-picture viewport within the window. Feel free to add additional cameras beyond the three listed (Sky cam,
Side-scrolling cam, Third Person cam, etc.) The camera class from Assignment4 should make this task significantly easier so you must have Camera.h
and Camera.cpp files.
In addition to be able to select which camera view to use, the user must be able to select which Hero to follow for the arcball cam or first person cam.
(This would be a perfect example of when to use submenus.)
If you would like to have the user watch two Heroes move along the track and control the Wandering Hero at the same time, consider creating a
split screen in your application so the user can interact with both views simultaneously.
You will use stroke text to display the Hero's name above their head as they move through the world. You may rotate the text so that it is
always facing the camera, but that is not required. You can have the name facing the same direction the Hero is facing and rotate the camera
around to be able to read the text.
Lastly, display somewhere to the window (typically in one of the corners) the current real-time Frames Per Second rate of your application. Frames
per second is exactly what it sounds like - the average number of frames rendered in one second. Be sure to check some of the tutorials linked on the
resource page if you are having trouble doing the calculation. You should use raster text as this will mimic a HUD.
Section D - File Format
The format of the World File you will read as input is up to you to define. In your file format, a designer must be able to
specify the location of control points, as well as the location and type of objects to be placed in your scene. An example format
might look like:
<number of Bézier Surfaces for ground> |
<sixteen control points for each surface> |
... |
<number of control points for Bézier Curve track> |
<control point x> <control point y> <control point z> |
... |
<number of objects> |
<object type> <object x, y, z> <object orientation x, y, z> <object size> |
... |
As stated above, your file format is up to you to define; however, you must be able to place at least two different kinds of objects,
which can be as simple as GLUT/GLU primitives, or more complicated, like a flag or a tree. You must describe your file format in your
README.txt file. To demonstrate that your program can read in World Spec Files correctly, include two example files
with your program. They must each utilize the full functionality of your file format (i.e. must each contain objects placed in the scene and
must each specify control points for a valid track). They should be visually different and a user can distinctly tell a new world
has been entered.
Section X - Extra Credit: OpenAL
For extra credit, you must use at least two separate sounds and at least one of them must be triggered to some activity (a user
stopping/starting your Wandering Hero, screams when the Heroes descend a steep slope, clicking on an object, etc.). The other sound(s)
may be ambient (birds chirping periodically) or tied to the environment (crowds of people nearby cheering, which can be heard growing louder
and softer as the Camera passes by). There's a lot of fun stuff that can be done with audio!
The Listener should be appropriately placed so we can hear the sounds based on where we are in the world. Likewise, the sources should
be appropriately placed. The sources can be static or dynamic depending on their application. Use Lab04 as reference for how to
properly set up your Listener and Sources.
Be sure to be good little programmers and allow the OpenAL code to fully work cross platform.
Section Y - Lights & Materials
In past assignments and labs, we used glColor3f() to specify the colors of our objects. From now on, we will use Lights & Materials
to denote the color properties of our objects.
For extra credit, there must be at least two lights in your scene. One of these lights must be animated or dynamic in some way - light position can be tied to
objects in the scene like headlights; a strobe light could change colors according to the Hero's speed; compare an outdoor scene to
one that is in a tunnel or one that is indoors like Space Mountain. There should be some amount of ambient light to be able to view your entire scene.
In addition, the objects in your scene must have appropriate material properties using at least two materials. If your track is
made of steel, then perhaps it should be quite shiny and reflective. Compard to a wooden track that has a very flat appearance. The color we
perceive an object to be is a combination of the lighting present and the material of the object. Experiment with different material properties
to acheive various effects. When drawing your objects (as specified in Section B), each component
should be colored using a Material. There must be at least two distinct materials used across your objects.
Remember that lights exist not only to communicate shape and depth but also contribute substantially to the feel of the scene! Experiment with
light positions, colors, and intensities to get a particular look and feel. Generally, you can get good results with slightly off-white lights
of complementary colors - check out COLOURlovers for some nifty color palettes, as well as
tools to help you choose sets of complementary colors.
You must create these Lights and Materials by specifying a Light class and Material class. They should be in a Light.h and Material.h file respectively.
Scanning the room, you instantly know who should join you in the guild. You pull them aside, speak for a few minutes, and it's agreed. You three shall begin preparations immediately. You aspire to join the most prestigious guild and strive to stand out amongst the other teams. You already have plans for when you return to your Temple of how your guild will be victorious against this growing force.
Part II - Website
Update the webpage that you submitted with A4 to include an entry for this assignment. As
usual, include a screenshot (or two) and a brief description of the program, intended to showcase what
your program does to people who are not familiar with the assignment.
Part III - Presentation
During lab on October 14, each Guild will present their world, Heroes, and track. During this time, the other Guilds will be critiquing your project (by filling out a scoresheet) and at the end everyone will vote
for their favorite Guild that they want to join.
Documentation & Submission
With this and all future assignments, you are expected to appropriately document your code. This includes
writing comments in your source code - remember that your comments should explain what a piece of code
is supposed to do and why; don't just re-write what the code says in plain English. Comments serve the dual
purpose of explaining your code to someone unfamiliar with it and assisting in debugging. If you know
what a piece of code is supposed to be doing, you can figure out where it's going awry more easily.
Proper documentation also means including a README.txt file with your submission. In your
submission folder, always include a file called README.txt that lists:
- Your Name / email
- Guild Name / Guild Members
- Assignment Number / Project Title
- A brief, high level description of what the program is / does
- A usage section, explaining how to run the program, which keys perform which actions, etc.
- Instructions on compiling your code
- Notes about bugs, implementation details, etc. if necessary
- NEW: A description of the file format that your program reads as input
- NEW: A rough distribution of responsibilities / contributions of each student
- How long did this assignment take you?
- How much did the lab help you for this assignment? 1-10 (1 - did not help at all, 10 - this was exactly the same as the lab)
- How fun was this assignment? 1-10 (1 - discontinue this assignment, 10 - I wish I had more time to make it even better)
Grading Rubric
Your submission will be graded according to the following rubric.
45% |
Track is closed (end point = start point), C0 continuous, & C1 continuous. (This doesn't need to be enforced in-program, as long as input control points specifiy C0 & C1 continuous curves.)
One Hero moves by arc-length parameterization and moves at a constant speed regardless of control point spacing. The other Hero moves by equal parameter steps.
Terrain is comprised of Bézier Surfaces. The Wandering Hero can be controlled and moves around the terrain properly. |
10% |
Heroes are animated & comprised of GLUT primitives / GLU quadrics. Scene is comprised of track and other scenic objects. |
25% |
Arcball camera follows Hero and rotates correctly; user can control rotation. Free camera is correctly implemented, can move around the scene, and is user-controllable. Camera is set up in Camera.h file. Camera from Hero's point of view works correctly; it is attached to the Hero and looks along the Hero's direction of movement.
First-person camera view is placed in a separate viewport. User can toggle between cameras through use of a menu attached to the right mouse button. User can toggle between Heroes to follow through menu as well.
Frames Per Second are rendered to screen. Hero name is displayed above Hero. |
5% |
File format is documented in the README.txt file. A third-party should be able to write a World Scene in your format based on your documentation. File format supports two different types of objects that can be placed in the scene and objects are correctly placed and rendered in the scene. Two non-trivially different example files are included. Each example fully utilizes the file format (i.e. places objects of each type). |
15% |
Submission includes source code, Makefile, and README.txt. Source code is well documented. Webpage named <HeroName>.html submitted and updated with screenshot from latest assignment. Submission compiles and executes in the lab machine environment. Presentation is of high quality and equal division of work is reported by team members. |
Experience Gained & Available Achievements
Assignments +150 XP
|
Web +150 XP
|
Banana Split
|
Can You Hear Me Now?
|
Viewmaster
|
Submission
Please update your Makefile so it produces an executable with the name guildWars. When you are completed with the Midterm Project,
zip together your source code, Makefile, README.txt, and www/ folder. Name the zip file, GuildName_MP.zip. Upload this file to
Blackboard under GuildWars.
Everyone is expected to submit a README.txt file - hold each other accountable for effort contributed. Each team member must also update their Hero's
webpage. In your README.txt, be sure to specify who submitted the full source code (you all may do so, but make sure at least one
of you does).
This assignment is due by Thursday, October 13, 2016 by 11:59pm.
|