Commit Graph

6 Commits

Author SHA1 Message Date
cutealien
0c6385cb92 Replace public header guards to avoid using indentifiers reserved by c++
Usually something like __IRR_SOME_GUARD_INCLUDED__ replaced by IRR_SOME_GUARD_INCLUDED.
Removing underscores at the end wasn't necessary, but more symmetric (probably the reason they got added there as well).
While this touches every header it shouldn't affect users (I hope).

Also a few whitespace changes to unify whitespace usage a bit.
And a bunch of spelling fixes in comments.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6252 dfc29bdd-3216-0410-991c-e03cc46cb475
2021-08-27 15:03:34 +00:00
cutealien
54f5ac4982 Remove 'register' keyword in all c++ code.
It's never really done much in c++, was deprecated in c++11 and is reserved since c++17.
Thanks @Maksym Hamarnyk for remdinding me about this.
Note: there are few more register commands in third library .c code. It's still a valid keyword there.


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6130 dfc29bdd-3216-0410-991c-e03cc46cb475
2020-06-21 11:38:31 +00:00
cutealien
3acf725ae3 Work on IRRLICHT_FAST_MATH troubles. Document round_ and round32 troubles.
- Add warnings to round_, round32 about different (and sometimes worse) behavior than the standard library, especially at high numbers.
  For example with input 8388609 standard library corrrectly returns 8388609, but we get 8388610.
  But as we still don't use C99/c++11 in Irrlicht 1.9 I have no easy way to fix this.
- reciprocal_squareroot with IRRLICHT_FAST_MATH is less exact than it claims to be. Just commenting it.
- document slightly different behavior of reciprocal with IRRLICHT_FAST_MATH around 0.
- Kick out IRRLICHT_FAST_MATH for floor32, ceil32, round32. Their results are simply wrong, especially for uneven numbers.
  Like floor32(1) will be 0. or ceil32(-1) will also be 0. round32 wasn't as bad, but also down-rounding 0.5 and less exact.
  I know Burnings still wants those functions, so next commmit will add them again, but with new names and only an internal header.

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6011 dfc29bdd-3216-0410-991c-e03cc46cb475
2019-12-16 15:48:35 +00:00
cutealien
79800125ae No longer try to use __asm on _WIN64 in VisualStudio.
64-bit asm isn't supported on VS (and I suppose we used 32-bit asm anyway).


git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6010 dfc29bdd-3216-0410-991c-e03cc46cb475
2019-12-16 13:57:31 +00:00
cutealien
5c8f0484da Remove clearFPUException which did nothing.
That function just returned true for years not doing anything.
As far as I can see from the web it's about some rare cases in DOS compatibility mode with 32-bit apps. 
But not sure why it was called exactly in this place in the past.
So no comments, no idea what it's about and not actually doing anything and probably not needed on any platform anyone still uses ... lets just kick it out.
(it did break compiling IRRLICHT_FAST_MATH on x64 which is why I noticed it)

git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6009 dfc29bdd-3216-0410-991c-e03cc46cb475
2019-12-16 13:49:38 +00:00
cutealien
8310a3fbad Avoid warning and make local variable lower-case.
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6000 dfc29bdd-3216-0410-991c-e03cc46cb475
2019-12-12 16:32:41 +00:00