Commit b4c5624d authored by wangdawei's avatar wangdawei

test

parent 5db99f39
......@@ -337,7 +337,7 @@ bool AdjustPPK::Undisort(
bool AdjustPPK::ConfigMap(double timestamp)
{
int ret;
bool newMatcher = false;
static size_t lastPeriodIndex = 9999;
while(true){
ret = ppkPeriodVec_.at(periodIndex_).InPeriod(timestamp);
if(-1 == ret){
......@@ -345,9 +345,8 @@ bool AdjustPPK::ConfigMap(double timestamp)
}
if(0 == ret){
periodIndex_++;
newMatcher = true;
LOG(INFO) << "next period " << periodIndex_;
}else{ //no need reset matcher
}else{
break;
}
if(periodIndex_ >= ppkPeriodVec_.size()){
......@@ -355,7 +354,7 @@ bool AdjustPPK::ConfigMap(double timestamp)
return false;
}
}
if(!newMatcher){
if(lastPeriodIndex == periodIndex_){
return true;
}
auto meshId = ppkPeriodVec_.at(periodIndex_).meshId;
......@@ -364,6 +363,7 @@ bool AdjustPPK::ConfigMap(double timestamp)
}
currMatcher_ = meshVec_.at(meshId).matcher;
LOG(INFO) << "set currMatcher_: " << meshId;
lastPeriodIndex = periodIndex_;
return true;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment