Commit Graph

68 Commits

Author SHA1 Message Date
b61d55ee3c build: satiate clang-tidy somewhat 2019-01-03 15:48:34 +11:00
f6056153e3 rename root namespace from util to cruft
This places, at long last, the core library code into the same namespace
as the extended library code.
2018-08-05 14:42:02 +10:00
803acc9a87 relicense under MPL-2.0 2018-08-04 15:14:06 +10:00
3aaddd1d2b json: move json code to external module
This module can now be found at git://git.nerdcruft.net/libcruft-json.git
2018-08-04 15:02:06 +10:00
52fcb847c9 vector: add validator specialisation 2018-04-16 16:00:32 +10:00
3ad0339474 WIP vector: spherical/cartesian conversion 2017-11-02 18:11:16 +11:00
4bf160934c vector: prefer constexpr functions over static variables 2016-12-12 17:04:39 +11:00
246357e279 random: remove typed randomisers without generators 2016-11-17 18:38:08 +11:00
b927c8b8e7 vector: make cross function constexpr 2016-10-17 16:49:26 +11:00
9a798446b5 build: remove unnecessary includes
discovered with include-what-you-use
2016-10-12 15:08:22 +11:00
cf7fda382a vector: normalise result of from_euler 2016-10-11 20:57:17 +11:00
b809925396 vector: rename UNIT to ONES
unit isn't a normalised vector, so it's misleading to call it a 'unit'
vector
2016-08-15 20:56:10 +10:00
ead926bed2 vector: remove difference methods 2016-08-11 16:33:42 +10:00
1f3b44a20e vector: move vector::is_zero to coord::almost_zero 2016-08-11 16:33:32 +10:00
606a9c4eb8 coord/ops: use free functions for normalisations 2016-08-11 14:58:46 +10:00
1f432c13b7 build: avoid type truncation warnings
discovered with clang's -Wshorten-64-to-32
2016-05-12 17:39:33 +10:00
0ec92951fc vector: remove redundant almost_equal definition 2016-04-22 16:16:26 +10:00
809e7b0421 iostream: use consistent ostream format 2016-03-11 13:01:57 +11:00
b1bc54ac8c maths: move remaining operations into util namespace 2015-11-16 11:44:07 +11:00
7b083df977 maths: tighten up type requirements for almost_equal
almost_equal only operates on two reals, or two integers (and even then
only on the same signedness).
2015-11-13 17:18:10 +11:00
74d7f9c717 vector: add {to,from}_euler 2015-07-21 02:56:37 +10:00
13abad0d43 vector: use mag2 for normalised check 2015-04-15 14:25:16 +10:00
71d8a30769 vector: operate on value types, not references 2015-04-15 14:06:49 +10:00
6f1278767f vector: add is_normalised 2015-04-15 13:52:37 +10:00
f87481c5e0 vector: add constant unit vector 2015-04-15 13:52:22 +10:00
13ea2bbdf5 vector: style 2015-04-15 13:48:07 +10:00
2658b41ea1 relicence under Apache-2.0 2015-04-13 18:05:28 +10:00
a300f99b87 vector: add polar_to_cartesian 2015-04-02 15:01:17 +11:00
4aa35f4c70 vector: add almost_equal specialisation 2015-04-02 15:01:17 +11:00
3da59aea2f vector: instantiate polar_to_cartesian 2015-04-01 17:05:24 +11:00
439bb19679 coord: move operators out of subclasses 2015-03-06 01:09:58 +11:00
0ed770eb09 vector: style 2015-02-19 14:20:01 +11:00
d342ef72f5 vector: add free dot function 2015-02-19 13:29:16 +11:00
b0d3211f02 vector: fully qualify std::begin/end 2015-02-19 13:29:16 +11:00
cfc0f8ecd0 json: move tree parsing code to json::tree 2015-02-02 21:26:56 +11:00
cee9951f82 vector: add difference(2) methods 2015-01-28 15:00:20 +11:00
6abfd252d9 coord: move free maths func from point to vector 2015-01-28 14:59:33 +11:00
52f53caee5 debug: drop support for CHECK_HARD
HARD vs SOFT assertions were never very well defined or supported.
Currently they just imply a level of functionality that isn't present;
it's better to remove them instead of expending the effort at this
point.
2015-01-28 14:49:34 +11:00
6da2e2226c vector: collapse template instantiation behind def 2015-01-21 23:40:13 +11:00
fa52752629 vector: add vector2i and vector2u typedefs 2015-01-16 14:44:26 +11:00
7ef4cbcc1a vector: add redim operation 2015-01-15 14:01:51 +11:00
64c11bdcb0 point/vector: use coord constructors 2015-01-13 18:41:51 +11:00
5956d0421e parameterise point, vector, region, matrix on type 2014-12-15 20:10:56 +11:00
a6cc1e1e9d vector: add instantiations for 4 element vectors 2014-08-19 20:46:37 +10:00
f6894fabc8 whitespace 2014-08-18 22:16:50 +10:00
233251b2c8 vector: workaround internal compiler error for gcc 2014-08-01 21:39:13 +10:00
bd5b9722ea Make vector constructor explicit
It had been seen to construct out of single doubles, which is
problematic...
2013-08-06 21:23:56 +10:00
de0d05df97 Add decleration for vector::redim as a reminder 2013-08-06 14:32:08 +10:00
b4228aca1e Add polar to cartesian operation for vectors 2013-07-30 23:52:31 +10:00
7d61acc8c1 Remove double printing of vector[0] 2012-06-14 18:32:17 +10:00