Remark for the bresenham line generation algorithm, Computer Graphics

Remark for the Bresenham Line Generation Algorithm

Remark: The algorithm will be properly the same if we suppose | m | < 1

  • Algorithm | m | < 1:

(a) Input two line ending points and store left end point in (x0, y0) (b) Load (x0, y0) on frame buffer that is, plot the first point.

(c)  Determine Δx, Δy, 2Δy, 2Δy - 2Δx and acquire the beginning value of decision parameter as p0 = 2Δy - Δx

(d) At each xk along the line, beginning at k = 0, perform subsequent test:

If pk < 0, the subsequent plot is (xk + 1, yk) and pk + 1   = pk + 2Δy else subsequent plot is (xk + 1 , yk + 1) and pk + 1 = pk + 2(Δy - Δx)

(e) Repeat step (D) Δx times.

Bresenham Line Generation Algorithm    (| m | < 1)

Δ x ← x1 - x0

Δ y ← y1 - y0

p0 ← 2Δy - Δx

while (x0 < = x1) do

{puton (x0, y0)

if (pi > 0) then

{x0 ← x0 + 1;

y0 ← y0 + 1;

pi + 1 ← pi + 2 (Δy - Δx);

}

if (pi < 0) then

{x0 ← x0 + 1

y0y0

pi + 1 ← pi + 2 Δy

}

}

Posted Date: 3/22/2013 7:28:53 AM | Location : United States







Related Discussions:- Remark for the bresenham line generation algorithm, Assignment Help, Ask Question on Remark for the bresenham line generation algorithm, Get Answer, Expert's Help, Remark for the bresenham line generation algorithm Discussions

Write discussion on Remark for the bresenham line generation algorithm
Your posts are moderated
Related Questions
Resolution Graphic demonstrations are utilized in presentations to assist convey a concept or express a mood, two kinds of demonstrations graphics are: Vector, and B

Important Points for Designing the Animation Sequence There are several applications which do not follow this sequence as, real time computer animations generated by vehicle dr

Sequencing of Animation Design Previously we have discussed many things regarding the traditional and current trends of computer created animation although now it is time to pr

Refresh Rate: refreshing on raster - scan displays is carried out at the rate of 60 to 80 frames per second, although some system are designed for higher refresh rates. Sometimes,

Point clipping - 2-d viewing and clipping Point clipping is the method related to suitable display of points in the scene, though this type of clipping is utilized less freque

Hypertext/media and Human Memory Humans associate pieces of information along with other information and make complicated knowledge structures. Thus, this is also said as the h

Question 1) Why are selection tools useful? Describe them based on different categories Question 2) What are the different types of layers? Describe each type Quest

What is surface patch?  A single surface element can be explained as the surface traced out as two parameters (u, v) take all possible values between 0 and 1 in a two-parameter

De Casteljeau algorithm: The control points P 0 , P 1 , P 2 and P 3 are combined with line segments termed as 'control polygon', even if they are not actually a polygon although

3-D Modeling and Animation Tools: By 3-D modeling software, objects rendered in perspective show more realistic. One can produce stunning scenes and wander by them, choosing just