summaryrefslogtreecommitdiffstats
path: root/examples/positioning
diff options
context:
space:
mode:
authorEdward Welbourne <edward.welbourne@qt.io>2017-03-06 17:36:46 +0100
committerEdward Welbourne <edward.welbourne@qt.io>2017-03-21 13:23:11 +0000
commit22090b374f1f6e53a28188f91cca8b860c859555 (patch)
treebdd132c76215eb9dddf15fa151f1cb2590c86f9e /examples/positioning
parenta30343fe6aa4c15fcee4a14eabe45473a88056db (diff)
Simplify a mathematical expression
Squaring a number, doubling it and taking the square root is just a roundabout way of multiplying the number by sqrt(2); so do that instead, saving some computational cost and probably reducing the amount of rounding errors that can creep in. Change-Id: I1abf3c2de318f48f80536379156ace8f25a6acaf Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
Diffstat (limited to 'examples/positioning')
0 files changed, 0 insertions, 0 deletions