Doing some research into antialiasing methods, I stumbled upon this piece of code (grabbed from Nvidia's FXAA shader):
if(!pairN) lumaN = lumaS; if(!pairN) gradientN = gradientS; if(!pairN) lengthSign *= -1.0; Is there a good reason it's not written as the following instead?
if (!pairN) { lumaN = lumaS; gradientN = gradientS; lengthSign *= -1.0; } I assume it's an optimization of some sort? Just seems really counterintuitive...