Scan-line Polygon filling using OPENGL in C
Figures on a computer screen can be drawn using polygons. To fill those figures with color, we need to develop some algorithm.There are two famous… Read More »
Figures on a computer screen can be drawn using polygons. To fill those figures with color, we need to develop some algorithm.There are two famous… Read More »
Anti-Aliased Line Drawing Below is the image showing line drawn with Bresenham’s line algorithm (left) and Xiaolin Wu’s line algorithm (right) which smooths the line.… Read More »
A scaling transformation alters size of an object. In the scaling process, we either compress or expand the dimension of the object. Scaling operation can… Read More »
While trying c graphic programming on Ubuntu, I figured out that graphic.h is not a standard C library and it is not supported by gcc… Read More »
Given a radius of a circle, draw the circle without using floating point arithmetic. Following program uses a simple concept. Let the radius of the… Read More »
A convex polygon and a convex clipping area are given. The task is to clip polygon edges using the Sutherland–Hodgman Algorithm. Input is in the… Read More »
Clipping: In computer graphics our screen act as a 2-D coordinate system. it is not necessary that each and every point can be viewed on… Read More »
Given coordinate of two points A(x1, y1) and B(x2, y2) such that x1 < x2 and y1 < y2. The task to find all the… Read More »
Given coordinate of two points A(x1, y1) and B(x2, y2). The task to find all the intermediate points required for drawing line AB on the… Read More »
In any 2-Dimensional plane if we connect two points (x0, y0) and (x1, y1), we get a line segment. But in the case of computer… Read More »
Given a set of lines and a rectangular area of interest, the task is to remove lines which are outside the area of interest and… Read More »
In Turbo C graphics we use graphics.h functions to draw different shapes(like circle, rectangle etc), display text(any message) in different format(different fonts and colors). By… Read More »
Given starting and ending positions of segments on a line, the task is to take the union of all given segments and find length covered… Read More »
Since the dawn of computers, Hollywood has greatly demonstrated a Hacker or a Programmer as someone sitting on a computer typing random keys on computer… Read More »
Given a obfuscated code that generates the map of India, explain its working. The following code when executed generates the map of India – #include… Read More »