diff options
author | mwturvey <michael.w.turvey@intel.com> | 2017-03-08 10:47:27 -0700 |
---|---|---|
committer | mwturvey <michael.w.turvey@intel.com> | 2017-03-08 10:47:27 -0700 |
commit | a5430b24d41d1bb795db14036b35c39c7a9accd4 (patch) | |
tree | 90120d0a3d529aca81d77fe825229f8a6d641bc6 /src/survive_cal_lhfind.c | |
parent | 321749a4b8e3e8b3f4b03863200fbf86e36a0bbe (diff) | |
parent | c65498054c77192b2a12fdb5ef44439a14110292 (diff) | |
download | libsurvive-a5430b24d41d1bb795db14036b35c39c7a9accd4.tar.gz libsurvive-a5430b24d41d1bb795db14036b35c39c7a9accd4.tar.bz2 |
Merge branch 'master' of https://github.com/cnlohr/libsurvive
Diffstat (limited to 'src/survive_cal_lhfind.c')
-rw-r--r-- | src/survive_cal_lhfind.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/survive_cal_lhfind.c b/src/survive_cal_lhfind.c index e1e5fc9..a1bb2cc 100644 --- a/src/survive_cal_lhfind.c +++ b/src/survive_cal_lhfind.c @@ -7,13 +7,13 @@ #define MIN_HITS_FOR_VALID 10 -FLT static RunOpti( struct SurviveCalData * cd, int lh, int print, FLT * LighthousePos, FLT * LighthouseQuat ); +FLT static RunOpti( SurviveCalData * cd, int lh, int print, FLT * LighthousePos, FLT * LighthouseQuat ); //Values used for RunTest() -int survive_cal_lhfind( struct SurviveCalData * cd ) +int survive_cal_lhfind( SurviveCalData * cd ) { - struct SurviveContext * ctx = cd->ctx; + SurviveContext * ctx = cd->ctx; int cycle, i; int lh = 0; FLT dx, dy, dz; @@ -129,7 +129,7 @@ int survive_cal_lhfind( struct SurviveCalData * cd ) fullrange *= 0.25; } - if( beste > 0.005 ) + if( beste > 0.01 ) { //Error too high SV_ERROR( "LH: %d / Best E %f Error too high\n", lh, beste ); @@ -137,8 +137,8 @@ int survive_cal_lhfind( struct SurviveCalData * cd ) } cd->ctx->bsd[lh].PositionSet = 1; - copy3d( cd->ctx->bsd[lh].Position, LighthousePos ); - quatcopy( cd->ctx->bsd[lh].Quaternion, LighthouseQuat ); + copy3d( cd->ctx->bsd[lh].Pose.Pos, LighthousePos ); + quatcopy( cd->ctx->bsd[lh].Pose.Rot, LighthouseQuat ); } return 0; //Return 0 if success. @@ -149,14 +149,14 @@ int survive_cal_lhfind( struct SurviveCalData * cd ) -static FLT RunOpti( struct SurviveCalData * cd, int lh, int print, FLT * LighthousePos, FLT * LighthouseQuat ) +static FLT RunOpti( SurviveCalData * cd, int lh, int print, FLT * LighthousePos, FLT * LighthouseQuat ) { int i, p; FLT UsToTarget[3]; FLT LastUsToTarget[3]; FLT mux = .9; quatsetnone( LighthouseQuat ); - struct SurviveObject * hmd = cd->hmd; + SurviveObject * hmd = cd->hmd; FLT * hmd_points = hmd->sensor_locations; FLT * hmd_normals = hmd->sensor_normals; |