GLuint min_index,
GLuint max_index)
{
+ struct split_limits limits;
GLboolean retval;
+ limits.max_verts = 65535;
+ limits.max_indices = 65535;
+ limits.max_vb_size = 1024*1024;
+
if (min_index) {
vbo_rebase_prims( ctx, arrays, prim, nr_prims, ib, min_index, max_index, r300DrawPrims );
return;
}
+ if ((ib && ib->count > 65536)) {
+ vbo_split_prims (ctx, arrays, prim, nr_prims, ib, min_index, max_index, r300DrawPrims, &limits);
+ return;
+ }
/* Make an attempt at drawing */
retval = r300TryDrawPrims(ctx, arrays, prim, nr_prims, ib, min_index, max_index);
fprintf(stderr, "%s: nr=%d, ofs=0x%08x\n", __FUNCTION__, nr,
offset);
-
if (!rmesa->radeon.radeonScreen->kernel_mm) {
BEGIN_BATCH(sz+2+(nr * 2));
OUT_BATCH_PACKET3(R300_PACKET3_3D_LOAD_VBPNTR, sz - 1);
* arrays. *sigh*
*/
r300EmitElts(ctx, num_verts);
- r300EmitAOS(rmesa, rmesa->radeon.tcl.aos_count, start);
+ /* don't pass start if we are split up */
+ r300EmitAOS(rmesa, rmesa->radeon.tcl.aos_count, 0);
if (rmesa->radeon.radeonScreen->kernel_mm) {
BEGIN_BATCH_NO_AUTOSTATE(2);
OUT_BATCH_REGSEQ(R300_VAP_VF_MAX_VTX_INDX, 1);