sample_warp_displacement

Function sample_warp_displacement 

Source
fn sample_warp_displacement(field: &WarpField<'_>, x: f32, y: f32) -> (f32, f32)
Expand description

Look up the warp displacement at preset-space position (x, y) from field. Bilinear-interpolates across the four nearest mesh cells so the segment direction stays smooth across the grid boundaries. Returns (dx, dy) in preset-space UV units (uv_warp - uv_orig).