2 ms·
Step vs ternary op vs if statement are equivalent - you are correct in that. What I'm saying is not about optimization or assembly - optimization doesn't matter
by torginus 2y ago
Step vs ternary op vs if statement are equivalent - you are correct in that. What I'm saying is not about optimization or assembly - optimization doesn't matter when the end result looks bad.
What I'm saying that no matter how you express it in code, abrupt transitions of values introduce aliasing (or 'edge shimmer'), which looks unpleaseant. The way you get rid of it by smoothly blending between 2 values with smoothstep for example.
- grg0 2y ago[dead]