Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Suppose there is a straight line that goes from ( 1 0 , - 1 0 ) to ( 1 5 , - 1 9

Suppose there is a straight line that goes from (10,-10) to (15,-19). Use the
midpoint line drawing algorithm to calculate all the intermediary pixel coordinates.
Use eightway symmetry if necessary. Show the values of x,y,d, chosen neighbor,
real coordinate in tabular form.
In class, we have derived the midpoint line algorithm that exclusively works for
zone 0. Now, using the knowledge gained in class, derive the algorithm again but
this time exclusively for the zone you calculated in question (a). So that we
don't need to rely on eightway symmetry anymore. Mainly, you need to find the
formula for dinit,, which neighbor we choose when the value of d is positive or
negative, and the formula to update the value of d(for both cases).
Draw the flowchart of the version of the algorithm you derived in question (b).
[For sanity check that your new algorithm is working, you can recalculate the
pixels for the line given in question (a) and cross check, given that your question
(a)'s answer was correct (Optional)]
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Fundamentals Study Guide

Authors: Dr. Sergio Pisano

1st Edition

B09K1WW84J, 979-8985115307

More Books

Students also viewed these Databases questions

Question

=+What do you want them to know?

Answered: 1 week ago

Question

=+1. How can you animate it?

Answered: 1 week ago