mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-27 13:23:35 +08:00
Construct Vector from Slice<1,M> alias row()
This commit is contained in:
@@ -56,6 +56,11 @@ public:
|
||||
{
|
||||
}
|
||||
|
||||
template<size_t P, size_t Q>
|
||||
Vector3(const Slice<Type, 1, 3, P, Q>& slice_in) : Vector<Type, 3>(slice_in)
|
||||
{
|
||||
}
|
||||
|
||||
Vector3 cross(const Matrix31 & b) const {
|
||||
const Vector3 &a(*this);
|
||||
return {a(1)*b(2,0) - a(2)*b(1,0), -a(0)*b(2,0) + a(2)*b(0,0), a(0)*b(1,0) - a(1)*b(0,0)};
|
||||
|
||||
Reference in New Issue
Block a user