summaryrefslogtreecommitdiff
path: root/src/mesa/pipe/draw/draw_vertex.c
diff options
context:
space:
mode:
authorBrian <brian.paul@tungstengraphics.com>2007-08-31 11:27:16 -0600
committerBrian <brian.paul@tungstengraphics.com>2007-08-31 11:27:16 -0600
commit2e21058e3d2c484b282cbc0bb5e7169b9a8d4fc7 (patch)
tree240d5bbd4a45a98e19d104f62e7e3a687209ca1e /src/mesa/pipe/draw/draw_vertex.c
parent898d68a3762f84f0d435cda2f6aafddd356d1788 (diff)
Define attrib_format and interp_mode enum typedefs and use where appropriate.
Diffstat (limited to 'src/mesa/pipe/draw/draw_vertex.c')
-rw-r--r--src/mesa/pipe/draw/draw_vertex.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mesa/pipe/draw/draw_vertex.c b/src/mesa/pipe/draw/draw_vertex.c
index 64bc323207..1c7e1d8662 100644
--- a/src/mesa/pipe/draw/draw_vertex.c
+++ b/src/mesa/pipe/draw/draw_vertex.c
@@ -45,8 +45,8 @@
static INLINE void
-emit_vertex_attr(struct vertex_info *vinfo, uint vfAttr, uint format,
- uint interp)
+emit_vertex_attr(struct vertex_info *vinfo, uint vfAttr,
+ attrib_format format, interp_mode interp)
{
const uint n = vinfo->num_attribs;
vinfo->attr_mask |= (1 << vfAttr);
@@ -59,7 +59,6 @@ emit_vertex_attr(struct vertex_info *vinfo, uint vfAttr, uint format,
vinfo->interp_mode[n] = interp;
vinfo->format[n] = format;
vinfo->num_attribs++;
-
}
@@ -89,6 +88,7 @@ draw_compute_vertex_size(struct vertex_info *vinfo)
vinfo->size += 3;
break;
case FORMAT_4F:
+ case FORMAT_4F_VIEWPORT:
vinfo->size += 4;
break;
default:
@@ -104,7 +104,7 @@ draw_compute_vertex_size(struct vertex_info *vinfo)
void
draw_set_vertex_attributes( struct draw_context *draw,
const uint *slot_to_vf_attr,
- const uint *interp_mode,
+ const interp_mode *interps,
unsigned nr_attrs )
{
struct vertex_info *vinfo = &draw->vertex_info;
@@ -125,7 +125,7 @@ draw_set_vertex_attributes( struct draw_context *draw,
* Remaining attribs (color, texcoords, etc)
*/
for (i = 1; i < nr_attrs; i++) {
- emit_vertex_attr(vinfo, slot_to_vf_attr[i], FORMAT_4F, interp_mode[i]);
+ emit_vertex_attr(vinfo, slot_to_vf_attr[i], FORMAT_4F, interps[i]);
}
draw_compute_vertex_size(vinfo);