Version: 5.4 (switch to 5.5b)
  • C#
  • JS

Script language

Select your preferred scripting language. All code snippets will be displayed in this language.


Suggest a change


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.


Sumbission failed

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



public static function LerpUnclamped(a: float, b: float, t: float): float;
public static float LerpUnclamped(float a, float b, float t);


a 開始値
b 終了値
t 2 つの float を補間


float The float value as a result from the linear interpolation.


ab の間で t による線形補間します。t に制限はありません。

パラメーター t は固定値でなく、ab に基づいた値です。 t が 0 より小さい、または 1 より大きい場合は、LerpUnclampeda から b の範囲を超える返り値になります。

Suppose parameter a = 0.33f, and b = 1.5f. If interpolator t = -0.25f then the return value is 0.0375f.

Details: The calculation (b - a) is 1.17f. This is scaled by 0.25f and a result of 0.2925f is obtained. Subtracting this from a (because the interpolant t is negative) results in 0.0375f.

See Also: Lerp.