[Mesa-dev] [PATCH 1/9] gallium: decrease the size of pipe_rasterizer_state - 36 -> 32 bytes

Marek Olšák maraeo at gmail.com
Sun Apr 2 18:00:22 UTC 2017


From: Marek Olšák <marek.olsak at amd.com>

---
 src/gallium/include/pipe/p_state.h | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/gallium/include/pipe/p_state.h b/src/gallium/include/pipe/p_state.h
index ce19b92..5d995dc 100644
--- a/src/gallium/include/pipe/p_state.h
+++ b/src/gallium/include/pipe/p_state.h
@@ -151,21 +151,27 @@ struct pipe_rasterizer_state
     * This applies to both user clip planes and shader clip distances.
     * Note that if the bound shader exports any clip distances, these
     * replace all user clip planes, and clip half-spaces enabled here
     * but not written by the shader count as disabled.
     */
    unsigned clip_plane_enable:PIPE_MAX_CLIP_PLANES;
 
    unsigned line_stipple_factor:8;  /**< [1..256] actually */
    unsigned line_stipple_pattern:16;
 
-   uint32_t sprite_coord_enable; /* referring to 32 TEXCOORD/GENERIC inputs */
+   /**
+    * Replace the given TEXCOORD inputs with point coordinates, max. 8 inputs.
+    * If TEXCOORD (including PCOORD) are unsupported, replace GENERIC inputs
+    * instead. Max. 9 inputs: 8x GENERIC to emulate TEXCOORD, and 1x GENERIC
+    * to emulate PCOORD.
+    */
+   uint16_t sprite_coord_enable; /* 0-7: TEXCOORD/GENERIC, 8: PCOORD */
 
    float line_width;
    float point_size;           /**< used when no per-vertex size */
    float offset_units;
    float offset_scale;
    float offset_clamp;
 };
 
 
 struct pipe_poly_stipple
-- 
2.7.4



More information about the mesa-dev mailing list