1 Bresenham’s Circle Algorithm Define:D(s i ) = distance of p 3 from circle D(t i ) = distance of p 2 from circle i.e.D(s i ) = (x i + 1) 2 + y i 2 – r.

Slides:



Advertisements
Similar presentations
Circle Drawing Asst. Prof. Dr. Ahmet Sayar Kocaeli University
Advertisements

UNIT-1 Bresenham’s Circle Algorithm
Graphics Primitives Part II: Bresenhams line and circle.
Circles Sheila Roby April 22, What is a circle? A circle is the set of all points in a plane equidistant from a fixed point. Equi means same, so.
FRACTIONS.
CS 376 Introduction to Computer Graphics 02 / 02 / 2007 Instructor: Michael Eckmann.
Computer Graphics 4: Bresenham Line Drawing Algorithm, Circle Drawing & Polygon Filling By:Kanwarjeet Singh.
Larry F. Hodges (modified by Amos Johnson) 1 Design of Line, Circle & Ellipse Algorithms.
Lecture 17 Fun with Graphics Dr. Dimitrios S. Nikolopoulos CSL/UIUC.
Lecture 16 Fun with graphics
$100 $200 $300 $400 $500 $100 $200 $300 $400 $500 $100 $200 $300 $400 $500 $100 $200 $300 $400 $500 $100 $200 $300 $400 $500 $100 $200 $300.
Lesson 16: The Most Famous Ratio of All
Raster conversion algorithms for line and circle
CS5500 Computer Graphics © Chun-Fa Chang, Spring 2007 CS5500 Computer Graphics May 3, 2007.
Exercise Exercise3.1 8 Exercise3.1 9 Exercise
Exercise Exercise Exercise Exercise
Exercise Exercise Exercise Exercise
Exercise Exercise6.1 7 Exercise6.1 8 Exercise6.1 9.
University of Missouri at Columbia 2D Scan-line Conversion University of Missouri at Columbia.
Chapter 3 Graphics Output Primitives
Circle Drawing algo..
CGMB214: Introduction to Computer Graphics
Rasterizing primitives: know where to draw the line Dr Nicolas Holzschuch University of Cape Town Modified.
IT- 601: Computer Graphics Lecture-03 Scan Conversion
1 CS 430/536 Computer Graphics I Circle Drawing and Clipping Week 3, Lecture 6 David Breen, William Regli and Maxim Peysakhov Geometric and Intelligent.
WHERE TO DRAW A LINE?? Line drawing is accomplished by calculating intermediate positions along the line path between specified end points. Precise definition.
Scan Conversion Line and Circle
CS 450: COMPUTER GRAPHICS REVIEW: DRAWING ELLIPSES AND OTHER CURVES SPRING 2015 DR. MICHAEL J. REALE.
Do Now Make a table for –2 ≤ x ≤ 2 and draw the graph of: y = 2 x (Problem #1 from today’s packet)
$100 $200 $300 $400 $500 $100 $200 $300 $400 $500 $100 $200 $300 $400 $500 $100 $200 $300 $400 $500 $100 $200 $300 $400 $500 $100 $200 $300.
Larry F. Hodges 1 Design of Line and Circle Algorithms.
Presents. Distance Time Distance – Time Graph Distance Time Distance – Time Graph A Click the picture below that matches graph A.
Sullivan Algebra and Trigonometry: Section 2.4 Circles Objectives Write the Standard Form of the Equation of a Circle Graph a Circle Find the Center and.
1 Circle Drawing Algorithms Pictures snagged from
Introduction Computer Graphics & Its application Types of computer graphics Graphic display : random Scan & Raster Scan display Frame buffer and video.
Graphics Output Primitives
EXAMPLE 3 Write the standard equation of a circle The point (–5, 6) is on a circle with center (–1, 3). Write the standard equation of the circle. SOLUTION.
Image Synthesis Rabie A. Ramadan, PhD 7. 2 Image Rasterization.
MIDPOINT CIRCLE & ELLIPSE GENERARTING ALGORITHMS
November 18, We could solve for y in terms of x ( x 0, y 0 ) are the origin points A Simple Circle Drawing Algorithm The equation for a circle.
Midpoint Circle Algorithm
CS 325 Introduction to Computer Graphics 02 / 03 / 2010 Instructor: Michael Eckmann.
Algebra II Honors Problem of the Day Homework: p odds Without graphing find all symmetries for each equation.
Warm-Up What is the distance between the two trees? If you wanted to meet a friend halfway, where would you meet.
11.5: Circles in the Coordinate Plane OBJECTIVES: STUDENTS WILL BE TO… IDENTIFY THE CENTER AND THE RADIUS OF A CIRCLE FROM ITS EQUATION WRITE AND GRAPH.
Warm Up. EQUATION OF A CIRCLE Geometry How can we make a circle? What are the most important aspects when drawing a circle?
Equations of Circles. You can write an equation of a circle in a coordinate plane, if you know: Its radius The coordinates of its center.
3:00. 2:59 2:58 2:57 2:56 2:55 2:54 2:53 2:52.
Computer Graphics : Bresenham Line Drawing Algorithm, Circle Drawing
Computer Graphics CC416 Lecture 04: Bresenham Line Algorithm & Mid-point circle algorithm Dr. Manal Helal – Fall 2014.
Section 2.8 Distance and Midpoint Formulas; Circles.
10-8 Equations of Circles 1.Write the equation of a circle. 2.Graph a circle on the coordinate plane.
10/10/2006TCSS458A Isabelle Bichindaritz1 Line and Circle Drawing Algorithms.
Computer Graphics Lecture 07 Ellipse and Other Curves Taqdees A. Siddiqi
Computer Graphics Lecture 06 Circle Drawing Techniques Taqdees A. Siddiqi
Line Drawing Algorithms 1. A line in Computer graphics is a portion of straight line that extends indefinitely in opposite direction. 2. It is defined.
Computer graphics 2D graphics.
CENG 477 Introduction to Computer Graphics
MID-POINT CIRCLE ALGORITHM
Lecture 05: Mid-point Ellipse algorithm Dr. Manal Helal – Fall 2014
Prof. Harriet Fell Spring 2007 Lecture 5 – January 17, 2006
Chapter Three Part I Output Primitives CS 380.
Estimating Sums and Differences of Decimals
Top Fire Protection Services Ottawa available on Dubinskyconstruction
Scan Conversion of Circles
2D Scan-line Conversion
Type to enter a caption. Computer Graphics Week 2 Lecture 1.
Type to enter a caption. Computer Graphics Week 1 Lecture 2.
OUTPUT PRIMITIVES / DISPLAY TECHNIQUES
Presentation transcript:

1 Bresenham’s Circle Algorithm Define:D(s i ) = distance of p 3 from circle D(t i ) = distance of p 2 from circle i.e.D(s i ) = (x i + 1) 2 + y i 2 – r 2 [always +ve] D(t i ) = (x i + 1) 2 + (y i – 1) 2 – r 2 [always -ve] Decision Parameter p i = D(s i ) + D(t i ) so if p i < 0 then the circle is closer to p 3 (point above) if p i ≥ 0 then the circle is closer to p 2 (point below)

2 The Algorithm x 0 = 0 y 0 = r p 0 = [1 2 + r 2 – r 2 ] + [1 2 + (r-1) 2 – r 2 ] = 3 – 2r if p i < 0 then y i+1 = y i p i+1 = p i + 4x i + 6 else if p i ≥ 0 then y i+1 = y i – 1 p i+1 = p i + 4(x i – y i ) + 10 Stop when x i ≥ y i and determine symmetry points in the other octants x i+1 = x i + 1

3 Example ipipi x i, y i 0-17(0, 10) 1-11(1, 10) 2(2, 10) 313(3, 10) 4-5(4, 9) 515(5, 9) 69(6, 8) 7(7,7) r = 10 p 0 = 3 – 2r = -17 Initial point (x 0, y 0 ) = (0, 10)

p 0 = *0 + 6 = -11 p 1 = *1 + 6 = -1 p 2 = -1+ 4*2 + 6 = 13 p 3 = (3 – 10) + 10 = -5

5 Exercises Draw the circle with r = 12 using the Bresenham algorithm. Draw the circle with r = 14 and center at (15, 10).