Lecture 4 Graphic Primitives, Circle. Drawing Circles.

Slides:



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

Graphics Primitives Part II: Bresenhams line and circle.
Computer Graphics- SCC 342
Lecture 4 Graphic Primitives, Line. Features of a simple graphic program.
Computer Graphics 4: Bresenham Line Drawing Algorithm, Circle Drawing & Polygon Filling By:Kanwarjeet Singh.
CS 450: COMPUTER GRAPHICS REVIEW: DRAWING LINES AND CIRCLES SPRING 2015 DR. MICHAEL J. REALE.
+ CPCS 391 Computer Graphics 1 Instructor: Dr. Sahar Shabanah Lecture 3.
Scan Conversion Algorithms
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.
Advanced Manufacturing Laboratory Department of Industrial Engineering Sharif University of Technology Session # 7.
Lecture 16 Fun with graphics
Sullivan Precalculus: Section 5.2 Trig Functions: Unit Circle
Foundations of Computer Graphics (Fall 2012) CS 184, Lecture 11: Curves Problems
Find the exact values of trig functions no calculators allowed!!!
Raster conversion algorithms for line and circle
CS5500 Computer Graphics © Chun-Fa Chang, Spring 2007 CS5500 Computer Graphics May 3, 2007.
Computer Graphics (Fall 2008) COMS 4160, Lectures 8,9: Curves Problems
University of Missouri at Columbia 2D Scan-line Conversion University of Missouri at Columbia.
Edge Detection Today’s readings Cipolla and Gee –supplemental: Forsyth, chapter 9Forsyth Watt, From Sandlot ScienceSandlot Science.
Line Drawing by Algorithm. Line Drawing Algorithms Line drawn as pixels Graphics system –Projects the endpoints to their pixel locations in the frame.
Unit Circle Definition of Trig Functions. The Unit Circle  A unit circle is the circle with center at the origin and radius equal to 1 (one unit). 
Circle Drawing algo..
1 Trigonometric Functions of Any Angle & Polar Coordinates Sections 8.1, 8.2, 8.3,
Trigonometric Functions of Any Angle & Polar Coordinates
SOLUTION EXAMPLE 4 Standardized Test Practice Use the Distance Formula. You may find it helpful to draw a diagram.
CGMB214: Introduction to Computer Graphics
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.
Dr. S.M. Malaek Assistant: M. Younesi
Scan Conversion Line and Circle
October 14, 2014Computer Vision Lecture 11: Image Segmentation I 1Contours How should we represent contours? A good contour representation should meet.
The Trig Graphs Build-A-Graph Day (5.5). POD #1 Complete these limit statements. For limit statements, go to the graphs, not the unit circle. For which.
1Computer Graphics Implementation III Lecture 17 John Shearer Culture Lab – space 2
Section 7.5 Unit Circle Approach; Properties of the Trigonometric Functions.
1 Circle Drawing Algorithms Pictures snagged from
Graphics Output Primitives
CGMB214: Introduction to Computer Graphics
The Definition of the Derivative LESSON 3 OF 20. Deriving the Formula You can use the coordinates in reverse order and still get the same result. It doesn’t.
Image Synthesis Rabie A. Ramadan, PhD 7. 2 Image Rasterization.
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.
Trigonometric Functions of Any Angle & Polar Coordinates
Lecture 15: Raster Graphics and Scan Conversion
WARM UP What is the exact value of cos 30°? What is the exact value of tan 60°? Write cos 57° in decimal form. Write sin 33° in decimal form. Write csc.
Instructor: Dr. Shereen Aly Taie If (P>0)
Computer Graphics CC416 Lecture 04: Bresenham Line Algorithm & Mid-point circle algorithm Dr. Manal Helal – Fall 2014.
Computer Graphics Inf4/MSc Computer Graphics Lecture 4 Line & Circle Drawing.
5.7 Inverse Trig Functions. Does the sine function have an inverse?
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
Primitive graphic objects
Computer graphics 2D graphics.
Lecture 05: Mid-point Ellipse algorithm Dr. Manal Helal – Fall 2014
Chapter Three Part I Output Primitives CS 380.
Boolean Expressions Lecture No. 10.
CSE 167 [Win 17], Lecture 11: Curves Problems Ravi Ramamoorthi
Trigonometric functions
Scan Conversion of Circles
2D Scan-line Conversion
Reconstructing a Function from its Gradient
TEE SQUARE, SET SQUARES, COMPASS AND PROTRACTOR
Reading: Hambley Ch. 7 through 7.5
6 The Circular Functions and Their Graphs
Circles! You are going to create an “image” with circle(s)
Arc Length Area of a Sector Unit Circle Trig values of unit circle
Find the distance between the star and circle
GRADIENTS AND STRAIGHT LINE GRAPHS
Computational physics: intro workshop
Discuss: What information must we have to use the sine rule to calculate a missing length?
Presentation transcript:

Lecture 4 Graphic Primitives, Circle

Drawing Circles

Brute Force Method

Cheating with 8 arcs

Cheating with 8 arcs Implementation

Digital Differential Analysis - An incremental algorithm Does not require sine or cosine table. based upon calculating the gradient of a circle at a point and using that to approximate the position of the next point.

Digital Differential Analysis - An incremental algorithm

Digital Differential Analysis - Implementation

Bresenham’s algorithm for circles Based on limiting the choice of the next pixel to be plotted to two alternatives, then creating and testing a decision variable to determine which alternative is actually plotted. D(Si) and D(Ti) represent the differences between the squared distance between the center of the circle and the middle of pixels S and T. Whichever is smallest corresponds to the pixel that should be plotted. To combine the two calculations into one “decision variable” is simply a matter of subtracting the two expressions:

Bresenham’s algorithm for circles

Implementation for Bresenham’s algorithm

Implementation for circles