Z- buffer algorithm, Computer Graphics

Assignment Help:

Q. Describe the z- Buffer algorithm for hidden surface removal.

Ans. Z- buffer method: This method compares surface depths at each pixel position on the projection plane. The surface depth is measured from the view plane along the z- axis of a viewing system. When object description is converted to projection coordinates (x, y, z) each pixel position on the view plane is specified by x & y coordinate, and z value gives the depth information. Thus object depth can by comparing the z- values. The z- buffer algorithm is usually implemented in the normalized coordinates, so that z- values range from 0 at the back clipping plane to 1 at the front clipping plane. Z- Buffer Algorithm  1. Initialize the depth buffer and refresh buffer so that for all buffer position (x, y), depth (x, y) =0 refresh (x, y) = 1 background. 2. For each position on each polygon surface, compare depth values to previously started values in the depth buffer to determine visibility. (a) Calculate the depth z for each (x,y) position on the polygon. (b) If z> depth (x, y) then set depth (x, y) =z refresh (x, y) = Isuff (x, y) Where I background intensity and Isuff (x, y) is the projection intensity value for the surface at pixel position (x, y). After all surface have been processed, the depth buffer contains depth values for the visible surface and the refresh buffer contains the corresponding intensity values for those surface. In the figure, among three surface, surface S1 has the smallest depth at view position (x, y) and hence highest z value. So it is visible at that position. To calculate the z- value, the plane equation Ax + By + Cz + D = 0 is used where (x, y, z) is any point on the plane, and the coefficient A, B, C and D are contents describing the spatial properties of the plane.                                                     Only one subtraction is needed to calculate z (x + 1, y) given z (x, y), since the quotient A/C is constant and ^x = 1. A similar incremental calculation cam be performed to determine the first value of z on the next scan line, decrementing by B/C for each ^y. Drawback of z- buffer (i) It requires an additional buffer and hence the large memory. (ii) It is a time consuming process as it requires comparison for each pixel instead for the entire polygon. 

 

 


Related Discussions:- Z- buffer algorithm

Cathode ray tube, cathode ray tube is an analog or digital device

cathode ray tube is an analog or digital device

Advantages of bresenham’s line drawing algorithm, What are the advantages o...

What are the advantages of Bresenham's line drawing algorithm over DDA line drawing algorithm? DDA and Bresenham algorithms both are efficient line drawing algorithm. Breaenham

Buffer areas required for z-buffer algorithm, Buffer Areas Required For Z-B...

Buffer Areas Required For Z-Buffer Algorithm For applying z-buffer algorithm, we need two buffer areas or two 2-Dimentional arrays: 1) Depth-buffer [i,j], to sa

Different advertising hooks, Question: (a) Name two visual effects you...

Question: (a) Name two visual effects you would use to communicate: i. Good old days ii. Rebellion iii. Fear (b) Explain each of your answers given in section (a).

What do you understand by the term image compositing, Question 1: (a) E...

Question 1: (a) Explain in detail what you understand by the term image compositing and where it is more often used? (b) You are given 3-5 images to make a photo montage/ima

What is a blobby object, What is a Blobby object?  Some objects do not ...

What is a Blobby object?  Some objects do not handle a fixed shape, but change their surface characteristics in sure motions or when in proximity to other objects. That is call

Cases for subdivisions of polygon-visible surface detection, Cases for Subd...

Cases for Subdivisions of Polygon No additional subdivisions of a particular area are desired, if one of the subsequent conditions is true as: Case 1: All the polygons ar

.python programming, Write a function that computes the area of a triangle ...

Write a function that computes the area of a triangle given the length of its three sides as parameters (see Programming Exercise 9 from Chapter 3). Use your function to augment tr

View volumes and general projection transformations, View Volumes and Gener...

View Volumes and General Projection Transformations You have to remember that the view volume is the volume which sets up near and far extents, top and bottom extents and left

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd