BEGIN_CS((8 * fb->nr_cbufs) + (fb->zsbuf ? 8 : 0) + 4);
for (i = 0; i < fb->nr_cbufs; i++) {
tex = (struct r300_texture*)fb->cbufs[i]->texture;
+ assert(tex && tex->buffer && "cbuf is marked, but NULL!");
pixpitch = tex->stride / tex->tex.block.size;
OUT_CS_REG_SEQ(R300_RB3D_COLOROFFSET0 + (4 * i), 1);
if (fb->zsbuf) {
tex = (struct r300_texture*)fb->zsbuf->texture;
- pixpitch = (tex->stride / tex->tex.block.size);
+ assert(tex && tex->buffer && "zsbuf is marked, but NULL!");
+ pixpitch = tex->stride / tex->tex.block.size;
OUT_CS_REG_SEQ(R300_ZB_DEPTHOFFSET, 1);
OUT_CS_RELOC(tex->buffer, 0, 0, RADEON_GEM_DOMAIN_VRAM, 0);
/* ...textures... */
for (i = 0; i < r300->texture_count; i++) {
tex = r300->textures[i];
- assert(tex && tex->buffer && "zsbuf is marked, but NULL!");
+ assert(tex && tex->buffer && "texture is marked, but NULL!");
r300->winsys->add_buffer(r300->winsys, tex->buffer,
RADEON_GEM_DOMAIN_GTT | RADEON_GEM_DOMAIN_VRAM, 0);
}
if (r300_screen(r300->context.screen)->caps->has_tcl) {
/* Do the transform in HW. */
- r300->viewport_state->vte_control = R300_VTX_W0_FMT;
+ r300->viewport_state->vte_control = R300_VTX_XY_FMT | R300_VTX_Z_FMT;
if (state->scale[0] != 1.0f) {
assert(state->scale[0] != 0.0f);
r300_emit_rs_block_state(r300, &r300_rs_block_copy_state);
}
+ BEGIN_CS(28);
/* VAP stream control, mapping from input memory to PVS/RS memory */
if (caps->has_tcl) {
OUT_CS_REG(R300_VAP_PROG_STREAM_CNTL_0,
OUT_CS_REG(R300_RB3D_DSTCACHE_CTLSTAT, 0xA);
+ END_CS;
+
r300->dirty_hw++;
}