[PATCH xf86-video-ati resend 1/2] EXA/6xx/7xx: fast solid pixmap support

Michel Dänzer michel at daenzer.net
Tue May 31 09:01:59 UTC 2016


On 27.05.2016 18:05, Tan Hu wrote:
> Solid pixmaps are currently implemented with scratch pixmaps, which
> is slow. This replaces the hack with a proper implementation. The
> Composite shader can now either sample a src/mask or use a constant
> value.
> 
> r6xx still be used on some machine,
> Ported from commit 94d0d14914a025525a0766669b556eaa6681def7.
> 
> Signed-off-by: Tan Hu <tan.hu at zte.com.cn>

[...]

> @@ -1251,19 +1358,19 @@ static Bool R600PrepareComposite(int op, PicturePtr pSrcPicture,
>  	    accel_state->src_alpha = FALSE;
>  	}
>      } else {
> -	if (!R600SetAccelState(pScrn,
> -			       &src_obj,
> -			       NULL,
> -			       &dst_obj,
> -			       accel_state->comp_vs_offset, accel_state->comp_ps_offset,
> -			       3, 0xffffffff))
> -	    return FALSE;
> -
>  	accel_state->msk_pic = NULL;
>  	accel_state->component_alpha = FALSE;
>  	accel_state->src_alpha = FALSE;
>      }
>  
> +    if (!R600SetAccelState(pScrn,
> +		pSrc ? &src_obj : NULL,
> +		(pMaskPicture && pMask) ? &mask_obj : NULL,
> +		&dst_obj,
> +		accel_state->comp_vs_offset, accel_state->comp_ps_offset,
> +		3, 0xffffffff))
> +	return FALSE;

The second and following lines of the if statement look to be indented
by two tabs, should be only one.


> +	R600SetSolidConsts(pScrn, &ps_alu_consts[0], pSrcPicture->format,
> +		pSrcPicture->pSourcePict->solidFill.color, 0);
[...]
> +	R600SetSolidConsts(pScrn, &ps_alu_consts[4], pMaskPicture->format,
> +		pMaskPicture->pSourcePict->solidFill.color, 1);

The second lines of the R600SetSolidConsts calls aren't aligned with the
opening parentheses.


There may be more similar indentation problems that I missed.


-- 
Earthling Michel Dänzer               |               http://www.amd.com
Libre software enthusiast             |             Mesa and X developer


More information about the xorg-driver-ati mailing list