[1/7] [wined3d] add ps_np2fixup_t struct to ps_compiled_shader

Tobias Jakobi liquid.acid at gmx.net
Wed Apr 22 13:07:54 CDT 2009

Henri Verbeet wrote:
> Tex fixup parameter for tex1 would have idx 0, the one for tex3 would
> have idx 1. These would then be packed as PsamplerNP2Fixup0.xy and
> PsamplerNP2Fixup0.zw.

OK, forget that as well.

Like I replied to Stefan about the uchar thing: The code is only active
for FX cards which have a constant limit of 256. (or it could become
active for cards below a FX)

With the approach without swz, this would mean changing the unsigned
char array to a unsigned short one, which would double the size.

I tried to keep the whole struct as small as possible, the current size
if now 20 bytes (16 bytes for the indices, and 4 bytes for swz and

Adding the code for ARB would introduce 2 additional bytes (active
bitflag, since we can figure out quite well if there are still enough
free constants in ARB), but that's it.

Performancewise the current approach shouldn't be a problem. I think we
should focus on size here, and that's why I don't think changing this
will do any good.

More information about the wine-devel mailing list