computeBoundingBox method

  1. @override
void computeBoundingBox()
override

Implementation

@override
computeBoundingBox() {
  var box = Box3(null, null);

  boundingBox ??= Box3(null, null);

  var start = attributes["instanceStart"];
  var end = attributes["instanceEnd"];

  if (start != null && end != null) {
    boundingBox!.setFromBufferAttribute(start);

    box.setFromBufferAttribute(end);

    boundingBox!.union(box);
  }
}