瀏覽代碼

fix StructureElementSelectionManager.getPrincipalAxes for multiple entries

Alexander Rose 5 年之前
父節點
當前提交
a13c98c36c
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/mol-plugin/util/structure-element-selection.ts

+ 1 - 1
src/mol-plugin/util/structure-element-selection.ts

@@ -83,7 +83,7 @@ class StructureElementSelectionManager {
         let offset = 0
         this.entries.forEach(v => {
             StructureElement.Loci.toPositionsArray(v.selection, positions, offset)
-            offset += StructureElement.Loci.size(v.selection)
+            offset += StructureElement.Loci.size(v.selection) * 3
         })
         return PrincipalAxes.ofPoints(Matrix.fromArray(positions, 3, elementCount))
     }