GridBroadphase constructor
nx
Number of boxes along x.
ny
Number of boxes along y.
nz
Number of boxes along z.
Implementation
GridBroadphase([
Vector3? aabbMin,// = Vector3(100, 100, 100),
Vector3? aabbMax,// = Vector3(-100, -100, -100),
this.nx = 10,
this.ny = 10,
this.nz = 10
]):super(){
this.aabbMin = aabbMin ?? Vector3(100, 100, 100);
this.aabbMax = aabbMax ?? Vector3(-100, -100, -100);
final nbins = nx * ny * nz;
if (nbins <= 0) {
throw"GridBroadphase: Each dimension's n must be >0";
}
bins = List.filled(nbins, []);
binLengths = List.filled(nbins, 0);
}