This extension adds a new parameter to the polygon offset function that clamps the calculated offset to a minimum or maximum value. The clamping functionality is useful when polygons are nearly parallel to the view direction because their high slopes can result in arbitrarily large polygon offsets. In the particular case of shadow mapping, the lack of clamping can produce the appearance of unwanted holes when the shadow casting polygons are offset beyond the shadow receiving polygons, and this problem can be alleviated by enforcing a maximum offset value.
| Modifier and Type | Field and Description |
|---|---|
| public static final int | GL_POLYGON_OFFSET_CLAMP_EXT
Accepted by the |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public static native void | glPolygonOffsetClampEXT(float
scales the maximum depth slope of the polygon factor, float scales an implementation-dependent constant that relates to the usable resolution of the depth buffer units, float the minimum or maximum clamp value clamp)The depth values of all fragments generated by the rasterization of a polygon may be offset by a single value that is computed for that polygon. |
| GL_POLYGON_OFFSET_CLAMP_EXT | back to summary |
|---|---|
| public static final int GL_POLYGON_OFFSET_CLAMP_EXT Accepted by the | |
| EXTPolygonOffsetClamp | back to summary |
|---|---|
| protected EXTPolygonOffsetClamp() | |
| glPolygonOffsetClampEXT | back to summary |
|---|---|
| public static native void glPolygonOffsetClampEXT(float factor, float units, float clamp) The depth values of all fragments generated by the rasterization of a polygon may be offset by a single value that is computed for that polygon. The function that determines this value is specified with this command.
| |