nv50: fix constant vtxattr methods
authorChristoph Bumiller <e0425955@student.tuwien.ac.at>
Mon, 18 Jan 2010 20:37:33 +0000 (21:37 +0100)
committerChristoph Bumiller <e0425955@student.tuwien.ac.at>
Mon, 18 Jan 2010 20:40:30 +0000 (21:40 +0100)
This function was untested, sorry.

src/gallium/drivers/nv50/nv50_vbo.c

index b9cf0754b77b3c6f3a334193d6df3c7225a2c691..bfb1b34d27aee58afe0ded3c37c182067be65de9 100644 (file)
@@ -230,25 +230,25 @@ nv50_set_static_vtxattr(struct nv50_context *nv50, unsigned i, void *data)
        switch (nv50->vtxelt[i].nr_components) {
        case 4:
                BEGIN_RING(chan, tesla, NV50TCL_VTX_ATTR_4F_X(i), 4);
-               OUT_RING  (chan, v[0]);
-               OUT_RING  (chan, v[1]);
-               OUT_RING  (chan, v[2]);
-               OUT_RING  (chan, v[3]);
+               OUT_RINGf (chan, v[0]);
+               OUT_RINGf (chan, v[1]);
+               OUT_RINGf (chan, v[2]);
+               OUT_RINGf (chan, v[3]);
                break;
        case 3:
-               BEGIN_RING(chan, tesla, NV50TCL_VTX_ATTR_3F_X(i), 4);
-               OUT_RING  (chan, v[0]);
-               OUT_RING  (chan, v[1]);
-               OUT_RING  (chan, v[2]);
+               BEGIN_RING(chan, tesla, NV50TCL_VTX_ATTR_3F_X(i), 3);
+               OUT_RINGf (chan, v[0]);
+               OUT_RINGf (chan, v[1]);
+               OUT_RINGf (chan, v[2]);
                break;
        case 2:
-               BEGIN_RING(chan, tesla, NV50TCL_VTX_ATTR_2F_X(i), 4);
-               OUT_RING  (chan, v[0]);
-               OUT_RING  (chan, v[1]);
+               BEGIN_RING(chan, tesla, NV50TCL_VTX_ATTR_2F_X(i), 2);
+               OUT_RINGf (chan, v[0]);
+               OUT_RINGf (chan, v[1]);
                break;
        case 1:
-               BEGIN_RING(chan, tesla, NV50TCL_VTX_ATTR_1F(i), 4);
-               OUT_RING  (chan, v[0]);
+               BEGIN_RING(chan, tesla, NV50TCL_VTX_ATTR_1F(i), 1);
+               OUT_RINGf (chan, v[0]);
                break;
        default:
                assert(0);