Write c program which takes points as input from mouse click, Computer Graphics

Assignment Help:

Write a C program which takes points as input from mouse clicks (left button) and then performs an action.  Apply your program to generate a closed polygon as follows: Every time a left button is pressed, a point on the screen is selected at mouse position and corresponding edge is drawn. When the right button is clicked, the polygon is created.  Use one of the line drawing algorithms to plot your line segment.


Related Discussions:- Write c program which takes points as input from mouse click

What is persistence, What is persistence? The time it takes the emitted...

What is persistence? The time it takes the emitted light from the screen to decompose one tenth of its original intensity is known as persistence.

Briefly explain the term density range, QUESTION a) Explain with the he...

QUESTION a) Explain with the help of a diagram, how a thermal inkjet printer works. b) Briefly explain the term density range. c) Distinguish between scaling and resampli

Rotation about z-axis - transformation for 3-d rotation, Rotation about z-a...

Rotation about z-axis - Transformation for 3-d rotation Rotation about z-axis is explained by the xy-plane. Suppose a 3-D point P(x,y,z) be rotated to P'(x',y',z') along with

2d clipping algorithms - clipping and 3d primitives, 2D Clipping Algorithms...

2D Clipping Algorithms Clipping is an operation that eliminates invisible objects from the view window.  To understand clipping, recall that when we take a snapshot of a scene,

Vertical retrace - display devices, Vertical retrace - Display Devices ...

Vertical retrace - Display Devices In a refresh CRT monitor, the time it takes for an electron beam to return to the top, left most point on the monitor after refreshing all ho

Assumptions for area subdivision method, Assumptions for Area Subdivision M...

Assumptions for Area Subdivision Method a) ¾   Plane of projection is z=0 plane b) ¾ Orthographic parallel projections c) ¾   Direction of projection as d= (0,0,-1) d

Scale a sphere cantered on the point (1, Scale a sphere cantered on the poi...

Scale a sphere cantered on the point (1, 2, and 3) with radius 1, so that the new sphere has the same centre with radius 2.    Solution: Translate the sphere so that its centre

How does the z-buffer algorithm find out which surfaces, Illustration 1: H...

Illustration 1: How does the z-buffer algorithm find out which surfaces are hidden? Solution : Depth or Z-buffer algorithm employs a two buffer area each of two-dimensional ar

What is aspect ratio, Define  Aspect ratio- Aspect ratio: The ratio ...

Define  Aspect ratio- Aspect ratio: The ratio of vertical points to horizontal points necessary to produce equal –length lines in both directions on the screen, is called as

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd