import type { Wafer } from './wafer.js';
export interface ReticleSpec {
    width: number;
    height: number;
    diePitchX: number;
    diePitchY: number;
    anchorDie?: {
        x: number;
        y: number;
    };
    /**
     * Physical position of die index (0,0) — i.e. where `anchorDie` is measured
     * from. Defaults to the wafer centre `{0,0}`, correct only when the die grid
     * is itself centred on the wafer. When the die grid's physical placement is
     * offset from wafer centre by a non-whole-die-pitch amount (e.g. partial/
     * off-centre wafer data, where `buildWaferMap` centres the *data extent*
     * rather than the wafer), that fractional remainder must be passed here or
     * field boundaries silently drift out of alignment with die edges.
     */
    gridOrigin?: {
        x: number;
        y: number;
    };
}
/** A reticle rectangle in wafer-local (pre-rotation) coordinates. */
export interface Reticle {
    x: number;
    y: number;
    width: number;
    height: number;
}
/**
 * The field-local (column, row) that a die occupies within its reticle field,
 * per the `anchorDie` convention documented on `generateReticleGrid`:
 * `anchorDie` is the field's min-x/min-y (bottom-left) corner, so a die's
 * local position is `die - anchorDie`, wrapped to the field dimensions.
 *
 * This is the single source of truth for "which reticle cell is this die
 * in" — every consumer that needs the answer (e.g. stats findings, region
 * labeling) must call this rather than re-deriving the phase math, so field
 * geometry and cell labeling can never drift apart again.
 */
export declare function getReticleCell(die: {
    x: number;
    y: number;
}, config: {
    width: number;
    height: number;
    anchorDie?: {
        x: number;
        y: number;
    };
}): {
    column: number;
    row: number;
};
/**
 * Generate the grid of reticle rectangles that cover the wafer area.
 * Returns positions in wafer-local coordinates (before orientation rotation).
 * Reticles that don't overlap the wafer circle are excluded.
 *
 * Width and height are in die counts; diePitchX/diePitchY convert to display units.
 * The anchorDie index lands at the reticle's min-x/min-y corner (bottom-left,
 * since +Y is up) — i.e. anchorDie is the first (leftmost, bottom-most) die
 * of the field it belongs to.
 */
export declare function generateReticleGrid(wafer: Wafer, config: ReticleSpec): Reticle[];
//# sourceMappingURL=reticle.d.ts.map