[ Next Article | Previous Article | Book Contents | Library Home | Legal | Search ]
GL3.2 for AIX: Graphics Library (GL) Technical Reference

zclear Subroutine

Purpose

Initializes the z-buffer.

Libraries

Graphics Library

C (libgl.a)

FORTRAN (libfgl.a)

C Syntax

void zclear( )

FORTRAN Syntax

SUBROUTINE ZCLEAR

Description

The zclear subroutine loads the z-buffer with the largest possible positive integer. If the default value of the z comparison function is used (set by the zfunction subroutine), the zbuffer, when cleared to the largest possible value, can be used for basic z-buffering.

Only the z-buffer behind the area inside the current screenmask is cleared. The screenmask cannot be made larger than the window. Note that by default the screenmask is exactly the same size as the window.

The scrmsk subroutine can be used to change the size of the screenmask. Note also that the viewport subroutine resets the screenmask to be precisely the same size as the viewport.

Note: The operation of this subroutine for the Model 730 Supergraphics Processor is modified. (See "Hardware Considerations".)

Example

The example C language programs zbuffer1.c and zbuffer2.c use the zclear subroutine to initialize the z-buffer.

Implementation Specifics

This subroutine is part of GL in the AIXwindows Environment/6000 Version 1, Release 2 with AIXwindows/3D Feature.

Files

/usr/include/gl/gl.h Contains C language constant and variable type definitions for GL.
/usr/include/gl/fgl.h Contains FORTRAN constant and variable type definitions for GL.

Related Information

Clearing the z-buffer and the color bitplanes simultaneously with the czclear subroutine.

Removing Hidden Surfaces.

Understanding the Hardware Used by GL, Clearing, Resetting, and Initializing GL, and Configuring the Frame Buffer.


[ Next Article | Previous Article | Book Contents | Library Home | Legal | Search ]