Home
Netbeans Eclipse Qt Java
Games
College of Engineering Aeronautics and Astronautics Agricultural and Biological Engineering Biomedical Engineering Chemical Engineering Civil Engineering Construction Engineering and Management Electrical and Computer Engineering Engineering Education Engineering Professional Education Environmental and Ecological Engineering Industrial Engineering Materials Engineering Mechanical Engineering Nuclear Engineering
EPICS (Engineering Projects In Community Service) First-Year Engineering Program First-Year Engineering Honors Program Global Engineering Program Minority Engineering Program Professional Practice (Co-Op) Program Women in Engineering Program
College Administration Schools Programs All Groups All People ECN Webmail
Purdue Home

ECE 462 Assignment 2

Two-player Breakout game using C++ and Qt (outcome 2)

Please finish the first three lab exercises before starting this programming assignment.

This is the same assignment as the first assignment except that you have to write it in C++ and Qt. Please read the specification for the first assignment.

Bonus Points: You can only receive the bonus points for bonus task 3 once, in either PA1 or PA2.  However, if you accomplish the bonus tasks 1,2 in both PA1 and PA2, you may receive doubled bonus points.

Qt's drawChord

You can find the definition of Qt's drawChord here.  The following example shows calling the function with different parameters.

  // multiple with 16 because Qt divide each degree into 16 levels
  painter.setBrush(Qt::red);
  painter.drawChord(50, 60, 100, 100, 0, 45 * 16);
  painter.setBrush(Qt::blue);
  painter.drawChord(150, 60, 60, 60, 45 * 16, 90 * 16);
  painter.setBrush(Qt::black);
  painter.drawChord(250, 60, 60, 60, 150 * 16, 120 * 16);
  painter.setBrush(Qt::gray);
  painter.drawChord(350, 60, 60, 60, 90 * 16, 60 * 16);
  painter.setBrush(Qt::yellow);
  painter.drawChord(50, 160, 60, 60, 270 * 16, 90 * 16);
  painter.setBrush(Qt::green);
  painter.drawChord(150, 160, 60, 60, 330 * 16, 60 * 16);
  painter.setBrush(Qt::cyan);
  painter.drawChord(250, 160, 60, 60, 180 * 16, 180 * 16);
  painter.setBrush(Qt::magenta);
  painter.drawChord(350, 160, 60, 60, 150 * 16, 60 * 16);

 You can find the source code for generating the above figure here.