lerpAngle

fun lerpAngle(fromRadians: Float, toRadians: Float, progress: Float): Float

Linearly interpolates between two angles in radians. Takes into account that angles wrap at two pi and always takes the direction with the smallest delta angle.

Return

the interpolated angle in the range [0, PI2[

Parameters

fromRadians

start angle in radians

toRadians

target angle in radians

progress

interpolation value in the range 0, 1