txf = ps->fmt;
txf |= tf->format | 0x8000;
- txf |= ((pt->last_level - pt->first_level + 1) <<
- NV40TCL_TEX_FORMAT_MIPMAP_COUNT_SHIFT);
+ txf |= ((pt->last_level + 1) << NV40TCL_TEX_FORMAT_MIPMAP_COUNT_SHIFT);
if (1) /* XXX */
txf |= NV40TCL_TEX_FORMAT_NO_BORDER;
txs = tf->swizzle;
so = so_new(16, 2);
- so_method(so, nv40->curie, NV40TCL_TEX_OFFSET(unit), 8);
+ so_method(so, nv40->hw->curie, NV40TCL_TEX_OFFSET(unit), 8);
so_reloc (so, nv40mt->buffer, 0, tex_flags | NOUVEAU_BO_LOW, 0, 0);
so_reloc (so, nv40mt->buffer, txf, tex_flags | NOUVEAU_BO_OR,
NV40TCL_TEX_FORMAT_DMA0, NV40TCL_TEX_FORMAT_DMA1);
so_data (so, ps->wrap);
- so_data (so, NV40TCL_TEX_ENABLE_ENABLE | ps->en |
- (0x00078000) /* mipmap related? */);
+ so_data (so, NV40TCL_TEX_ENABLE_ENABLE | ps->en);
so_data (so, txs);
- so_data (so, ps->filt | 0x3fd6 /*voodoo*/);
+ so_data (so, ps->filt | 0x2000 /*voodoo*/);
so_data (so, (pt->width[0] << NV40TCL_TEX_SIZE0_W_SHIFT) |
pt->height[0]);
so_data (so, ps->bcol);
- so_method(so, nv40->curie, NV40TCL_TEX_SIZE1(unit), 1);
+ so_method(so, nv40->hw->curie, NV40TCL_TEX_SIZE1(unit), 1);
so_data (so, (pt->depth[0] << NV40TCL_TEX_SIZE1_DEPTH_SHIFT) | txp);
so_emit(nv40->nvws, so);
so_ref (so, &nv40->so_fragtex[unit]);
+ so_ref (NULL, &so);
}
void