summaryrefslogtreecommitdiff
path: root/src/mesa/drivers
diff options
context:
space:
mode:
authorDave Airlie <airlied@panoply-rh.(none)>2008-04-18 15:14:48 +1000
committerDave Airlie <airlied@panoply-rh.(none)>2008-04-18 15:14:48 +1000
commitfda4895d26eec6d810da51a6c023a5459230ff6a (patch)
tree88eda73aebfbe529ebfbbdf0bd0dbae11a43bd4d /src/mesa/drivers
parente92e3848e7c8c1481e785973d8609072f2f5db21 (diff)
i965: fix vb aperture space check
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r--src/mesa/drivers/dri/i965/brw_draw_upload.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_draw_upload.c b/src/mesa/drivers/dri/i965/brw_draw_upload.c
index 78677df6c0..aa985d68b6 100644
--- a/src/mesa/drivers/dri/i965/brw_draw_upload.c
+++ b/src/mesa/drivers/dri/i965/brw_draw_upload.c
@@ -315,7 +315,7 @@ int brw_prepare_vertices( struct brw_context *brw,
GLuint i;
const unsigned char *ptr = NULL;
GLuint interleave = 0;
- int ret;
+ int ret = 0;
struct brw_vertex_element *enabled[VERT_ATTRIB_MAX];
GLuint nr_enabled = 0;
@@ -362,6 +362,8 @@ int brw_prepare_vertices( struct brw_context *brw,
dri_bo_reference(input->bo);
input->offset = (unsigned long)input->glarray->Ptr;
input->stride = input->glarray->StrideB;
+
+ ret |= dri_bufmgr_check_aperture_space(input->bo);
} else {
/* Queue the buffer object up to be uploaded in the next pass,
* when we've decided if we're doing interleaved or not.
@@ -419,11 +421,13 @@ int brw_prepare_vertices( struct brw_context *brw,
}
if (brw->vb.upload.bo) {
- ret = dri_bufmgr_check_aperture_space(brw->vb.upload.bo);
- if (ret)
- return 1;
+ ret |= dri_bufmgr_check_aperture_space(brw->vb.upload.bo);
}
+ if (ret)
+ return 1;
+
+
return 0;
}