static GLushort *radeonAllocElts( r100ContextPtr rmesa, GLuint nr ) { if (rmesa->radeon.dma.flush) rmesa->radeon.dma.flush( rmesa->radeon.glCtx ); radeonEmitAOS( rmesa, rmesa->radeon.tcl.aos_count, 0 ); return radeonAllocEltsOpenEnded( rmesa, rmesa->tcl.vertex_format, rmesa->tcl.hw_primitive, nr ); }
static GLushort *radeonAllocElts( radeonContextPtr rmesa, GLuint nr ) { if (rmesa->dma.flush) rmesa->dma.flush( rmesa ); radeonEnsureCmdBufSpace(rmesa, AOS_BUFSZ(rmesa->tcl.nr_aos_components) + rmesa->hw.max_state_size + ELTS_BUFSZ(nr)); radeonEmitAOS( rmesa, rmesa->tcl.aos_components, rmesa->tcl.nr_aos_components, 0 ); return radeonAllocEltsOpenEnded( rmesa, rmesa->tcl.vertex_format, rmesa->tcl.hw_primitive, nr ); }
/* TODO: Try to extend existing primitive if both are identical, * discrete and there are no intervening state changes. (Somewhat * duplicates changes to DrawArrays code) */ static void radeonEmitPrim( struct gl_context *ctx, GLenum prim, GLuint hwprim, GLuint start, GLuint count) { r100ContextPtr rmesa = R100_CONTEXT( ctx ); radeonTclPrimitive( ctx, prim, hwprim ); radeonEmitAOS( rmesa, rmesa->radeon.tcl.aos_count, start ); /* Why couldn't this packet have taken an offset param? */ radeonEmitVbufPrim( rmesa, rmesa->tcl.vertex_format, rmesa->tcl.hw_primitive, count - start ); }
/* TODO: Try to extend existing primitive if both are identical, * discrete and there are no intervening state changes. (Somewhat * duplicates changes to DrawArrays code) */ static void radeonEmitPrim( GLcontext *ctx, GLenum prim, GLuint hwprim, GLuint start, GLuint count) { radeonContextPtr rmesa = RADEON_CONTEXT( ctx ); radeonTclPrimitive( ctx, prim, hwprim ); radeonEnsureCmdBufSpace( rmesa, AOS_BUFSZ(rmesa->tcl.nr_aos_components) + rmesa->hw.max_state_size + VBUF_BUFSZ ); radeonEmitAOS( rmesa, rmesa->tcl.aos_components, rmesa->tcl.nr_aos_components, start ); /* Why couldn't this packet have taken an offset param? */ radeonEmitVbufPrim( rmesa, rmesa->tcl.vertex_format, rmesa->tcl.hw_primitive, count - start ); }