“Point clipping is a process which is used to define the point position.” The point is either inside the view pane (window) or outside the view pane.

In computer graphics, the computer screen work like a two-dimensional coordinate system. Each point does not need to be displayed inside the computer screen.

It includes two terms-

  • Window: It means what to display?
  • Clipping: It means discarding the portion that is outside the window.

Example: Let us have a view pane (window). The coordinates of the window are-

(xwmax, xwmin) – For X-axis of the window

(ywmax, ywmin) – For Y-axis of the window    

Let us assume a point coordinate (P, Q). If the point lies inside the window, then there is no need to perform point clipping. But if the point lies outside the window, we need to perform clipping. We can understand it by the following equation-

xwmax <= P <= xwmin

ywmax <= Q <= ywmin

There are four conditions; if these four are satisfied, then the point lies inside the window. If anyone condition is not satisfied, then the point lies outside the window, it means we have to perform clipping on the point.

xwmin <= P

xwmax => P

ywmin <= Q

ywmax => Q

Algorithm of Point Clipping:

Step 1: First, we set the value of xwmin and xwmax coordinates for the window.

Step 2: Now, set the coordinates of a given point (P, Q).

Step 3: Nowcheck the above mention condition.

Step 4: If

                 Point coordinates lie between the (xwmin, xwmax) and (ywmin, ywmax)


                  {Display the point in the view pane}    


                  {Removethe point}

Step 5: Stop.

Pin It on Pinterest

Share This