[PATCH 1/5] d3dcompiler: Store the swizzle unshifted.

Francois Gouget fgouget at free.fr
Sat Feb 15 06:12:05 CST 2020


It was already the case before but this patch made it more obvious (at 
least to my simple script).

Both BWRITERVS_X_X and D3DVS_X_X are 0:

#define BWRITERVS_X_X   (0)
#define D3DVS_X_X       (0 << D3DVS_SWIZZLE_SHIFT)

So this line in d3d9_swizzle() from dlls/d3dcompiler_43/bytecodewriter.c 
does nothing at all:

    if ((bwriter_swizzle & BWRITERVS_X_X) == BWRITERVS_X_X) ret |= D3DVS_X_X;

Just to be sure, is this really what was intended?
I guess having this line is nice for symmetry with the ones that follow 
but would it be better / less confusing to comment it out?

-- 
Francois Gouget <fgouget at free.fr>              http://fgouget.free.fr/
  Any sufficiently advanced Operating System is indistinguishable from Linux



More information about the wine-devel mailing list