Vladimír Vondruš
3952a20099
Math: verify that the Frustum constructor is implicit.
10 years ago
Vladimír Vondruš
8d1d786698
Math: more Frustum data access functions, test for constexprness.
10 years ago
Vladimír Vondruš
3e2464cded
Math: default/identity and NoInit constructors for Frustum, tests.
10 years ago
Vladimír Vondruš
70ef473710
Math: verify that the NoInit constructors are explicit.
10 years ago
Vladimír Vondruš
310e1c1c25
Math: noexcept constructor for Frustum.
10 years ago
Vladimír Vondruš
54d1aefcba
Math: equality comparison for Frustum.
...
Together with the debug operator it allows for much simpler testing.
10 years ago
Vladimír Vondruš
376ea1e0b2
Math: debug operator for Frustum.
10 years ago
Vladimír Vondruš
b7eb367dde
Math: cleanup, code compression.
10 years ago
Squareys
0062fbf78e
Math: Add rudimentary Frustum class
...
Signed-off-by: Squareys <Squareys@googlemail.com>
10 years ago
Vladimír Vondruš
37565d5414
Math: print 8-bit colors as hex in Debug.
...
So #ffffff00 instead of Vector(255, 255, 255, 0). Much shorter with the
same information value.
10 years ago
Vladimír Vondruš
69dfc39f30
Math: don't compare const char* as pointers in test by accident.
10 years ago
Vladimír Vondruš
210949f2dd
Math: long double is the same as double also on Android.
10 years ago
Vladimír Vondruš
c47f8e04e3
Math: test for size of long double.
...
In order to have predictable results in the tests.
10 years ago
Vladimír Vondruš
60b56b0999
Math: no need for that GCC type deduction workaround anymore.
10 years ago
Vladimír Vondruš
a2c8435ede
Use new TestSuite numeric comparators where appropriate.
10 years ago
Vladimír Vondruš
cf185b00fa
Math: add explicit boolean conversion to BoolVector.
10 years ago
Vladimír Vondruš
6422a27b46
Math: improve Matrix4::lookAt() test.
...
It now verifies all assumptions about how the resulting matrix should
look like.
10 years ago
Vladimír Vondruš
e9a2623e02
Math: expect NoInit test failures on GCC 6.1+ with optimizations enabled.
...
It's nothing harmful, just inefficient.
10 years ago
Vladimír Vondruš
87074202c8
Math: support infinite far plane in Matrix::perspectiveProjection().
10 years ago
Vladimír Vondruš
9fdf467c59
Math: added *Matrix::setRow().
...
Row equivalent for the mutable operator[]().
10 years ago
Vladimír Vondruš
2e91bb4372
Math: work around MSVC constexpr issues yet again.
10 years ago
Vladimír Vondruš
b033af3b59
Math: ability to convert Color from/to external representation.
10 years ago
Vladimír Vondruš
4a395ac490
Math: enlarge epsilon value for long doubles on MSVC.
...
They are internally treated as 64-bit doubles, so there's no difference.
10 years ago
Vladimír Vondruš
cadd28276a
Math: conditionally include <algorithm> for std::max() in MSVC.
...
Don't want to include it for every platform, as it is pretty huge...
10 years ago
Vladimír Vondruš
aef580ec62
Math: test iterative normalization of Complex/Quaternion transformations.
...
If the values are renormalized after every step, it shouldn't happen
that the value is denormalized even after calling `normalized()`.
The test fails for DualQuaternion with large values, as expected. Will
be fixed in the next commit.
10 years ago
Vladimír Vondruš
1dc1fc79b0
Math: better test cases for {*Complex,Quaternion}::isNormalized().
...
The expectation is that the values are considered normalized only if the
difference is small enough. This should have been tested since the
beginning, but instead this was waved away with a dumb test case testing
obviously denormalized value and obviously normalized value.
The test fails for DualQuaternion with large translation values (as
expected). Will be fixed in following commits.
10 years ago
Vladimír Vondruš
74c75998b0
Math: added TypeTraits::equalsZero().
10 years ago
Vladimír Vondruš
3c17a53fb3
Math: test also long double versions of TypeTraits.
10 years ago
Vladimír Vondruš
9ade2cae47
Math: added TypeTraits::name(), using that in the test.
10 years ago
Vladimír Vondruš
48dfdc1da5
Math: properly test constructing Unit with ZeroInit tag.
10 years ago
Vladimír Vondruš
844bfcce5a
Math: ability to create Dual with ZeroInit tag.
...
It does slightly different things than the implicit constructor for some
types.
10 years ago
Vladimír Vondruš
40d60f6a3f
Math: make all constructor noexcept and test their behavior.
10 years ago
Vladimír Vondruš
60524e0367
Math: remove now redundant Color test case.
...
At some point before the default Color constructor was different from
the ZeroInit one. Not anymore.
10 years ago
Vladimír Vondruš
bac5ccd8e6
Math: improve Angle test to be consistent with the rest.
10 years ago
Vladimír Vondruš
1357186fe1
Math: MSVC 2015 is picky about constexpr again.
...
No clue.
10 years ago
Vladimír Vondruš
b59b8d431e
Math: make Bezier::subdivide() return a pair and test it.
10 years ago
Vladimír Vondruš
8f7fa196a8
Math: renamed Bezier::lerp() to Bezier::value(), simplified test cases.
...
It's interpolation, but *not* linear interpolation, so don't confuse
with the naming. The test cases now compare to ground truth instead of
replicating the calculation.
10 years ago
Vladimír Vondruš
aaa0b0945a
Math: ability to convert Bezier underlying type.
10 years ago
Vladimír Vondruš
6f6d69012f
Math: added comparison operators to Bezier, expanded the test.
10 years ago
Vladimír Vondruš
12e19eff37
Math: ability to save/restore Bezier to/from Configuration.
10 years ago
Vladimír Vondruš
719aff99b2
Math: debug operator for Bezier.
10 years ago
Vladimír Vondruš
8bf1f5e5d8
Math: Minor Bézier cleanup and documentation improvements.
...
Removed the points() access function, as it has no real value.
10 years ago
Ashwin Ravichandran
6b7097497f
Math: added Bezier curve
10 years ago
Vladimír Vondruš
ac1cda6334
Math: simplify Constants test by making it templated.
10 years ago
Vladimír Vondruš
bf393fad59
Math: fix/workaround constexpr test compilation on MSVC 2015.
10 years ago
Vladimír Vondruš
951f116f5b
Math: added RectangularMatrix::flipped{Cols,Rows}().
10 years ago
Vladimír Vondruš
633d792e3d
Math: added Vector::flipped().
10 years ago
Vladimír Vondruš
eaeda24399
Don't restrict Double usage on OpenGL ES.
...
Restrict only what's not defined by GL on the ES flavor (double
attributes and uniforms). I love the smell of burning code.
10 years ago
Vladimír Vondruš
288a1f265c
Math: this shouldn't have been here.
...
Fixes test failures on *all* platforms. Ha!
10 years ago
Vladimír Vondruš
c2d2737ca6
Math: test and document Matrix4::*projection() harder.
10 years ago