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

Function B2Vec2Sub

CommonB2Math.go:527–529  ·  view source on GitHub ↗

Subtract two vectors component-wise.

(a, b B2Vec2)

Source from the content-addressed store, hash-verified

525
526// /// Subtract two vectors component-wise.
527func B2Vec2Sub(a, b B2Vec2) B2Vec2 {
528 return MakeB2Vec2(a.X-b.X, a.Y-b.Y)
529}
530
531func B2Vec2MulScalar(s float64, a B2Vec2) B2Vec2 {
532 return MakeB2Vec2(s*a.X, s*a.Y)

Callers 15

ReadCacheMethod · 0.85
GetSearchDirectionMethod · 0.85
GetMetricMethod · 0.85
Solve2Method · 0.85
Solve3Method · 0.85
B2DistanceFunction · 0.85
InitializeMethod · 0.85
FindMinSeparationMethod · 0.85
EvaluateMethod · 0.85
InitializeMethod · 0.85
StepMethod · 0.85
SolveC2Method · 0.85

Calls 1

MakeB2Vec2Function · 0.85

Tested by

no test coverage detected