Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
OpenFlipper
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
OpenFlipper-Free
OpenFlipper
Merge requests
!162
Matrix3x3: support multiplication of vectors of different type.
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Matrix3x3: support multiplication of vectors of different type.
mat3x3-mixed-mult
into
master
Overview
2
Commits
1
Pipelines
0
Changes
1
Merged
Martin Heistermann
requested to merge
mat3x3-mixed-mult
into
master
5 years ago
Overview
2
Commits
1
Pipelines
0
Changes
1
Expand
[x] TODO: correct operator order in decltype(), include the addition too
Edited
5 years ago
by
Martin Heistermann
0
0
Merge request reports
Compare
master
version 1
9d3e9009
5 years ago
master (base)
and
latest version
latest version
90ce2cf6
1 commit,
5 years ago
version 1
9d3e9009
1 commit,
5 years ago
1 file
+
12
−
6
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
libs_required/ACG/Math/Matrix3x3T.hh
+
12
−
6
Options
@@ -128,20 +128,26 @@ class Matrix3x3T {
}};
}
constexpr
Vec3
operator
*
(
const
Vec3
&
rhs
)
const
{
return
Vec3
(
template
<
typename
OtherScalar
>
constexpr
auto
operator
*
(
const
VectorT
<
OtherScalar
,
3
>
&
rhs
)
const
->
OpenMesh
::
VectorT
<
decltype
((
*
this
)(
0
,
0
)
*
rhs
[
0
]),
3
>
{
return
{
(
*
this
)(
0
,
0
)
*
rhs
[
0
]
+
(
*
this
)(
0
,
1
)
*
rhs
[
1
]
+
(
*
this
)(
0
,
2
)
*
rhs
[
2
],
(
*
this
)(
1
,
0
)
*
rhs
[
0
]
+
(
*
this
)(
1
,
1
)
*
rhs
[
1
]
+
(
*
this
)(
1
,
2
)
*
rhs
[
2
],
(
*
this
)(
2
,
0
)
*
rhs
[
0
]
+
(
*
this
)(
2
,
1
)
*
rhs
[
1
]
+
(
*
this
)(
2
,
2
)
*
rhs
[
2
]
)
;
}
;
}
constexpr
friend
Vec3
operator
*
(
Vec3
v
,
const
Matrix3x3T
&
rhs
)
{
return
Vec3
(
template
<
typename
OtherScalar
>
constexpr
friend
auto
operator
*
(
VectorT
<
OtherScalar
,
3
>
v
,
const
Matrix3x3T
&
rhs
)
->
OpenMesh
::
VectorT
<
decltype
(
rhs
(
0
,
0
)
*
v
[
0
]),
3
>
{
return
{
rhs
(
0
,
0
)
*
v
[
0
]
+
rhs
(
0
,
1
)
*
v
[
1
]
+
rhs
(
0
,
2
)
*
v
[
2
],
rhs
(
1
,
0
)
*
v
[
0
]
+
rhs
(
1
,
1
)
*
v
[
1
]
+
rhs
(
1
,
2
)
*
v
[
2
],
rhs
(
2
,
0
)
*
v
[
0
]
+
rhs
(
2
,
1
)
*
v
[
1
]
+
rhs
(
2
,
2
)
*
v
[
2
]
)
;
}
;
}
constexpr
Matrix3x3T
operator
*
(
Scalar
c
)
const
{
Loading