[Mesa-dev] [PATCH 14/20] i915: Use COPY_DWORDS for points

ville.syrjala at linux.intel.com ville.syrjala at linux.intel.com
Mon Mar 23 05:47:30 PDT 2015


From: Ville Syrjälä <ville.syrjala at linux.intel.com>

The sub-pixel adjustment for points was killed off in
 commit 60d762aa625095a8c1f9597d8530bb5a6fa61b4c
 Author: Xiang, Haihao <haihao.xiang at intel.com>
 Date:   Wed Jan 2 11:38:51 2008 +0800

    i915: Needn't adjust pixel centers. fix #12944

so we can just as well use COPY_DWORDS().

Signed-off-by: Ville Syrjälä <ville.syrjala at linux.intel.com>
---
 src/mesa/drivers/dri/i915/intel_tris.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/src/mesa/drivers/dri/i915/intel_tris.c b/src/mesa/drivers/dri/i915/intel_tris.c
index 2d91ca8..e46b142 100644
--- a/src/mesa/drivers/dri/i915/intel_tris.c
+++ b/src/mesa/drivers/dri/i915/intel_tris.c
@@ -457,11 +457,7 @@ intel_draw_point(struct intel_context *intel, intelVertexPtr v0)
    GLuint *vb = intel_get_prim_space(intel, 1);
    int j;
 
-   /* Adjust for sub pixel position -- still required for conform. */
-   *(float *) &vb[0] = v0->v.x;
-   *(float *) &vb[1] = v0->v.y;
-   for (j = 2; j < vertsize; j++)
-      vb[j] = v0->ui[j];
+   COPY_DWORDS(j, vb, vertsize, v0);
 }
 
 
-- 
2.0.5



More information about the mesa-dev mailing list