MCPcopy Create free account
hub / github.com/ByteArena/box2d / B2IsValid

Function B2IsValid

CommonB2Math.go:16–18  ·  view source on GitHub ↗

b2Math.h This function is used to ensure that a floating point number is not a NaN or infinity.

(x float64)

Source from the content-addressed store, hash-verified

14
15/// This function is used to ensure that a floating point number is not a NaN or infinity.
16func B2IsValid(x float64) bool {
17 return !math.IsNaN(x) && !math.IsInf(x, 0)
18}
19
20/// This is a approximate yet fast inverse square-root.
21func B2InvSqrt(x float64) float64 {

Callers 10

NewB2BodyFunction · 0.85
SetMaxForceMethod · 0.85
SetMaxTorqueMethod · 0.85
SetCorrectionFactorMethod · 0.85
SetRatioMethod · 0.85
SetMaxForceMethod · 0.85
SetMaxTorqueMethod · 0.85
IsValidMethod · 0.85
SetDensityMethod · 0.85
MakeB2MouseJointFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected