Processors.StickDeadzone

Static Method in Processors

Declaration

public static Vector2 StickDeadzone(Vector2 input, float min = 0.125F, float max = 0.925F)

Description

A stick deadzone scales the input such that any value with a magnitude smaller than the min results in (0,0), and any value with a magnitude greater than the max is normalized to unit length (1).

Parameters

inputThe input value to scale.
minThe lower deadzone threshold.
maxThe upper deadzone threshold.

Returns

Vector2The scaled input value.

Overload

Declaration

public static Vector3 StickDeadzone(Vector3 input, float min = 0.125F, float max = 0.925F)

Description

A stick deadzone scales the input such that any value with a magnitude smaller than the min results in (0,0), and any value with a magnitude greater than the max is normalized to unit length (1).

Parameters

inputThe input value to scale.
minThe lower deadzone threshold.
maxThe upper deadzone threshold.

Returns

Vector3The scaled input value.

Overload

Declaration

public static Vector4 StickDeadzone(Vector4 input, float min = 0.125F, float max = 0.925F)

Description

A stick deadzone scales the input such that any value with a magnitude smaller than the min results in (0,0), and any value with a magnitude greater than the max is normalized to unit length (1).

Parameters

inputThe input value to scale.
minThe lower deadzone threshold.
maxThe upper deadzone threshold.

Returns

Vector4The scaled input value.