Stable five-slot confidence ranking without heap, threads or flight-plan decisions. More...

Go to the source code of this file.
Functions | |
| void | spotter_targets_reset (struct spotter_targets *targets) |
| Forget all prior assignments without manufacturing target coordinates. | |
| int | spotter_targets_offer (struct spotter_targets *targets, const struct spotter_target *observation, bool(*apply)(void *, unsigned, const struct spotter_target *), void *context) |
| Admit a target only after its owner's coordinate application succeeds. | |
Detailed Description
Stable five-slot confidence ranking without heap, threads or flight-plan decisions.
Definition in file spotter_targets.c.
Function Documentation
◆ spotter_targets_offer()
| int spotter_targets_offer | ( | struct spotter_targets * | targets, |
| const struct spotter_target * | observation, | ||
| bool(* | apply )(void *, unsigned, const struct spotter_target *), | ||
| void * | context ) |
Admit a target only after its owner's coordinate application succeeds.
- Parameters
-
targets Exclusive target store. observation Immutable valid geographic observation. apply Optional coordinate transaction; false leaves the selected slot unchanged. context Borrowed callback state.
- Returns
- Assigned zero-based slot, or minus one for invalid/nonimproving/rejected observations.
Empty slots fill first; once full, only a strictly better score replaces the lowest. Reobserving exactly the same position improves its existing slot instead of consuming another.
Definition at line 31 of file spotter_targets.c.
◆ spotter_targets_reset()
| void spotter_targets_reset | ( | struct spotter_targets * | targets | ) |
Forget all prior assignments without manufacturing target coordinates.
- Parameters
-
targets Writable store, or NULL to do nothing.
Definition at line 24 of file spotter_targets.c.