Version: Unity 6.3 Beta (6000.3)
LanguageEnglish
  • C#

PhysicsRotate.LerpRotation

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Declaration

public LowLevelPhysics2D.PhysicsRotate LerpRotation(LowLevelPhysics2D.PhysicsRotate rotation, float interval);

Parameters

Parameter Description
rotation The rotation to lerp with against the current rotation.
interval The lerp interval, typically in the range [0, 1]. A value outside of this range performs normalized linear extrapolation.

Returns

PhysicsRotate The normalized linear interpolation/extrapolation.

Description

Calculate the normalized linear interpolation of this rotation and the specified rotation using the specified interval.


Declaration

public static LowLevelPhysics2D.PhysicsRotate LerpRotation(LowLevelPhysics2D.PhysicsRotate rotationA, LowLevelPhysics2D.PhysicsRotate rotationB, float interval);

Parameters

Parameter Description
rotationA The rotation to lerp from.
rotationB The rotation to lerp to.
interval The lerp interval, typically in the range [0, 1]. A value outside of this range performs normalized linear extrapolation.

Returns

PhysicsRotate The normalized linear interpolation/extrapolation.

Description

Calculate the normalized linear interpolation between two rotations using the specified fraction.