Not sure why you mask away many of the bits here? I think we need to take them all into account (I believe the blendfuncs are 4 bits). Same with Eq (but it's only 3 bits).