diff options
author | Zack Rusin <[email protected]> | 2013-06-10 23:36:59 -0400 |
---|---|---|
committer | Zack Rusin <[email protected]> | 2013-06-13 12:13:11 -0400 |
commit | 5507c11f85dda4fbcdc9b36494551c933471a070 (patch) | |
tree | ded8a6152801200b5b6d79f02a180f838e7af763 /src/gallium/docs/source | |
parent | b63eeaf7b7df83a2c52c5ddb701454fd8a49b987 (diff) |
gallium/draw: add limits to the clip and cull distances
There are strict limits on those registers. Define the maximums
and use them instead of magic numbers. Also allows us to add
some extra sanity checks.
Suggested by Brian.
Signed-off-by: Zack Rusin <[email protected]>
Reviewed-by: Roland Scheidegger <[email protected]>
Reviewed-by: Jose Fonseca <[email protected]>
Diffstat (limited to 'src/gallium/docs/source')
-rw-r--r-- | src/gallium/docs/source/tgsi.rst | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/gallium/docs/source/tgsi.rst b/src/gallium/docs/source/tgsi.rst index f3aebb3b317..3f48b511ee6 100644 --- a/src/gallium/docs/source/tgsi.rst +++ b/src/gallium/docs/source/tgsi.rst @@ -2435,6 +2435,29 @@ float32 signed distance to a plane. Primitives will be completely discarded if the plane distance for all of the vertices in the primitive are < 0. If a vertex has a cull distance of NaN, that vertex counts as "out" (as if its < 0); +The limits on both clip and cull distances are bound +by the PIPE_MAX_CLIP_OR_CULL_DISTANCE_COUNT define which defines +the maximum number of components that can be used to hold the +distances and by the PIPE_MAX_CLIP_OR_CULL_DISTANCE_ELEMENT_COUNT +which specifies the maximum number of registers which can be +annotated with those semantics. + + +TGSI_SEMANTIC_CLIPDIST +"""""""""""""""""""""" + +When components of vertex elements are identified this way, these +values are each assumed to be a float32 signed distance to a plane. +Primitive setup only invokes rasterization on pixels for which +the interpolated plane distances are >= 0. Multiple clip planes +can be implemented simultaneously, by annotating multiple +components of one or more vertex elements with the above specified +semantic. The limits on both clip and cull distances are bound +by the PIPE_MAX_CLIP_OR_CULL_DISTANCE_COUNT define which defines +the maximum number of components that can be used to hold the +distances and by the PIPE_MAX_CLIP_OR_CULL_DISTANCE_ELEMENT_COUNT +which specifies the maximum number of registers which can be +annotated with those semantics. Declaration Interpolate |