Skip to content

Commit

Permalink
feat: use vector math 32 instead of 64
Browse files Browse the repository at this point in the history
  • Loading branch information
renancaraujo committed Dec 14, 2024
1 parent e6ceed6 commit 809729b
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 15 deletions.
2 changes: 0 additions & 2 deletions packages/forge2d/lib/src/collision/distance.dart
Original file line number Diff line number Diff line change
Expand Up @@ -501,8 +501,6 @@ class DistanceProxy {
_count = 2;
radius = edge.radius;
break;
default:
assert(false);
}
}

Expand Down
12 changes: 2 additions & 10 deletions packages/forge2d/lib/src/collision/time_of_impact.dart
Original file line number Diff line number Diff line change
Expand Up @@ -411,12 +411,7 @@ class SeparationFunction {
_pointA.setFrom(Transform.mulVec2(_xfa, _localPointA));

return (_pointA..sub(_pointB)).dot(_normal);
default:
assert(false);
indexes[0] = -1;
indexes[1] = -1;
return 0.0;
}
}
}

double evaluate(int indexA, int indexB, double t) {
Expand Down Expand Up @@ -447,9 +442,6 @@ class SeparationFunction {
_pointA.setFrom(Transform.mulVec2(_xfa, _localPointA));

return (_pointA..sub(_pointB)).dot(_normal);
default:
assert(false);
return 0.0;
}
}
}
}
4 changes: 1 addition & 3 deletions packages/forge2d/lib/src/dynamics/fixture.dart
Original file line number Diff line number Diff line change
Expand Up @@ -321,8 +321,6 @@ class Fixture {
}
}
break;
default:
break;
}
}
}
}

0 comments on commit 809729b

Please sign in to comment.