Closed dennisppaul closed 3 years ago
f(x) = abs(x)
f(x) = x < 0.0 ? 0.0 : x
f(x) = x < 0.0 ? -1.0 : x > 0.0 ? 1.0 : 0.0
Math.signum(0.0f)
f(x) = x > t ? t : x < -t ? -t : x (t=threshold)
f(x) = x - s * pow(x, 3) (s=scaling_factor=[0,1]=default:0.33)
f(x) = (2.0 / PI) * atan(a*x) (a=amount=[1,10])
f(x) = floor(x * s) / s (s=steps=pow(2,bits-1))
floor use
added and cleaned up distortion types
f(x) = abs(x)
)f(x) = x < 0.0 ? 0.0 : x
)f(x) = x < 0.0 ? -1.0 : x > 0.0 ? 1.0 : 0.0
||Math.signum(0.0f)
)f(x) = x > t ? t : x < -t ? -t : x (t=threshold)
)f(x) = x - s * pow(x, 3) (s=scaling_factor=[0,1]=default:0.33)
)f(x) = (2.0 / PI) * atan(a*x) (a=amount=[1,10])
)f(x) = floor(x * s) / s (s=steps=pow(2,bits-1))
) ( instead offloor use
round` )