Illustrated C/C++ source sheets, symbol index, API relationship graph, compiler console and debug trace

LIVE AI / FLEXIBLE SENSING / FLIGHT CONTEXT

Sensoraia API

Live AI and sensing, connected to the flight.
See, listen, inspect and return supported results while airborne.

Loading...
Searching...
No Matches
spotter_targets.h File Reference

Five ranked geographic targets, independent of navigation and camera transport. More...

#include <stdbool.h>
#include <stdint.h>
Include dependency graph for spotter_targets.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  spotter_target
 Geographic observation in the shared USHER point units. More...
struct  spotter_targets
 Caller-owned fixed storage; slot indices stay stable while scores improve. More...

Macros

#define SPOTTER_TARGET_COUNT   5U

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

Five ranked geographic targets, independent of navigation and camera transport.

Definition in file spotter_targets.h.

Macro Definition Documentation

◆ SPOTTER_TARGET_COUNT

#define SPOTTER_TARGET_COUNT   5U

Definition at line 30 of file spotter_targets.h.

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
targetsExclusive target store.
observationImmutable valid geographic observation.
applyOptional coordinate transaction; false leaves the selected slot unchanged.
contextBorrowed 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
targetsWritable store, or NULL to do nothing.

Definition at line 24 of file spotter_targets.c.