Realm

oa::image::warp_polar

Warp each image plane to polar coordinates about a center, following warpPolar: output row y is the angular axis [0, 2pi) and column x is the radial axis — x / width * max_radius under Linear or max_radius^(x / width) under SemiLog. Source samples gather with the admitted interpolation and border policy. Errors Returns an error unless the image is a nonempty FP32 NCHW/CHW image, the center and radius are finite with max_radius > 0, the output extent is nonzero, border_value is finite, and all sizes fit the shader ABI.

FnRust public API

Function Documentation

pub fn warp_polar( input: &Image, center_x: f32, center_y: f32, max_radius: f32, out_width: u32, out_height: u32, mode: PolarMode, interpolation: InterpolationMode, border: BorderMode, border_value: f32 ) -> Result<Image>
Warp each image plane to polar coordinates about a center, following warpPolar: output row y is the angular axis [0, 2pi) and column x is the radial axis — x / width * max_radius under Linear or max_radius^(x / width) under SemiLog. Source samples gather with the admitted interpolation and border policy. Errors Returns an error unless the image is a nonempty FP32 NCHW/CHW image, the center and radius are finite with max_radius > 0, the output extent is nonzero, border_value is finite, and all sizes fit the shader ABI.