Page 6: Exercise 1: Quadcopter / Multi-Rotor

CS559 Spring 2023 Sample Solution

You have made a quadcopter in 2D on a previous assignment. We’ll do the same thing again, with a few twists.

Summary: In 07-06-01.js ( 07-06-01.html) turn the flying donut into a quadcopter/aircraft (with spinning rotors/propellers).

First, since this is 3D, we won’t just see the vehicle from above, so you have a little more freedom in what you make. It needs to have multiple (spinning) propellers, but it could be a traditional helicopter (with a vertical rotor in the tail) or even a multi-engined propeller airplane.

Second, in addition to the aircraft, you need to have a “radar dish” on the ground that always points towards the aircraft. This object should stay in the same place on the ground, but rotate so that it is always pointing towards the aircraft (tracking it). As the aircraft moves, the radar rotates. It doesn’t have to be a radar dish (you can be creative - it could be a telescope that looks at the aircraft, or …), but it does have to have an obvious “top” that always points towards the aircraft.

The goal of the assignment is to have you make a hierarchical object (aircraft with propellers) that flies around in 3D, and be able to point one object at the other. Other bells and whistles are nice (and can earn advanced points).

Some requirements:

  1. The aircraft can be simple in shape, but it must have an obvious front that faces forward when flying.
  2. The propellers can be simple (a thin box can work), but they must have an obvious center that they spin around, and they must spin as the aircraft flies.
  3. Your scene must have a ground plane.
  4. Your scene must have at least one aircraft that flies in a circle. You can have the other aircraft fly in more complicated ways (see advanced points).
  5. You should have at least two aircraft flying. Both with spinning propellers. It is OK if the two are the same, but you get advanced points if they are different.
  6. For each aircraft there should be an object on the ground that tracks it (points toward it as it flies around). These can be radar dishes, but they can have a different shape as well. Whatever they are, it should be obvious which direction they are pointing and that they “track” the aircraft (they continually point towards it as the aircraft flies around).

Note: it will be better to have one aircraft, with a functional radar dish, than two aircraft and no radar dish. Of course, it’s best to have two of each. Once you make one, it shouldn’t be too hard to add another.

The starter code provides some lighting, a simple ground plane, and OrbitCamera controls. You are welcome to improve the lighting, and make the ground more interesting.

Try getting things to work with simple shapes first. It is better to have a simple helicopter made of blocks that has a block propeller that spins properly, than a fancy shaped thing that doesn’t fly correctly.

(optional) You may load geometry from a file (using, for example THREE’s OBJLoader). However, if you do this, you must describe in the text file below where the OBJ file comes from. If you do not create the file yourself, be sure to give proper attribution, and confirm that it comes from a source that allows you to use it (e.g., it has a Creative Commons license). Don’t forget to add any geometry files to the repository. Please do not give big files, or things that use features we haven’t discussed in class yet (like textures). You may only add object files (i.e., .obj). If you choose to load geometry from a file, look at the previous workbook for tips. You will have plenty of opportunity to use loaded objects in later workbooks.

If you’re curious how to make a radar dish, you can use the lathe example. Or you can make it some other way. A cone would work at a minimum. It is more important that the object has the right behavior (it clearly points toward an aircraft). A hint: lookAt is your friend.

You should complete this assignment in 07-06-01.js ( 07-06-01.html). We’ve given you some code to start - a basic ground plane, a camera, some lights, even a simple animation loop. We’ve put the OrbitControls for the camera into the scene. You don’t have to use what we’ve put there (you can take out things if you want to put in better stuff - especially for the ground and lighting). However, please include OrbitControls in your result.

This part of the assignment does not use the framework code (described in the later pages). Please build everything using THREE.js “from scratch” (using the starter code). In other parts of this workbook, we’ll introduce you to some framework code that should help in making bigger projects.

We will reward exceptional projects with advanced points. From the last quadcopter assignment, we saw that people can be very creative. We will reward cool stuff (after you show the basics). It is more important to have spinning propellers on flying aircraft than fancier things.

  1. Have interesting aircraft, potentially with multiple types. This means more than just finding a shape and loading it from a file (although loading geometry is allowed).
  2. Have the aircraft have interesting behaviors. One has to fly in a circle. Others can fly in more complex patterns. For example, have a quadcopter that takes off, picks a random place to fly to, turns to face that direction, flies in that direction and lands when it gets to its destination. You could give it a spotlight that shines at its destination so we know where it’s going.

You must list the features you have implemented in the text file 07-06-01.txt:

After this exercise, move on to Page  7  (The CS559 Framework Code (GraphicsTown)) to learn about the framework code we’ll use for the next exercises (and future workbooks).

Page 6 Rubric (26 points total)
Points (21):
Box 07-06-01
2 pt
Some aircraft that isn’t a donut
Box 07-06-01
3 pt
A propeller that spins (not the body)
Box 07-06-01
3 pt
More than one propeller spinning (per aircraft)
Box 07-06-01
2 pt
(at least) One aircraft that flies in a circle (or curved path)
Box 07-06-01
3 pt
aircraft points forward as it moves
Box 07-06-01
3 pt
multiple aircraft both moving, both with propellers
Box 07-06-01
2 pt
Radar dish (or some pointable object)
Box 07-06-01
3 pt
Radar correctly points at aircraft (tracks as aircraft moves) - should use lookat
Advanced points (5) (maximum 10 can be earned in this workbook):
Box 07-06-01
1 pt
cool aircraft
Box 07-06-01
1 pt
more complex motion
Box 07-06-01
2 pt
multiple types of aircraft - each with an articulation/propeller
Box 07-06-01
1 pt
other cool features (students came up with some great things in 2D!)