Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Institute of Technical Acoustics (ITA)
toolbox
Commits
922758a3
Commit
922758a3
authored
Apr 05, 2018
by
fpa
Browse files
changed treatment of NaN entries, are now preserved
parent
5cc1c170
Changes
2
Hide whitespace changes
Inline
Side-by-side
applications/Hardware/Tracking/Optitrack/@itaOrientation/itaOrientation.m
View file @
922758a3
...
...
@@ -40,7 +40,7 @@ classdef itaOrientation
% ita_vu2quat, ita_vu2rpy, itaOptitrack
%
% Author: Florian Pausch, fpa@akustik.rwth-aachen.de
% Version: 201
6
-05-0
9
% Version: 201
8
-05-0
4
%
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
...
...
@@ -205,7 +205,7 @@ classdef itaOrientation
% set quat, nPoints x 4 [double]
if
~
isa
(
value
,
'quaternion'
)
assert
(
isequal
(
size
(
value
,
2
),
4
),[
'Size of input must be '
,
num2str
(
this
.
nPoints
),
' x 4 [double].'
])
if
size
(
value
,
1
)
~=
this
.
nPoints
;
if
size
(
value
,
1
)
~=
this
.
nPoints
fprintf
(
'[\b[itaOrientation]\tSize of input does not match %d x 4.]\b\n'
,
this
.
nPoints
)
fprintf
(
'[\b\t\t\t\t\tSize of class object is changed.]\b\n'
)
end
...
...
applications/Hardware/Tracking/Optitrack/ita_vu2rpy.m
View file @
922758a3
...
...
@@ -28,7 +28,7 @@ function [r, p, y] = ita_vu2rpy(v, u)
%
% Authors: Florian Pausch, Jonas Stienen
% e-Mail: {fpa, jst}@akustik.rwth-aachen.de
% Version: 201
6
-04-0
7
% Version: 201
8
-04-0
5
%
% <ITA-Toolbox>
% This file is part of the ITA-Toolbox. Some rights reserved.
...
...
@@ -69,8 +69,8 @@ if (colv == 1)
v
(
~
isnan
(
v
(:,
1
)),:)
=
v
(
~
isnan
(
v
(:,
1
)),:)
.
/
abs
(
v
(
~
isnan
(
v
(:,
1
)),:));
u
(
~
isnan
(
u
(:,
1
)),:)
=
u
(
~
isnan
(
u
(:,
1
)),:)
.
/
abs
(
u
(
~
isnan
(
u
(:,
1
)),:));
else
v
=
sqrt
(
ones
.
/
(
sum
((
v
(
~
isnan
(
v
(:,
1
)),:)
.*
v
(
~
isnan
(
v
(:,
1
)),:)
)
')) )'
*
ones
(
1
,
colv
)
.*
v
(
~
isnan
(
v
(:,
1
)),:)
;
u
=
sqrt
(
ones
.
/
(
sum
((
u
(
~
isnan
(
u
(:,
1
)),:)
.*
u
(
~
isnan
(
u
(:,
1
)),:)
)
')) )'
*
ones
(
1
,
colu
)
.*
u
(
~
isnan
(
u
(:,
1
)),:)
;
v
=
sqrt
(
ones
.
/
(
nan
sum
((
v
.*
v
)
')) )'
*
ones
(
1
,
colv
)
.*
v
;
u
=
sqrt
(
ones
.
/
(
nan
sum
((
u
.*
u
)
')) )'
*
ones
(
1
,
colu
)
.*
u
;
end
% init.
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment