projective_grid/shared/mod.rs
1//! Shared detection back-half plus the geometry-only grid-growth engine.
2//!
3//! The topological strategy's only job is to build connected components;
4//! everything after — local component merge ([`merge`]), geometric validation
5//! ([`validate`]), and the per-component lattice fit (`fit`) — is shared here.
6//!
7//! This module also hosts the pattern-agnostic grid-growth primitives and the
8//! geometry-only recovery schedule that powers the topological synthesized-axis
9//! (`Evidence::Positions` / `Evidence::Oriented1`) path:
10//!
11//! - [`grow`] — the [`SquareAttachPolicy`](grow::SquareAttachPolicy) contract,
12//! candidate search, ambiguity resolution, and the per-edge cardinal gate.
13//! - [`grow_extend`] / [`extension`] / [`fill`] — boundary-extension and
14//! interior-fill engines built on those primitives.
15//! - [`recovery_schedule`] — the
16//! [`RecoverySchedule`](recovery_schedule::RecoverySchedule) fixed-point that
17//! composes extension + fill + revalidation + drop filters.
18//!
19//! A crate-private geometry-first attach policy for synthesized-axis evidence
20//! backs the recovery schedule. The undirected-angle helpers it needs live in
21//! [`crate::cluster`] (the single source of truth for `wrap_pi` /
22//! `angular_dist_pi`).
23//!
24//! The chessboard crate composes [`grow`] / [`fill`] / [`extension`] /
25//! [`grow_extend`] directly for its own topological recovery path.
26
27// `fit` is engine-internal: only the in-crate strategy facades consume
28// `fit_component` / `FitComponentResult` (re-exported `pub(crate)` below). No
29// external consumer reaches it, so the module is crate-private — keeping the
30// advanced tier no wider than what callers actually use.
31pub(crate) mod fit;
32pub mod merge;
33pub mod validate;
34
35// Geometry-only grid-growth engine + recovery schedule (relocated from the
36// retired `seed_and_grow` module; consumed by the topological recovery path
37// and, externally, by the chessboard crate).
38pub mod extension;
39pub mod fill;
40pub mod grow;
41pub mod grow_extend;
42mod positions_policy;
43pub mod recovery_schedule;
44
45/// Deprecated path alias for [`recovery_schedule`]. The module was renamed
46/// `recovery` → `recovery_schedule` in 0.10.0; this alias keeps external
47/// advanced-engine consumers that import
48/// `projective_grid::shared::recovery::{recover_components, local_pitch_of, …}`
49/// compiling. Remove after the 0.10.0 migration window.
50#[deprecated(since = "0.10.0", note = "renamed to `recovery_schedule`")]
51pub use recovery_schedule as recovery;
52
53pub(crate) use fit::{fit_component, FitComponentResult};