feat(reflector_pair): make tape_core_intensity and tape_plateau_min_fraction optional
An unset core threshold defaults to tape_min_intensity and an unset plateau fraction to 1.0, resolved once in ReflectorPairMatcher::configure(). Every deployed profile already set the two thresholds equal (no bloom on the robot lidar), so operators now configure one threshold. Profiles that set both keys match exactly as before.
This commit is contained in:
@@ -27,6 +27,10 @@ bool ReflectorPairMatcher::configure(const ReflectorPairProfile& profile, std::s
|
||||
return false;
|
||||
}
|
||||
profile_ = profile;
|
||||
if (std::isnan(profile_.tape_core_intensity))
|
||||
profile_.tape_core_intensity = profile_.tape_min_intensity;
|
||||
if (std::isnan(profile_.tape_plateau_min_fraction))
|
||||
profile_.tape_plateau_min_fraction = 1.0;
|
||||
configured_ = true;
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user