ACC - Fundamentals of auditing and business
ACC311ACC501
ACF - (Accounting And Finance Related)
ACF619ACFI619
COM - (Commerce Related)
COM619COMI619
ECO - (Economics Related)
ECO401 ECO402 ECO403 ECO404
ENG - (English Related)
ENG001 ENG101 ENG201 ENG301 ENG401
ETH201 - Ethics (for Non-Muslims)
ETH201
ISL201 - Islamic Studies
ISL201
IT - (Info Tech Related
IT000IT0001IT430IT619ITI619
MIS - (Project And Internship Report)
MIS619 MISI619MIS620 MISI620
PAD - (Public Administration Related)
PAD619 PADI619
PAK301 - Pakistan Studies
PAK301PAK302
PHY - (Physics Related)
PHY101 PHY301
PSC201 - International Relations
PSC201PSC401
SOC - (Socialogy Related)
SOC101 SOC401
STA - (Statistics and Research)
STA301 STA630
URDU - (Urdu Related)
URD101
VUPROJECTS
AIOU PROJECTS
VUDESK TUBE
VUDESK APP
IT INTERNSHIPS FB Page
FB Group
DESK MEMBERS

APPLY NOW  | SIT (STEP IN SECURITY) | Ghrapical Password | Smart ETL Tool | SMS BLOCKER

Assignment No. 02
Semester: Spring 2015

CS602: Computer Graphics

 

Total Marks: 20

 

Due Date:10/06/2015

 

Instructions

Please read the following instructions carefully before submitting assignment:

It should be clear that your assignment will not get any credit if:

  • The assignment is submitted after due date.
  • The submitted assignment does not open or file is corrupt.
  • Solution is copied from any other source.

Objective

The objective of this assignment is to;

  • Improve the motion effect of Ball given in Assignment No.1. i.e. Implement the Ball natural motion inside rectangular region.

 

Assignment

This assignment is based your Assignment No.1. Please see the given startup code for this assignment (in attached folder StartupCode) which is same as solution of Assignment No.1. Open Assigment2.dev project file in Dev-C++ and after successful compilation and execution, you will see the output. You can see the code in order to understand how coordinates of the Ball are modified to introduce back and forth motion effect along horzintal axis.

After understanding it’s working, you need to further modify the code as desired in this assignment.

 

Your Task

Your task is to slightly modify this code just by improving motion effect of the Ball as shown in the executables “Desired_Output.exe”. You can see, Ball is not restricted to horizontal motion only, rather its moving in the rectangular rigion and get reflected with the same angle as inccident angle after colliding with the walls. Each time you execute the program, Ball get started from a randomnly selected position near the top line of rectangle.

 

Hint: To get ball reflected with the same angle as inccident angle, you can to add/subtract 3 from both x and y coordinates of the ball depending upon its motion direction.

 

 

 

 

 

 

 

Screenshot of the desired  output:

 

Submission

You are required to submit your solution through LMS in zip format containing two files.

  • Your Project in zipped form containing both .dev and .cpp file.
  • An MS Word document containing screenshot of your program output/execution and your own Student-ID must be visible in the screenshot.

 

 

 

Views: 235

Download Documents

Replies to This Discussion

Advertise Here

idea solution ....

Download Documents

Ready solution for cs602

Download Documents

RSS

Super Active Members 

Sponsers

VUDESK GROUPS

 

© 2019   Created by ʭIsmail Shahʭ.   Powered by

Badges  |  Report an Issue  |  Terms of Service