We are here with you hands in hands to facilitate your learning & don't appreciate the idea of copying or replicating solutions. Read More>>

Looking For Something at vustudents.ning.com? Click Here to Search


+ Link For Assignments, GDBs & Online Quizzes Solution


+ Link For Past Papers, Solved MCQs, Short Notes & More

Dear Students! Share your Assignments / GDBs / Quizzes files as you receive in your LMS, So it can be discussed/solved timely. Add Discussion

How to Add New Discussion in Study Group ? Step By Step Guide Click Here.

CS602: Computer Graphics Assignment No. 03 Semester: Fall 2014 Total Marks: 20 Due Date:12/02/2015


Total Marks: 20


Due Date:12/02/2015


Please read the following instructions carefully before submitting assignment:

Read and follow the instructions given in document inside the Help folder attached.

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.


The objective of this assignment is to;

  • Learn about rotation of Line.



In this assignment, you are provided with a small startup code attached with this assignment in folder “StartupCode”. Your job is to slightly modify this code as desired in this assignment.

First, you need to understand the working of the given code and execute it in Dev-C++. This program essentially draws some text, a line and a point on screen as shown in following screenshot.

By opening rotation.dev project file in Dev-C++ and successful compilation, execution, you will see the above output. Notice the small Dot near the middle of screen; this is our center of rotation.


Your Task

Your task is to add few lines of code in order to rotate the line around the “point near the center” as shown in “DesiredSolution.exe”. Each time, you press Spacebar button on the keyboard, the line is slightly moved along the circular path. If keep on press the spacebar, the line will keep revolving around this central point. This simply requires only few lines of code to modify the x and y coordinates of the Line. You shall add your code inside the while loop in the areas indicated with comments “Add your code here to modify coordinates of Line”.

Hint: You have to use your mathematical skills in order to calculate the coordinates of Line for its rotation about the given point.

Screenshot of the desired  output:



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.



+ How to Follow the New Added Discussions at Your Mail Address?

+ How to Join Subject Study Groups & Get Helping Material?

+ How to become Top Reputation, Angels, Intellectual, Featured Members & Moderators?

+ VU Students Reserves The Right to Delete Your Profile, If?

See Your Saved Posts Timeline

Views: 2956


+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)

+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)

+ Click Here to Search (Looking For something at vustudents.ning.com?)

+ Click Here To Join (Our facebook study Group)


Replies to This Discussion

idea solution please

yaa lets' start discussion.......

Who solved assignment

Dosto aj last date he aur kisi ne discuss bi kia 

koi to churu karo bhai idea do is ka kuch

bahi last hours shru hen koi tu idea do

editing bhut ker lee but kabi tokri banti he kabi line opar ko bhagna shuru ker deta he
samj nahee aa raheeee

instructor ne kaha ha ma upload kr donga 14 feb ko tens na lo sub

oh yes I nearly   got it now a little effort required

to rotate the line the code is on page 129  lecture note  just use code for x1,x2 ,y1,y2  while delete the remaining code.

it worked....... but not exactly...... 

variate the value of angle  it may come close to the required assignment


© 2020   Created by +M.Tariq Malik.   Powered by

Promote Us  |  Report an Issue  |  Privacy Policy  |  Terms of Service