Table of contents
GDI
TOC
Collapse the table of content
Expand the table of content

Guard Band Clipping

Last Updated: 2/14/2017

The driver signals that it supports guard band clipping when it fields the GUID_D3DExtendedCaps GUID in DdGetDriverInfo. A guard band is a rectangle that is potentially larger than the viewport (and even the render target), to which vertices can be clipped automatically by the driver. The Microsoft Direct3D clipping code clips to this rectangle instead of to the viewport. By allowing the driver to specify potentially large guard band rectangles, the need to generate new vertices due to clipping is reduced. One example is a hardware device that can correctly render as long as screen x and y coordinates fall in the range -2048 through 2047.

Guard band clipping is also beneficial for anti-aliasing hardware, because the filter area can extend outside the rendering surface extent. This reduces filtering errors that can be introduced if primitives are geometrically clipped to this extent.

To do the correct clipping, the driver is passed the viewport information. This specifies the actual viewport that the application requires the geometry to be clipped to. Driver writers who do not want to implement guard band clipping can ignore this information. It is recommended that drivers do not use this data to implement clipping through scissors or masking operations because these are likely to be slower than letting Direct3D do the clipping.

Send comments about this topic to Microsoft

© 2017 Microsoft