pub fn rescale_descriptors_to_input(
descriptors: &mut [CornerDescriptor],
factor: u32,
)Expand description
Optional pre-pipeline integer bilinear upscaling stage. These are the
raw stage primitives behind UpscaleConfig; Detector applies
the stage automatically, so they are only needed when composing the
pipeline by hand.
Rescale corner positions from an upscaled image back to the
original input-image pixel frame.
Uses the inverse of the forward half-pixel-center mapping from
upscale_bilinear_u8:
forward : x_out = (x_src + 0.5) * k - 0.5
inverse : x_src = (x_out + 0.5) / k - 0.5
= x_out / k - (k - 1) / (2k)A naive x /= k biases returned coordinates by (k − 1) / (2k)
pixels (+0.25 px at k = 2). Axis angles and sigmas are
scale-invariant and are left untouched.