Commit Graph

92 Commits

Author SHA1 Message Date
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
b8253536ea vector: add hughes-moeller make_basis 2018-04-18 21:48:55 +10:00
76c809f031 point/vector: homog no longer takes a size parameter 2018-04-17 14:26:23 +10:00
52fcb847c9 vector: add validator specialisation 2018-04-16 16:00:32 +10:00
28148dd890 vector: add make_basis function 2018-04-12 12:59:45 +10:00
1cc4f90b52 vector: add forwarding assignment operator 2018-04-11 19:28:03 +10:00
561925b201 vector: expose base assignment operator 2018-04-11 18:25:51 +10:00
d1da97f213 vector: clarify spherical components 2018-04-05 19:22:38 +10:00
5532f90de7 vector: note what each component in spherical corresponds to 2018-03-27 16:11:49 +11:00
5bc2cf12d4 maths: use true constexpr values for pi 2018-03-12 23:06:15 +11:00
ba19aebe88 point/vector: give homog a default dimensionality 2018-03-06 18:13:46 +11:00
0e3fa05f05 build: migrate from ipp files to pure hpp files
ipp files weren't a great way of keeping things clean, and IDEs have a
little trouble dealing with the split configuration. this simplifies
debugging a great deal.
2018-02-28 11:49:13 +11:00
51ffcbb07e vector: add spherical canonicalisation function 2018-01-17 17:44:59 +11:00
a8b6184e65 vector: use atan2 for spherical conversions 2018-01-17 17:44:45 +11:00
9bb2bdbaba Merge remote-tracking branch 'origin/master' 2018-01-10 17:19:39 +11:00
0351313c36 Merge branch 'master' into coord 2017-11-23 17:24:11 +11:00
d3f434b523 coord: make template parameters more flexible
The coordinate system was unable to support types that prohibited
redim or retype operations. Additionally, the `tags' type used for
providing named data parameters was unwiedly.

We remove much of the dependance on template template parameters in the
defined operations and instead define these in terms of a template
specialisation of is_coord.

The tag types were replaced with direct specialisation of the `store'
struct by the primary type, and passing this type through use of the
CRTP.
2017-11-22 17:03:00 +11:00
3ad0339474 WIP vector: spherical/cartesian conversion 2017-11-02 18:11:16 +11:00
3799135236 coord: add general vector comparison function 2017-08-27 12:32:00 +10:00
cde0fe882e vector: add more convenience typedefs for bools 2017-08-27 12:28:00 +10:00
a14847bb59 vector: add and correct 4-dimension types 2017-08-24 14:39:54 +10:00
a7caea16e1 vector: add 2d cross product 2016-12-21 20:23:43 +11:00
4bf160934c vector: prefer constexpr functions over static variables 2016-12-12 17:04:39 +11:00
ec78216813 coord: prefer int/unsigned to intmax/size_t 2016-10-25 17:46:36 +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
109d47e971 coord/ops: generalise vectors hypot function 2016-09-23 13:27:44 +10:00
ede9b75bad vector: fix hypot implementation 2016-09-21 22:24:02 +10:00
4544a594c3 vector: add hypot function
calculates the root of the sum of the squares. much like std::hypot, but
of arbitrary dimension.
2016-09-21 17:13:25 +10: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
cf3d58074f vector: add convenience typedef vectoru 2016-08-10 18:26:13 +10:00
809e7b0421 iostream: use consistent ostream format 2016-03-11 13:01:57 +11:00
7753e37dc3 vector: add constant sized convenience typedefs 2015-10-06 15:19:29 +11:00
4ea5896d21 coord: use template typedefs 2015-07-24 01:34:44 +10:00
f4738fc010 vector: add vector3{u,i} typedefs 2015-07-22 02:54:52 +10:00
74d7f9c717 vector: add {to,from}_euler 2015-07-21 02:56:37 +10:00
5b8df525a2 vector: add homogenous converter
added for symmetry with point classes
2015-07-21 01:41:48 +10:00
19544076dd vector: add vector{2,3,4} convenience typedefs 2015-07-13 16:30:54 +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
2658b41ea1 relicence under Apache-2.0 2015-04-13 18:05:28 +10:00
bd88832df3 coord: move cast/redim operations to coord 2015-04-09 17:58:47 +10:00
5428c93b9a coord: pass client class to coord base
allows common typesafe implementation of cast and redim
2015-04-09 17:47:35 +10:00
c94535dfae vector: note the order of components for polar 2015-04-08 19:00:46 +10:00