Explorar o código

fixed lines bounding sphere calc

Alexander Rose %!s(int64=6) %!d(string=hai) anos
pai
achega
8097d6e75b
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      src/mol-geo/geometry/lines/lines.ts

+ 2 - 2
src/mol-geo/geometry/lines/lines.ts

@@ -174,8 +174,8 @@ export namespace Lines {
 }
 
 function getBoundingSphere(lineStart: Float32Array, lineEnd: Float32Array, lineCount: number, transform: Float32Array, transformCount: number) {
-    const start = calculateBoundingSphere(lineStart, lineCount, transform, transformCount)
-    const end = calculateBoundingSphere(lineEnd, lineCount, transform, transformCount)
+    const start = calculateBoundingSphere(lineStart, lineCount * 4, transform, transformCount)
+    const end = calculateBoundingSphere(lineEnd, lineCount * 4, transform, transformCount)
     return {
         boundingSphere: Sphere3D.addSphere(start.boundingSphere, end.boundingSphere),
         invariantBoundingSphere: Sphere3D.addSphere(start.invariantBoundingSphere, end.invariantBoundingSphere)