1. Homepage
  2. Programming
  3. CISC/CMPE 454 Computer Graphics - Assignment 1 - Asteroids

CISC/CMPE 454 Computer Graphics - Assignment 1 - Asteroids

Engage in a Conversation
CanadaQueen's UniversityCISC 454CMPE 454Computer GraphicsAsteroidsOpenGLC++

CISC/CMPE 454 Assignment 1 - Asteroids

Due Friday, January 27 at noon CourseNana.COM

You will implement parts of the Asteroids game by extending the skeleton code provided in this directory. You may work individually or in groups of two. Graduate students must work individually. CourseNana.COM

Compile the code

On Linux: CourseNana.COM

Go to the linux directory. Execute make CourseNana.COM

If this fails, you may need to install the glfw library like this: CourseNana.COM

sudo apt-get install libglfw3-dev

On Windows with Visual Studio: CourseNana.COM

Click on a1.vcxproj Press F7. CourseNana.COM

On Mac: CourseNana.COM

Go to the macos directory. Execute make CourseNana.COM

If this fails, you may need to install gcc and glfw by following the instructions in the README.txt file in the macos directory. CourseNana.COM

Run the code

Run the code and verify that a window pops up with the Asteroids world. On Linux and MacOS this is done by typing ./asteroids in the terminal window. CourseNana.COM

Read the code

Read all of the code to get a general understanding of it. This should take several hours and will help a great deal later on. CourseNana.COM

Modify the code

All modifications are done in places with a comment saying "YOUR CODE HERE": CourseNana.COM

  1. Modify Object::modelToWorldTransform() to return the 4x4 transform that maps object points to the world coordinate system. An Object has a position, orientation, and a scale factor, all of which must be incorporated into the model-to-world transform. [1 mark]
  2. Modify Object::setupVAO() to set up the VAO that defines the object segments. [1 mark]
  3. Modify Object::draw() to draw the object in the correct position and orientation. You'll first need to find the model-to-view transform. [1 mark]
  4. Modify Ship::addThrust() to change the velocity. Use SHIP_THRUST_ACCEL, deltaT, and the current ship orientation. Modify Ship::rotateCW() to rotate the ship clockwise. [1 mark]
  5. Modify Segment::intersects() to determine whether two segments intersect. [1 mark]
  6. Modify Ship::fireShell() to set the initial state of a shell that is fired from the nose of the ship [1 mark]
  7. Modify World::updateState() to check for shell/asteroid collisions and to update the asteroids upon any such collisions. [3 marks]
  8. Optionally, implement additional features. Up to [3 bonus marks] can be awarded for additional features. You could have 3D asteroids (e.g. spinning) but still play on a flat plane. Or you could implement a flying saucer as in the original game. Or have a shield. Or have a number of lives that are shown on the screen and decremented.

Submit the code

Create a NEW DIRECTORY called 'a1'. CourseNana.COM

COPY ONLY THESE FILES into that directory: CourseNana.COM

.cpp .h README.txt CourseNana.COM

Do not include other files and directories. In particular, DO NOT INCLUDE THESE: .vs A1.txt a1.sln a1.vcxproj a1.vcxproj.filters glad include lib32 lib64 libglfw.so ll resource.h . CourseNana.COM

Your archive should be under 500 KB. If it's larger, you've likely included extra files, especially a Debug or .vs directory inside the windows directory. CourseNana.COM

Create a zip archive of that directory, named 'a1.zip'. If you use a different name, you WILL LOSE 1 MARK! CourseNana.COM

Submit the zip archive on OnQ. CourseNana.COM

Get in Touch with Our Experts

Wechat WeChat
Whatsapp Whatsapp
Canada代写,Queen's University代写,CISC 454代写,CMPE 454代写,Computer Graphics代写,Asteroids代写,OpenGL代写,C++代写,Canada代编,Queen's University代编,CISC 454代编,CMPE 454代编,Computer Graphics代编,Asteroids代编,OpenGL代编,C++代编,Canada代考,Queen's University代考,CISC 454代考,CMPE 454代考,Computer Graphics代考,Asteroids代考,OpenGL代考,C++代考,Canadahelp,Queen's Universityhelp,CISC 454help,CMPE 454help,Computer Graphicshelp,Asteroidshelp,OpenGLhelp,C++help,Canada作业代写,Queen's University作业代写,CISC 454作业代写,CMPE 454作业代写,Computer Graphics作业代写,Asteroids作业代写,OpenGL作业代写,C++作业代写,Canada编程代写,Queen's University编程代写,CISC 454编程代写,CMPE 454编程代写,Computer Graphics编程代写,Asteroids编程代写,OpenGL编程代写,C++编程代写,Canadaprogramming help,Queen's Universityprogramming help,CISC 454programming help,CMPE 454programming help,Computer Graphicsprogramming help,Asteroidsprogramming help,OpenGLprogramming help,C++programming help,Canadaassignment help,Queen's Universityassignment help,CISC 454assignment help,CMPE 454assignment help,Computer Graphicsassignment help,Asteroidsassignment help,OpenGLassignment help,C++assignment help,Canadasolution,Queen's Universitysolution,CISC 454solution,CMPE 454solution,Computer Graphicssolution,Asteroidssolution,OpenGLsolution,C++solution,