最近真是发狠写了一堆文啊...XD
正弦(sine)和余弦(cosine)
是两个游戏逻辑常常用到的函式
然而它们的效能往往不佳
本文示范如何使用之前介绍的多项式近似技巧
实作比std::sin和std::cos快的版本
(在我的电脑上测试约是3.5倍快)
http://allenchou.net/2014/02/game-math-faster-sine-cosine/
[追加]
本技巧也可用来近似 1/sqrt(x)
用来快速re-normalize长度接近一的向量
http://allenchou.net/2014/02/game-math-fast-re-normalization-of-unit-vectors/
系列文目录 http://allenchou.net/game-math-series/