matlab plotPose3: don't draw covariance if it's empty
parent
2dbbd9f989
commit
3bad1346d6
|
@ -20,7 +20,7 @@ L = [C zAxis]';
|
||||||
line(L(:,1),L(:,2),L(:,3),'Color','b');
|
line(L(:,1),L(:,2),L(:,3),'Color','b');
|
||||||
|
|
||||||
% plot the covariance
|
% plot the covariance
|
||||||
if nargin>2
|
if (nargin>2) && (~isempty(P))
|
||||||
pPp = P(4:6,4:6); % covariance matrix in pose coordinate frame
|
pPp = P(4:6,4:6); % covariance matrix in pose coordinate frame
|
||||||
gPp = gRp*pPp*gRp'; % convert the covariance matrix to global coordinate frame
|
gPp = gRp*pPp*gRp'; % convert the covariance matrix to global coordinate frame
|
||||||
covarianceEllipse3D(C,gPp);
|
covarianceEllipse3D(C,gPp);
|
||||||
|
|
Loading…
Reference in New Issue