Generation of jittered sub-pixel samples using programmable sub-pixel offsets
AssigneeNVIDIA Corporation
InventorsRui M. Bastos, Nathan A. Carr
Life of this patent
Estimating the term…
Abstract
Jittered sub-pixel samples are used to reduce aliasing during rendering in a graphics pipeline. Sub-pixel samples are jittered using programmed sub-pixel offset values, permitting an application to select not only the number of sub-pixel samples within a pixel, but also the position of each sub-pixel sample within the pixel.
Claims17
A programmable graphics processor for generating anti-aliased images utilizing a non-periodic jitter pattern that varies from pixel to pixel, comprising:
- a storage element configured to store programmed sub-pixel offset values, wherein the number of sub-pixel offset values stored is dependent on the resolution of the image to be displayed;
- an offset access unit coupled to the storage element, the offset access unit configured to read a portion of the sub-pixel offset values based on at least a portion of the coordinates of a pixel position;
- a sample computation unit configured to combine the pixel position and the portion of the programmed sub-pixel offset values, read from the storage element, dependent on the resolution of the image to be displayed to produce a jittered sub-pixel sample position for each and every sub-pixel sample cell within each pixel of an antialiased image so that the jitter pattern is effectively non-periodic, but is antialiased consistently from frame to frame, each sub-pixel offset value being either added to or subtracted from the pixel position coordinate to establish the sub-pixel sample position based on whether the sub-pixel sample position is in the left or right half of the cell;
- a rasterizer configured to produce sub-pixel coverage data associated with a fragment using the jittered sub-pixel sample positions;
- a shader configured to compute a depth value corresponding to the fragment depth at the pixel position;
- and
- a raster operations unit configured to produce sub-pixel depth values using the depth value corresponding to the fragment depth at the pixel position and the jittered sub-pixel sample positions.
A method of determining sub-pixel sample positions for a pixel position to reduce aliasing utilizing a non-periodic jitter pattern that varies from pixel to pixel, the method comprising:
- determining pixel positions for a plurality of pixels in an image;
- determining a plurality of sub-pixel sample cells for each of the pixels;
- storing a number of sub-pixel offset values, wherein the number of sub-pixel offset values stored is dependent on the resolution of the image to be displayed;
- selecting a sub-pixel offset value for each and every one of the sub-pixel sample cells within each of the pixels based on the pixel positions, wherein the stored sub-pixel offset values are accessed using selected bits of the pixel position coordinates;
- combining the selected sub-pixel offset values with the pixel positions to determine a sub-pixel sample pattern defining the location of each cell of the plurality of sub-pixel sample cells based on the pixel position being sampled, each sub-pixel offset value being either added to or subtracted from the pixel position coordinate to establish the sub-pixel sample position based on whether the sub-pixel sample position is in the left or right half of the cell;
- and
- rendering graphics primitives representing the image using the sub-pixel sample pattern to produce an anti-aliased image for display, wherein the sub-pixel sample pattern used is non-periodic so that the jitter pattern is non-periodic, but is antialiased consistently from frame to frame.
Dependencies are inferred from the claim text.