Question: Problem 5 (20 points). Graphics applications often need to simply object geometries before rendering them to the screen. To do so, they only draw the

 Problem 5 (20 points). Graphics applications often need to simply object

Problem 5 (20 points). Graphics applications often need to simply object geometries before rendering them to the screen. To do so, they only draw the portions of the objects that are not covered up (or occluded) by other objects. Consider the problem of drawing a 2-dimensional city scene with different rectangular buildings that eliminates borders hidden by other buildings: The input is a set of rectangular buildings. Each building shares a common bottom and is described by (1,2r, h). and give the building's left and right r coordinates and h gives the height. The output is a collection of strips where each strip is described by it's left coordinate h (or the pair (21,h)). The collection denotes the end of the cityscape border with Imax is the rightmost edge of all the buildings. and its height maz, 0) where (a) Give the resulting cityscape output for the input {(1, 5, 9), (3, 8, 3), (9, 11, 6), (10, 17, 8), (13, 16,4)}. Provide both a drawing of the cityscape as well as the output pairs. (b) Give pseudocode for a divide and conquer algorithm that solves the cityscape problem faster than O(na) time. (c) What is your algorithm's running time and why? Problem 5 (20 points). Graphics applications often need to simply object geometries before rendering them to the screen. To do so, they only draw the portions of the objects that are not covered up (or occluded) by other objects. Consider the problem of drawing a 2-dimensional city scene with different rectangular buildings that eliminates borders hidden by other buildings: The input is a set of rectangular buildings. Each building shares a common bottom and is described by (1,2r, h). and give the building's left and right r coordinates and h gives the height. The output is a collection of strips where each strip is described by it's left coordinate h (or the pair (21,h)). The collection denotes the end of the cityscape border with Imax is the rightmost edge of all the buildings. and its height maz, 0) where (a) Give the resulting cityscape output for the input {(1, 5, 9), (3, 8, 3), (9, 11, 6), (10, 17, 8), (13, 16,4)}. Provide both a drawing of the cityscape as well as the output pairs. (b) Give pseudocode for a divide and conquer algorithm that solves the cityscape problem faster than O(na) time. (c) What is your algorithm's running time and why

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!