On 12/13/2011 01:19 PM, Eric Anholt wrote:
> On Thu, 8 Dec 2011 17:08:04 -0800, Kenneth Graunke <[email protected]>
> wrote:
>> Signed-off-by: Kenneth Graunke <[email protected]>
>> + if (one_mask) {
>> + swizzled_result.writemask = one_mask;
>> + emit(MOV(swizzled_result, src_reg(1.0f)));
>> + }
>> }
>
> I think this would be wrong for SWIZZLE_ONE of integer textures.
My tests indicate that it works. swizzled_result gets the appropriate
register type, so this ends up being something like:
mov(8) m4<1>.ywUD 1F { align16 WE_normal 1Q };
and the MOV instruction does the float->int conversion for us.
Is that okay? If not, what would you prefer?
_______________________________________________
mesa-dev mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-dev