Sam Hocevar
|
6faf4ee067
|
base: roll our own constants because it’s always a pain in the ass
to get M_PI from the platform headers and cast it to float.
|
pirms 12 gadiem |
Sam Hocevar
|
d6634da83f
|
build: fix the WTFPL site URL in all code comments.
|
pirms 12 gadiem |
Sam Hocevar
|
28728814cc
|
core: replace usage of sin() or std::sin() with lol::sin() where appropriate.
|
pirms 12 gadiem |
Sam Hocevar
|
56e4332597
|
build: reorganise math files in a single "math" directory, and get rid of the
"shader" source directory since we have "gpu".
|
pirms 13 gadiem |
Sam Hocevar
|
0303a8384f
|
win32: fix Visual Studio compilation and link issues.
|
pirms 13 gadiem |
Sam Hocevar
|
14a3e1f739
|
core: fix a bug on the PS3 version of lol_sin().
|
pirms 13 gadiem |
Sam Hocevar
|
b3e2429b9e
|
core: avoid returning to memory when giving GCC floating point hints.
|
pirms 13 gadiem |
Sam Hocevar
|
320e70d8c4
|
core: a few compilation fixes for non-GCC compilers.
|
pirms 13 gadiem |
Sam Hocevar
|
5feadd8b6a
|
core: fix PS3 compilation; the lol_fdiv implementation was missing.
|
pirms 13 gadiem |
Sam Hocevar
|
bf164def53
|
core: fix an accuracy error in the cos() part of lol_sincos().
|
pirms 13 gadiem |
Sam Hocevar
|
2489233a44
|
core: improve tan() accuracy by tweaking higher order Taylor coefficients.
|
pirms 13 gadiem |
Sam Hocevar
|
82d81256b9
|
core: implement accelerated lol_sincos() and lol_tan().
|
pirms 13 gadiem |
Sam Hocevar
|
5be195a8b0
|
core: slightly reorganise Taylor series in sin() and cos().
|
pirms 13 gadiem |
Sam Hocevar
|
49f9c59ff3
|
core: implement accelerated cos().
|
pirms 13 gadiem |
Sam Hocevar
|
a65c472ffd
|
core: add a code shortcut for sin() on platforms that have cheap branches.
|
pirms 13 gadiem |
Sam Hocevar
|
824551e4af
|
optim: split the Taylor series calculation into two separate values.
This is at the cost of one additional multiply, but performance increases
by more than 11%, because the PS3 pipeline is a lot happier now.
|
pirms 13 gadiem |
Sam Hocevar
|
de496b15fe
|
core: remove one multiplication and one selection from the optimised
version of sinf().
|
pirms 13 gadiem |
Sam Hocevar
|
42b22f1163
|
core: minor optimisation in the x86 version of lol_sin()
Instead of dividing by 2 and rounding with magic number 2^52, we round with
magic number 2^53, which gives us the parity with at least one mul less.
|
pirms 13 gadiem |
Sam Hocevar
|
1b33a7fcb7
|
core: start implementing optimised trigonometry functions for PS3 and x86.
|
pirms 13 gadiem |