3 ms·
That really just needs some whitespace. Vec w=nl, u=((fabs(w.x) > .1 ? Vec(0,1) : Vec(1)) % w).norm(), v=w%u; Simple, right? I can see ho
by TillE 10y ago
That really just needs some whitespace.
Vec w=nl,
u=((fabs(w.x) > .1 ? Vec(0,1) : Vec(1)) % w).norm(),
v=w%u;
Simple, right? I can see how it would look like garbage if you miss the three separate variables being initialized, but that should be familiar to most people with C/C++ experience.
- strainer 10y ago% being overloaded as vector cross product is a bit mysterious here (until investigating Vec's definition) It might be helpful if the instantiations were written fully too, ie. Vec(0,1,0) : Vec(1,0,0)