summaryrefslogtreecommitdiff
path: root/src/gallium/docs
diff options
context:
space:
mode:
authorRoland Scheidegger <sroland@vmware.com>2010-02-09 19:32:21 +0100
committerRoland Scheidegger <sroland@vmware.com>2010-02-09 19:32:21 +0100
commit653a83445f94620673f747a4ace6847a2c7fdb4d (patch)
treee2c6814da8d809813daffce530b37f3d283e96ff /src/gallium/docs
parentb0613d87672ea08bb3b9cd56dee714fe413b670e (diff)
parentdd7be07c9685012b3e9fdfbaa13dc638abf6a9d1 (diff)
Merge branch 'gallium-nopointsizeminmax'
Conflicts: src/gallium/drivers/nv10/nv10_state.c src/gallium/drivers/nv20/nv20_state.c src/gallium/drivers/nv50/nv50_program.c
Diffstat (limited to 'src/gallium/docs')
-rw-r--r--src/gallium/docs/source/cso/rasterizer.rst32
-rw-r--r--src/gallium/docs/source/tgsi.rst6
2 files changed, 23 insertions, 15 deletions
diff --git a/src/gallium/docs/source/cso/rasterizer.rst b/src/gallium/docs/source/cso/rasterizer.rst
index bfa4a1170a..24cc78c68d 100644
--- a/src/gallium/docs/source/cso/rasterizer.rst
+++ b/src/gallium/docs/source/cso/rasterizer.rst
@@ -119,18 +119,20 @@ point_size_per_vertex
Whether vertices have a point size element.
point_size
The size of points, if not specified per-vertex.
-point_size_min
- The minimum size of points.
-point_size_max
- The maximum size of points.
-point_sprite
- Whether points are drawn as sprites (textured quads)
+sprite_coord_enable
+ Specifies if a coord has its texture coordinates replaced or not. This
+ is a packed bitfield containing the enable for all coords - if all are 0
+ point sprites are effectively disabled, though points may still be
+ rendered slightly different according to point_quad_rasterization.
+ If any coord is non-zero, point_smooth should be disabled, and
+ point_quad_rasterization enabled.
+ If enabled, the four vertices of the resulting quad will be assigned
+ texture coordinates, according to sprite_coord_mode.
sprite_coord_mode
Specifies how the value for each shader output should be computed when
- drawing sprites. If PIPE_SPRITE_COORD_NONE, don't change the vertex
- shader output. Otherwise, the four vertices of the resulting quad will
- be assigned texture coordinates. For PIPE_SPRITE_COORD_LOWER_LEFT, the
- lower left vertex will have coordinate (0,0,0,1).
+ drawing sprites, for each coord which has sprite_coord_enable set.
+ For PIPE_SPRITE_COORD_LOWER_LEFT, the lower left vertex will have
+ coordinate (0,0,0,1).
For PIPE_SPRITE_COORD_UPPER_LEFT, the upper-left vertex will have
coordinate (0,0,0,1).
This state is needed by :ref:`Draw` because that's where each
@@ -139,7 +141,15 @@ sprite_coord_mode
sprite rendering.
Note that when geometry shaders are available, this state could be
removed. A special geometry shader defined by the state tracker could
- converts the incoming points into quads with the proper texture coords.
+ convert the incoming points into quads with the proper texture coords.
+point_quad_rasterization
+ This determines if points should be rasterized as quads or points.
+ d3d always uses quad rasterization for points, regardless if point sprites
+ are enabled or not, but OGL has different rules. If point_quad_rasterization
+ is set, point_smooth should be disabled, and points will be rendered as
+ squares even if multisample is enabled.
+ sprite_coord_enable should be zero if point_quad_rasterization is not
+ enabled.
scissor
Whether the scissor test is enabled.
diff --git a/src/gallium/docs/source/tgsi.rst b/src/gallium/docs/source/tgsi.rst
index fc5482d384..c292cd37d5 100644
--- a/src/gallium/docs/source/tgsi.rst
+++ b/src/gallium/docs/source/tgsi.rst
@@ -1380,10 +1380,8 @@ TGSI_SEMANTIC_PSIZE
"""""""""""""""""""
PSIZE, or point size, is used to specify point sizes per-vertex. It should
-be in ``(p, n, x, f)`` format, where ``p`` is the point size, ``n`` is the minimum
-size, ``x`` is the maximum size, and ``f`` is the fade threshold.
-
-XXX this is arb_vp. is this what we actually do? should double-check...
+be in ``(s, 0, 0, 1)`` format, where ``s`` is the (possibly clamped) point size.
+Only the first component matters when writing from the vertex shader.
When using this semantic, be sure to set the appropriate state in the
:ref:`rasterizer` first.