diff options
-rw-r--r-- | src/radeon_commonfuncs.c | 6 | ||||
-rw-r--r-- | src/radeon_exa_render.c | 4 | ||||
-rw-r--r-- | src/radeon_textured_videofuncs.c | 32 |
3 files changed, 20 insertions, 22 deletions
diff --git a/src/radeon_commonfuncs.c b/src/radeon_commonfuncs.c index 28bb6e56..deea2d22 100644 --- a/src/radeon_commonfuncs.c +++ b/src/radeon_commonfuncs.c @@ -795,10 +795,8 @@ static void FUNC_NAME(RADEONInit3DEngine)(ScrnInfoPtr pScrn) else OUT_ACCEL_REG(RADEON_SE_CNTL_STATUS, RADEON_TCL_BYPASS); OUT_ACCEL_REG(RADEON_SE_COORD_FMT, - RADEON_VTX_XY_PRE_MULT_1_OVER_W0 | - RADEON_VTX_ST0_NONPARAMETRIC | - RADEON_VTX_ST1_NONPARAMETRIC | - RADEON_TEX1_W_ROUTING_USE_W0); + RADEON_VTX_XY_PRE_MULT_1_OVER_W0 | + RADEON_TEX1_W_ROUTING_USE_W0); FINISH_ACCEL(); BEGIN_ACCEL(5); diff --git a/src/radeon_exa_render.c b/src/radeon_exa_render.c index 89c803aa..68f95147 100644 --- a/src/radeon_exa_render.c +++ b/src/radeon_exa_render.c @@ -395,8 +395,8 @@ static Bool FUNC_NAME(R100TextureSetup)(PicturePtr pPict, PixmapPtr pPix, txformat |= RADEON_TXFORMAT_NON_POWER2; txformat |= unit << 24; /* RADEON_TXFORMAT_ST_ROUTE_STQX */ - info->accel_state->texW[unit] = 1; - info->accel_state->texH[unit] = 1; + info->accel_state->texW[unit] = w; + info->accel_state->texH[unit] = h; switch (pPict->filter) { case PictFilterNearest: diff --git a/src/radeon_textured_videofuncs.c b/src/radeon_textured_videofuncs.c index 8ead2a40..227e19ac 100644 --- a/src/radeon_textured_videofuncs.c +++ b/src/radeon_textured_videofuncs.c @@ -398,30 +398,30 @@ FUNC_NAME(RADEONDisplayTexturedVideo)(ScrnInfoPtr pScrn, RADEONPortPrivPtr pPriv srcw = (pPriv->src_w * dstw) / pPriv->dst_w; srch = (pPriv->src_h * dsth) / pPriv->dst_h; + if (isplanar) { /* * Just render a rect (using three coords). - * Filter is a bit a misnomer, it's just texcoords... */ - VTX_OUT_6((float)dstX, (float)(dstY + dsth), - (float)srcX, (float)(srcY + srch), - (float)srcX, (float)(srcY + (srch / 2))); - VTX_OUT_6((float)(dstX + dstw), (float)(dstY + dsth), - (float)(srcX + srcw), (float)(srcY + srch), - (float)(srcX + (srcw / 2)), (float)(srcY + (srch / 2))); - VTX_OUT_6((float)(dstX + dstw), (float)dstY, - (float)(srcX + srcw), (float)srcY, - (float)(srcX + (srcw / 2)), (float)srcY); + VTX_OUT_6((float)dstX, (float)(dstY + dsth), + (float)srcX / pPriv->w, (float)(srcY + srch) / pPriv->h, + (float)srcX / pPriv->w, (float)(srcY + srch) / pPriv->h); + VTX_OUT_6((float)(dstX + dstw), (float)(dstY + dsth), + (float)(srcX + srcw) / pPriv->w, (float)(srcY + srch) / pPriv->h, + (float)(srcX + srcw) / pPriv->w, (float)(srcY + srch) / pPriv->h); + VTX_OUT_6((float)(dstX + dstw), (float)dstY, + (float)(srcX + srcw) / pPriv->w, (float)srcY / pPriv->h, + (float)(srcX + srcw) / pPriv->w, (float)srcY / pPriv->h); } else { /* * Just render a rect (using three coords). */ - VTX_OUT_4((float)dstX, (float)(dstY + dsth), - (float)srcX, (float)(srcY + srch)); - VTX_OUT_4((float)(dstX + dstw), (float)(dstY + dsth), - (float)(srcX + srcw), (float)(srcY + srch)); - VTX_OUT_4((float)(dstX + dstw), (float)dstY, - (float)(srcX + srcw), (float)srcY); + VTX_OUT_4((float)dstX, (float)(dstY + dsth), + (float)srcX / pPriv->w, (float)(srcY + srch) / pPriv->h); + VTX_OUT_4((float)(dstX + dstw), (float)(dstY + dsth), + (float)(srcX + srcw) / pPriv->w, (float)(srcY + srch) / pPriv->h); + VTX_OUT_4((float)(dstX + dstw), (float)dstY, + (float)(srcX + srcw) / pPriv->w, (float)srcY / pPriv->h); } pBox++; |