Luxar Viewer API Documentation - v2026.9.22
    Preparing search index...

    Tuning knobs for measureLocalMedianOutliers.

    interface LocalMedianOptions {
        window?: number;
        threshold?: number;
        backgroundCutoff?: number;
    }
    Index
    window?: number

    Side length of the square neighbourhood the median is taken over. Must be an odd integer >= 3 — at 1 the "median" is the pixel itself and the metric can never report an outlier. Default 5 — wide enough to step over a one-to-two-pixel wedge tick, narrow enough to track a smooth ramp. Changing it moves the sensitivity envelope documented in the module header; the unit tests pin that envelope deliberately.

    threshold?: number

    Absolute luminance deviation (0-255 scale) beyond which a pixel counts as an outlier. Default 25.

    backgroundCutoff?: number

    Luminance below which a pixel counts as background and is excluded from "inside". The test is applied to the pixel's LOCAL MEDIAN, not to the pixel itself: a #790 wedge tick is background-dark on its own yet sits in a bright neighbourhood, and it is precisely the pixel that must be counted. Must be >= 0. Default 12.