Top Description Fields Constructors Methods
org.lwjgl.opengl

public Class NVConservativeRaster

extends Object
Class Inheritance
Imports
org.lwjgl.system.*

Native bindings to the NV_conservative_raster extension.

This extension adds a "conservative" rasterization mode where any pixel that is partially covered, even if no sample location is covered, is treated as fully covered and a corresponding fragment will be shaded.

A new control is also added to modify window coordinate snapping precision.

These controls can be used to implement "binning" to a low-resolution render target, for example to determine which tiles of a sparse texture need to be populated. An app can construct a framebuffer where there is one pixel per tile in the sparse texture, and adjust the number of subpixel bits such that snapping occurs to the same effective grid as when rendering to the sparse texture. Then triangles should cover (at least) the same pixels in the low-res framebuffer as they do tiles in the sparse texture.

Field Summary

Modifier and TypeField and Description
public static final int
GL_CONSERVATIVE_RASTERIZATION_NV

Accepted by the cap parameter of Enable, Disable, IsEnabled.

public static final int
GL_MAX_SUBPIXEL_PRECISION_BIAS_BITS_NV

Accepted by the pname parameter of GetBooleanv, GetDoublev, GetIntegerv, and GetFloatv.

public static final int
GL_SUBPIXEL_PRECISION_BIAS_X_BITS_NV

Accepted by the pname parameter of GetBooleanv, GetDoublev, GetIntegerv, and GetFloatv.

public static final int
GL_SUBPIXEL_PRECISION_BIAS_Y_BITS_NV

Accepted by the pname parameter of GetBooleanv, GetDoublev, GetIntegerv, and GetFloatv.

Constructor Summary

AccessConstructor and Description
protected

Method Summary

Modifier and TypeMethod and Description
public static native void
glSubpixelPrecisionBiasNV(int
the SUBPIXEL_PRECISION_BIAS_X_BITS_NV value. The initial value is zero.
xbits
,
int
the SUBPIXEL_PRECISION_BIAS_Y_BITS_NV value. The initial value is zero.
ybits
)

Sets the SUBPIXEL_PRECISION_BIAS_X_BITS_NV and SUBPIXEL_PRECISION_BIAS_Y_BITS_NV values.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

GL_CONSERVATIVE_RASTERIZATION_NVback to summary
public static final int GL_CONSERVATIVE_RASTERIZATION_NV

Accepted by the cap parameter of Enable, Disable, IsEnabled.

GL_MAX_SUBPIXEL_PRECISION_BIAS_BITS_NVback to summary
public static final int GL_MAX_SUBPIXEL_PRECISION_BIAS_BITS_NV

Accepted by the pname parameter of GetBooleanv, GetDoublev, GetIntegerv, and GetFloatv.

GL_SUBPIXEL_PRECISION_BIAS_X_BITS_NVback to summary
public static final int GL_SUBPIXEL_PRECISION_BIAS_X_BITS_NV

Accepted by the pname parameter of GetBooleanv, GetDoublev, GetIntegerv, and GetFloatv.

GL_SUBPIXEL_PRECISION_BIAS_Y_BITS_NVback to summary
public static final int GL_SUBPIXEL_PRECISION_BIAS_Y_BITS_NV

Accepted by the pname parameter of GetBooleanv, GetDoublev, GetIntegerv, and GetFloatv.

Constructor Detail

NVConservativeRasterback to summary
protected NVConservativeRaster()

Method Detail

glSubpixelPrecisionBiasNVback to summary
public static native void glSubpixelPrecisionBiasNV(int xbits, int ybits)

Sets the SUBPIXEL_PRECISION_BIAS_X_BITS_NV and SUBPIXEL_PRECISION_BIAS_Y_BITS_NV values.

The vertex's window x and y coordinates may be optionally converted to fixed-point values with N fractional bits. If CONSERVATIVE_RASTERIZATION_NV is disabled, then N is the implementation-dependent value of SUBPIXEL_BITS. If CONSERVATIVE_RASTERIZATION_NV is enabled, N is computed as the sum of the value of SUBPIXEL_BITS and programmable values of SUBPIXEL_PRECISION_BIAS_X_BITS_NV and SUBPIXEL_PRECISION_BIAS_Y_BITS_NV.

When these values are non-zero, the invariance requirement may not apply because the subpixel precision may not be the same at all window coordinates.

Parameters
xbits:int

the SUBPIXEL_PRECISION_BIAS_X_BITS_NV value. The initial value is zero.

ybits:int

the SUBPIXEL_PRECISION_BIAS_Y_BITS_NV value. The initial value is zero.