aboutsummaryrefslogtreecommitdiff
path: root/src/lib/conversion/rotation.h
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2014-07-03 14:02:05 +1000
committerLorenz Meier <lm@inf.ethz.ch>2014-07-08 11:46:40 +0200
commitf56724f7dff1f6d1167f4fd61015ffe24a64c8c9 (patch)
tree7fb95fa63f117cd14e130c988ec1d35e0f8a0e71 /src/lib/conversion/rotation.h
parente4e152a85b5a29cada6559197580a9dce93e45e3 (diff)
downloadpx4-firmware-f56724f7dff1f6d1167f4fd61015ffe24a64c8c9.tar.gz
px4-firmware-f56724f7dff1f6d1167f4fd61015ffe24a64c8c9.tar.bz2
px4-firmware-f56724f7dff1f6d1167f4fd61015ffe24a64c8c9.zip
lib/conversion: added rotate_3f()
will be used for user specified rotations in sensor drivers
Diffstat (limited to 'src/lib/conversion/rotation.h')
-rw-r--r--src/lib/conversion/rotation.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lib/conversion/rotation.h b/src/lib/conversion/rotation.h
index 0c56494c5..5187b448f 100644
--- a/src/lib/conversion/rotation.h
+++ b/src/lib/conversion/rotation.h
@@ -118,4 +118,12 @@ const rot_lookup_t rot_lookup[] = {
__EXPORT void
get_rot_matrix(enum Rotation rot, math::Matrix<3,3> *rot_matrix);
+
+/**
+ * rotate a 3 element float vector in-place
+ */
+__EXPORT void
+rotate_3f(enum Rotation rot, float &x, float &y, float &z);
+
+
#endif /* ROTATION_H_ */