molstar 3.8.2 → 3.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/viewer/index.html +4 -1
- package/build/viewer/molstar.js +1 -1
- package/lib/apps/viewer/app.d.ts +1 -1
- package/lib/apps/viewer/app.js +1 -1
- package/lib/apps/viewer/index.html +4 -1
- package/lib/cli/cif2bcif/converter.js +1 -1
- package/lib/commonjs/apps/viewer/app.d.ts +1 -1
- package/lib/commonjs/apps/viewer/app.js +2 -1
- package/lib/commonjs/cli/cif2bcif/converter.js +1 -1
- package/lib/commonjs/examples/alpha-orbitals/index.d.ts +1 -1
- package/lib/commonjs/examples/alpha-orbitals/index.js +4 -1
- package/lib/commonjs/examples/basic-wrapper/custom-theme.js +1 -1
- package/lib/commonjs/examples/proteopedia-wrapper/coloring.js +3 -3
- package/lib/commonjs/extensions/alpha-orbitals/density.d.ts +1 -1
- package/lib/commonjs/extensions/alpha-orbitals/density.js +6 -2
- package/lib/commonjs/extensions/alpha-orbitals/orbitals.d.ts +1 -1
- package/lib/commonjs/extensions/alpha-orbitals/orbitals.js +6 -3
- package/lib/commonjs/extensions/anvil/algorithm.js +1 -1
- package/lib/commonjs/extensions/cellpack/color/generate.js +1 -1
- package/lib/commonjs/extensions/cellpack/color/provided.js +1 -1
- package/lib/commonjs/extensions/cellpack/state.js +1 -1
- package/lib/commonjs/extensions/dnatco/confal-pyramids/color.js +1 -1
- package/lib/commonjs/extensions/g3d/model.js +1 -1
- package/lib/commonjs/extensions/model-archive/quality-assessment/color/plddt.js +1 -1
- package/lib/commonjs/extensions/model-archive/quality-assessment/color/qmean.js +1 -1
- package/lib/commonjs/extensions/pdbe/structure-quality-report/color.js +1 -1
- package/lib/commonjs/extensions/rcsb/assembly-symmetry/color.js +4 -4
- package/lib/commonjs/extensions/rcsb/validation-report/color/density-fit.js +1 -1
- package/lib/commonjs/extensions/rcsb/validation-report/color/geometry-quality.js +2 -2
- package/lib/commonjs/extensions/rcsb/validation-report/color/random-coil-index.js +1 -1
- package/lib/commonjs/extensions/rcsb/validation-report/representation.js +2 -2
- package/lib/commonjs/mol-canvas3d/canvas3d.js +4 -0
- package/lib/commonjs/mol-canvas3d/controls/trackball.js +7 -7
- package/lib/commonjs/mol-canvas3d/helper/camera-helper.js +14 -14
- package/lib/commonjs/mol-canvas3d/helper/interaction-events.js +5 -5
- package/lib/commonjs/mol-canvas3d/passes/draw.js +34 -5
- package/lib/commonjs/mol-canvas3d/passes/fxaa.js +5 -0
- package/lib/commonjs/mol-canvas3d/passes/marking.js +5 -0
- package/lib/commonjs/mol-canvas3d/passes/multi-sample.js +9 -0
- package/lib/commonjs/mol-canvas3d/passes/pick.d.ts +18 -5
- package/lib/commonjs/mol-canvas3d/passes/pick.js +125 -24
- package/lib/commonjs/mol-canvas3d/passes/postprocessing.js +5 -0
- package/lib/commonjs/mol-canvas3d/passes/smaa.js +4 -0
- package/lib/commonjs/mol-canvas3d/passes/wboit.js +4 -0
- package/lib/commonjs/mol-data/db/column.js +5 -5
- package/lib/commonjs/mol-data/db/table.js +2 -2
- package/lib/commonjs/mol-data/util/array.d.ts +1 -1
- package/lib/commonjs/mol-geo/geometry/texture-mesh/color-smoothing.js +13 -0
- package/lib/commonjs/mol-gl/compute/grid3d.d.ts +2 -2
- package/lib/commonjs/mol-gl/compute/grid3d.js +30 -8
- package/lib/commonjs/mol-gl/compute/histogram-pyramid/reduction.d.ts +1 -1
- package/lib/commonjs/mol-gl/compute/histogram-pyramid/reduction.js +6 -1
- package/lib/commonjs/mol-gl/compute/histogram-pyramid/sum.d.ts +1 -1
- package/lib/commonjs/mol-gl/compute/histogram-pyramid/sum.js +6 -1
- package/lib/commonjs/mol-gl/compute/marching-cubes/active-voxels.d.ts +1 -1
- package/lib/commonjs/mol-gl/compute/marching-cubes/active-voxels.js +6 -1
- package/lib/commonjs/mol-gl/compute/marching-cubes/isosurface.d.ts +1 -1
- package/lib/commonjs/mol-gl/compute/marching-cubes/isosurface.js +10 -10
- package/lib/commonjs/mol-gl/renderer.js +77 -32
- package/lib/commonjs/mol-gl/scene.js +2 -0
- package/lib/commonjs/mol-gl/shader/chunks/assign-color-varying.glsl.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/assign-color-varying.glsl.js +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/assign-material-color.glsl.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/assign-material-color.glsl.js +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/color-frag-params.glsl.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/color-frag-params.glsl.js +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/color-vert-params.glsl.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/color-vert-params.glsl.js +1 -1
- package/lib/commonjs/mol-gl/shader/cylinders.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/cylinders.frag.js +1 -1
- package/lib/commonjs/mol-gl/shader/direct-volume.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/direct-volume.frag.js +1 -1
- package/lib/commonjs/mol-gl/shader/image.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/image.frag.js +1 -1
- package/lib/commonjs/mol-gl/shader/lines.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/lines.frag.js +1 -1
- package/lib/commonjs/mol-gl/shader/mesh.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/mesh.frag.js +1 -1
- package/lib/commonjs/mol-gl/shader/points.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/points.frag.js +1 -1
- package/lib/commonjs/mol-gl/shader/spheres.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/spheres.frag.js +1 -1
- package/lib/commonjs/mol-gl/shader/text.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/text.frag.js +1 -1
- package/lib/commonjs/mol-gl/shader-code.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader-code.js +41 -9
- package/lib/commonjs/mol-gl/webgl/compat.d.ts +34 -1
- package/lib/commonjs/mol-gl/webgl/compat.js +50 -2
- package/lib/commonjs/mol-gl/webgl/context.d.ts +2 -0
- package/lib/commonjs/mol-gl/webgl/context.js +3 -0
- package/lib/commonjs/mol-gl/webgl/extensions.d.ts +3 -2
- package/lib/commonjs/mol-gl/webgl/extensions.js +6 -1
- package/lib/commonjs/mol-gl/webgl/timer.d.ts +22 -0
- package/lib/commonjs/mol-gl/webgl/timer.js +169 -0
- package/lib/commonjs/mol-io/common/binary-cif/array-encoder.js +18 -18
- package/lib/commonjs/mol-io/common/binary-cif/decoder.js +16 -16
- package/lib/commonjs/mol-io/common/binary-cif/encoding.js +9 -9
- package/lib/commonjs/mol-io/reader/cif/binary/field.js +3 -3
- package/lib/commonjs/mol-io/reader/cif/data-model.js +14 -14
- package/lib/commonjs/mol-io/reader/cif/schema.js +1 -1
- package/lib/commonjs/mol-io/reader/cif/text/parser.js +23 -23
- package/lib/commonjs/mol-io/reader/common/text/column/fixed.js +1 -1
- package/lib/commonjs/mol-io/reader/common/text/column/token.js +1 -1
- package/lib/commonjs/mol-io/reader/common/text/number-parser.js +6 -6
- package/lib/commonjs/mol-io/reader/csv/parser.js +8 -8
- package/lib/commonjs/mol-io/writer/cif/encoder/binary.js +10 -10
- package/lib/commonjs/mol-io/writer/cif/encoder/text.js +7 -7
- package/lib/commonjs/mol-io/writer/cif/encoder.js +8 -8
- package/lib/commonjs/mol-io/writer/mol2/encoder.js +4 -4
- package/lib/commonjs/mol-math/geometry/gaussian-density/gpu.js +13 -2
- package/lib/commonjs/mol-model/sequence/alignment/sequence.js +3 -3
- package/lib/commonjs/mol-model/sequence/sequence.js +9 -9
- package/lib/commonjs/mol-model/structure/export/categories/atom_site_operator_mapping.js +3 -3
- package/lib/commonjs/mol-model/structure/export/categories/secondary-structure.js +2 -2
- package/lib/commonjs/mol-model/structure/export/categories/utils.js +1 -1
- package/lib/commonjs/mol-model/structure/model/model.js +2 -2
- package/lib/commonjs/mol-model/structure/model/properties/custom/indexed.js +6 -6
- package/lib/commonjs/mol-model/structure/model/properties/utils/atomic-ranges.js +1 -1
- package/lib/commonjs/mol-model/structure/model/types.js +116 -116
- package/lib/commonjs/mol-model/structure/query/context.js +1 -1
- package/lib/commonjs/mol-model/structure/query/queries/generators.js +5 -5
- package/lib/commonjs/mol-model/structure/query/queries/internal.js +4 -4
- package/lib/commonjs/mol-model/structure/query/queries/modifiers.js +4 -4
- package/lib/commonjs/mol-model/structure/query/utils/structure-distance.d.ts +5 -54
- package/lib/commonjs/mol-model/structure/query/utils/structure-distance.js +9 -9
- package/lib/commonjs/mol-model/structure/structure/carbohydrates/constants.js +106 -106
- package/lib/commonjs/mol-model/structure/structure/element/loci.js +5 -5
- package/lib/commonjs/mol-model/structure/structure/element/stats.js +5 -5
- package/lib/commonjs/mol-model/structure/structure/properties.js +5 -5
- package/lib/commonjs/mol-model/structure/structure/structure.js +11 -11
- package/lib/commonjs/mol-model/structure/structure/unit/bonds/inter-compute.js +5 -5
- package/lib/commonjs/mol-model/structure/structure/unit/bonds/intra-compute.js +4 -4
- package/lib/commonjs/mol-model/structure/structure/unit/bonds.js +2 -2
- package/lib/commonjs/mol-model/structure/structure/unit/resonance.js +1 -1
- package/lib/commonjs/mol-model/structure/structure/unit/rings/compute.js +6 -6
- package/lib/commonjs/mol-model/structure/structure/unit/rings.js +6 -6
- package/lib/commonjs/mol-model/structure/structure/unit.js +16 -16
- package/lib/commonjs/mol-model/structure/structure/util/superposition-sifts-mapping.js +1 -1
- package/lib/commonjs/mol-model/structure/util.js +4 -4
- package/lib/commonjs/mol-model-formats/structure/basic/atomic.js +2 -2
- package/lib/commonjs/mol-model-formats/structure/basic/parser.js +4 -4
- package/lib/commonjs/mol-model-formats/structure/basic/properties.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/basic/sort.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/basic/util.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/cif-core.js +6 -6
- package/lib/commonjs/mol-model-formats/structure/common/entity.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/cube.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/gro.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/mol.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/mol2.js +4 -4
- package/lib/commonjs/mol-model-formats/structure/prmtop.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/property/bonds/chem_comp.js +3 -3
- package/lib/commonjs/mol-model-formats/structure/property/bonds/index-pair.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/property/bonds/struct_conn.js +6 -6
- package/lib/commonjs/mol-model-formats/structure/property/secondary-structure.js +8 -8
- package/lib/commonjs/mol-model-formats/structure/psf.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/top.js +1 -1
- package/lib/commonjs/mol-model-formats/structure/xyz.js +1 -1
- package/lib/commonjs/mol-model-props/computed/accessible-surface-area/shrake-rupley/radii.js +2 -2
- package/lib/commonjs/mol-model-props/computed/accessible-surface-area/shrake-rupley.js +3 -3
- package/lib/commonjs/mol-model-props/computed/accessible-surface-area.js +2 -2
- package/lib/commonjs/mol-model-props/computed/chemistry/functional-group.js +31 -31
- package/lib/commonjs/mol-model-props/computed/chemistry/geometry.js +22 -22
- package/lib/commonjs/mol-model-props/computed/chemistry/valence-model.js +32 -32
- package/lib/commonjs/mol-model-props/computed/interactions/charged.js +39 -39
- package/lib/commonjs/mol-model-props/computed/interactions/common.js +34 -34
- package/lib/commonjs/mol-model-props/computed/interactions/contacts-builder.js +1 -1
- package/lib/commonjs/mol-model-props/computed/interactions/contacts.js +1 -1
- package/lib/commonjs/mol-model-props/computed/interactions/halogen-bonds.js +12 -12
- package/lib/commonjs/mol-model-props/computed/interactions/hydrogen-bonds.js +32 -32
- package/lib/commonjs/mol-model-props/computed/interactions/hydrophobic.js +9 -9
- package/lib/commonjs/mol-model-props/computed/interactions/metal.js +26 -26
- package/lib/commonjs/mol-model-props/computed/interactions/refine.js +20 -20
- package/lib/commonjs/mol-model-props/computed/representations/interactions-inter-unit-cylinder.js +2 -2
- package/lib/commonjs/mol-model-props/computed/representations/interactions-intra-unit-cylinder.js +2 -2
- package/lib/commonjs/mol-model-props/computed/secondary-structure/dssp/bends.js +1 -1
- package/lib/commonjs/mol-model-props/computed/secondary-structure/dssp/bridges.js +12 -12
- package/lib/commonjs/mol-model-props/computed/secondary-structure/dssp/helices.js +6 -6
- package/lib/commonjs/mol-model-props/computed/secondary-structure/dssp/ladders.js +3 -3
- package/lib/commonjs/mol-model-props/computed/secondary-structure/dssp/sheets.js +11 -11
- package/lib/commonjs/mol-model-props/computed/secondary-structure/dssp/turns.js +3 -3
- package/lib/commonjs/mol-model-props/computed/secondary-structure/dssp.js +30 -30
- package/lib/commonjs/mol-model-props/computed/themes/accessible-surface-area.js +1 -1
- package/lib/commonjs/mol-model-props/computed/themes/interaction-type.js +10 -10
- package/lib/commonjs/mol-model-props/integrative/cross-link-restraint/color.js +1 -1
- package/lib/commonjs/mol-model-props/integrative/cross-link-restraint/format.js +3 -3
- package/lib/commonjs/mol-model-props/sequence/sifts-mapping.js +1 -1
- package/lib/commonjs/mol-model-props/sequence/themes/sifts-mapping.js +1 -1
- package/lib/commonjs/mol-plugin/animation-loop.d.ts +2 -1
- package/lib/commonjs/mol-plugin/animation-loop.js +18 -5
- package/lib/commonjs/mol-plugin/behavior/dynamic/camera.js +12 -12
- package/lib/commonjs/mol-plugin/behavior/dynamic/representation.js +7 -7
- package/lib/commonjs/mol-plugin/context.d.ts +2 -2
- package/lib/commonjs/mol-plugin/state.d.ts +1 -14
- package/lib/commonjs/mol-plugin-state/formats/volume.d.ts +12 -11
- package/lib/commonjs/mol-plugin-state/formats/volume.js +20 -13
- package/lib/commonjs/mol-plugin-state/helpers/structure-selection-query.js +5 -5
- package/lib/commonjs/mol-plugin-state/transforms/representation.js +2 -2
- package/lib/commonjs/mol-plugin-ui/controls/parameters.d.ts +1 -1
- package/lib/commonjs/mol-plugin-ui/sequence/polymer.js +1 -1
- package/lib/commonjs/mol-plugin-ui/sequence/sequence.js +1 -1
- package/lib/commonjs/mol-plugin-ui/structure/focus.js +1 -1
- package/lib/commonjs/mol-plugin-ui/viewport.d.ts +2 -2
- package/lib/commonjs/mol-repr/structure/visual/bond-inter-unit-cylinder.js +10 -10
- package/lib/commonjs/mol-repr/structure/visual/bond-inter-unit-line.js +10 -10
- package/lib/commonjs/mol-repr/structure/visual/bond-intra-unit-cylinder.js +12 -12
- package/lib/commonjs/mol-repr/structure/visual/bond-intra-unit-line.js +12 -12
- package/lib/commonjs/mol-repr/structure/visual/carbohydrate-symbol-mesh.js +16 -16
- package/lib/commonjs/mol-repr/structure/visual/carbohydrate-terminal-link-cylinder.js +1 -1
- package/lib/commonjs/mol-repr/structure/visual/gaussian-surface-mesh.js +9 -0
- package/lib/commonjs/mol-repr/structure/visual/orientation-ellipsoid-mesh.js +4 -4
- package/lib/commonjs/mol-repr/structure/visual/polymer-direction-wedge.js +1 -1
- package/lib/commonjs/mol-repr/structure/visual/polymer-trace-mesh.js +2 -2
- package/lib/commonjs/mol-repr/structure/visual/util/bond.js +2 -2
- package/lib/commonjs/mol-repr/structure/visual/util/common.js +3 -3
- package/lib/commonjs/mol-repr/structure/visual/util/link.js +30 -30
- package/lib/commonjs/mol-repr/structure/visual/util/polymer/backbone.js +6 -6
- package/lib/commonjs/mol-repr/structure/visual/util/polymer/gap-iterator.js +3 -3
- package/lib/commonjs/mol-repr/structure/visual/util/polymer/trace-iterator.js +20 -20
- package/lib/commonjs/mol-repr/structure/visual/util/polymer.js +6 -6
- package/lib/commonjs/mol-script/language/symbol-table/core.d.ts +2 -2
- package/lib/commonjs/mol-script/runtime/query/table.js +13 -13
- package/lib/commonjs/mol-state/object.d.ts +3 -3
- package/lib/commonjs/mol-task/util/user-timing.js +1 -1
- package/lib/commonjs/mol-theme/clipping.js +19 -19
- package/lib/commonjs/mol-theme/color/atom-id.js +1 -1
- package/lib/commonjs/mol-theme/color/carbohydrate-symbol.js +1 -1
- package/lib/commonjs/mol-theme/color/chain-id.js +4 -4
- package/lib/commonjs/mol-theme/color/element-index.js +1 -1
- package/lib/commonjs/mol-theme/color/element-symbol.js +1 -1
- package/lib/commonjs/mol-theme/color/entity-id.js +4 -4
- package/lib/commonjs/mol-theme/color/entity-source.js +5 -4
- package/lib/commonjs/mol-theme/color/hydrophobicity.js +1 -1
- package/lib/commonjs/mol-theme/color/illustrative.js +1 -1
- package/lib/commonjs/mol-theme/color/model-index.js +1 -1
- package/lib/commonjs/mol-theme/color/molecule-type.js +8 -8
- package/lib/commonjs/mol-theme/color/occupancy.js +1 -1
- package/lib/commonjs/mol-theme/color/operator-hkl.js +1 -1
- package/lib/commonjs/mol-theme/color/operator-name.js +1 -1
- package/lib/commonjs/mol-theme/color/partial-charge.js +1 -1
- package/lib/commonjs/mol-theme/color/polymer-id.js +4 -4
- package/lib/commonjs/mol-theme/color/polymer-index.js +1 -1
- package/lib/commonjs/mol-theme/color/residue-name.js +1 -1
- package/lib/commonjs/mol-theme/color/secondary-structure.js +12 -12
- package/lib/commonjs/mol-theme/color/sequence-id.js +7 -7
- package/lib/commonjs/mol-theme/color/shape-group.js +1 -1
- package/lib/commonjs/mol-theme/color/uncertainty.js +1 -1
- package/lib/commonjs/mol-theme/color/uniform.js +1 -1
- package/lib/commonjs/mol-theme/color/unit-index.js +1 -1
- package/lib/commonjs/mol-theme/color/volume-value.js +1 -1
- package/lib/commonjs/mol-theme/label.js +3 -3
- package/lib/commonjs/mol-util/binding.js +4 -4
- package/lib/commonjs/mol-util/debug.d.ts +6 -1
- package/lib/commonjs/mol-util/debug.js +11 -1
- package/lib/commonjs/mol-util/input/input-observer.js +20 -20
- package/lib/commonjs/mol-util/string-builder.js +1 -1
- package/lib/commonjs/servers/model/preprocess/converter.js +1 -1
- package/lib/commonjs/servers/model/server/query.js +1 -1
- package/lib/commonjs/servers/model/utils/fetch-retry.js +3 -2
- package/lib/commonjs/servers/volume/server/algebra/coordinate.js +6 -6
- package/lib/commonjs/servers/volume/server/query/encode.js +1 -1
- package/lib/examples/alpha-orbitals/index.d.ts +1 -1
- package/lib/examples/alpha-orbitals/index.html +11 -0
- package/lib/examples/alpha-orbitals/index.js +4 -1
- package/lib/examples/basic-wrapper/custom-theme.js +1 -1
- package/lib/examples/proteopedia-wrapper/coloring.js +3 -3
- package/lib/extensions/alpha-orbitals/density.d.ts +1 -1
- package/lib/extensions/alpha-orbitals/density.js +6 -2
- package/lib/extensions/alpha-orbitals/orbitals.d.ts +1 -1
- package/lib/extensions/alpha-orbitals/orbitals.js +6 -3
- package/lib/extensions/anvil/algorithm.js +1 -1
- package/lib/extensions/cellpack/color/generate.js +1 -1
- package/lib/extensions/cellpack/color/provided.js +1 -1
- package/lib/extensions/cellpack/state.js +1 -1
- package/lib/extensions/dnatco/confal-pyramids/color.js +1 -1
- package/lib/extensions/g3d/model.js +1 -1
- package/lib/extensions/model-archive/quality-assessment/color/plddt.js +1 -1
- package/lib/extensions/model-archive/quality-assessment/color/qmean.js +1 -1
- package/lib/extensions/pdbe/structure-quality-report/color.js +1 -1
- package/lib/extensions/rcsb/assembly-symmetry/color.js +4 -4
- package/lib/extensions/rcsb/validation-report/color/density-fit.js +1 -1
- package/lib/extensions/rcsb/validation-report/color/geometry-quality.js +2 -2
- package/lib/extensions/rcsb/validation-report/color/random-coil-index.js +1 -1
- package/lib/extensions/rcsb/validation-report/representation.js +2 -2
- package/lib/mol-canvas3d/canvas3d.js +5 -1
- package/lib/mol-canvas3d/controls/trackball.js +7 -7
- package/lib/mol-canvas3d/helper/camera-helper.js +14 -14
- package/lib/mol-canvas3d/helper/interaction-events.js +5 -5
- package/lib/mol-canvas3d/passes/draw.js +34 -5
- package/lib/mol-canvas3d/passes/fxaa.js +5 -0
- package/lib/mol-canvas3d/passes/marking.js +5 -0
- package/lib/mol-canvas3d/passes/multi-sample.js +9 -0
- package/lib/mol-canvas3d/passes/pick.d.ts +18 -5
- package/lib/mol-canvas3d/passes/pick.js +125 -24
- package/lib/mol-canvas3d/passes/postprocessing.js +5 -0
- package/lib/mol-canvas3d/passes/smaa.js +5 -1
- package/lib/mol-canvas3d/passes/wboit.js +5 -1
- package/lib/mol-data/db/column.js +5 -5
- package/lib/mol-data/db/table.js +2 -2
- package/lib/mol-data/util/array.d.ts +1 -1
- package/lib/mol-geo/geometry/texture-mesh/color-smoothing.js +13 -0
- package/lib/mol-gl/compute/grid3d.d.ts +2 -2
- package/lib/mol-gl/compute/grid3d.js +30 -8
- package/lib/mol-gl/compute/histogram-pyramid/reduction.d.ts +1 -1
- package/lib/mol-gl/compute/histogram-pyramid/reduction.js +6 -1
- package/lib/mol-gl/compute/histogram-pyramid/sum.d.ts +1 -1
- package/lib/mol-gl/compute/histogram-pyramid/sum.js +6 -1
- package/lib/mol-gl/compute/marching-cubes/active-voxels.d.ts +1 -1
- package/lib/mol-gl/compute/marching-cubes/active-voxels.js +6 -1
- package/lib/mol-gl/compute/marching-cubes/isosurface.d.ts +1 -1
- package/lib/mol-gl/compute/marching-cubes/isosurface.js +10 -10
- package/lib/mol-gl/renderer.js +77 -32
- package/lib/mol-gl/scene.js +2 -0
- package/lib/mol-gl/shader/chunks/assign-color-varying.glsl.d.ts +1 -1
- package/lib/mol-gl/shader/chunks/assign-color-varying.glsl.js +1 -1
- package/lib/mol-gl/shader/chunks/assign-material-color.glsl.d.ts +1 -1
- package/lib/mol-gl/shader/chunks/assign-material-color.glsl.js +1 -1
- package/lib/mol-gl/shader/chunks/color-frag-params.glsl.d.ts +1 -1
- package/lib/mol-gl/shader/chunks/color-frag-params.glsl.js +1 -1
- package/lib/mol-gl/shader/chunks/color-vert-params.glsl.d.ts +1 -1
- package/lib/mol-gl/shader/chunks/color-vert-params.glsl.js +1 -1
- package/lib/mol-gl/shader/cylinders.frag.d.ts +1 -1
- package/lib/mol-gl/shader/cylinders.frag.js +1 -1
- package/lib/mol-gl/shader/direct-volume.frag.d.ts +1 -1
- package/lib/mol-gl/shader/direct-volume.frag.js +1 -1
- package/lib/mol-gl/shader/image.frag.d.ts +1 -1
- package/lib/mol-gl/shader/image.frag.js +1 -1
- package/lib/mol-gl/shader/lines.frag.d.ts +1 -1
- package/lib/mol-gl/shader/lines.frag.js +1 -1
- package/lib/mol-gl/shader/mesh.frag.d.ts +1 -1
- package/lib/mol-gl/shader/mesh.frag.js +1 -1
- package/lib/mol-gl/shader/points.frag.d.ts +1 -1
- package/lib/mol-gl/shader/points.frag.js +1 -1
- package/lib/mol-gl/shader/spheres.frag.d.ts +1 -1
- package/lib/mol-gl/shader/spheres.frag.js +1 -1
- package/lib/mol-gl/shader/text.frag.d.ts +1 -1
- package/lib/mol-gl/shader/text.frag.js +1 -1
- package/lib/mol-gl/shader-code.d.ts +1 -1
- package/lib/mol-gl/shader-code.js +41 -9
- package/lib/mol-gl/webgl/compat.d.ts +34 -1
- package/lib/mol-gl/webgl/compat.js +48 -1
- package/lib/mol-gl/webgl/context.d.ts +2 -0
- package/lib/mol-gl/webgl/context.js +3 -0
- package/lib/mol-gl/webgl/extensions.d.ts +3 -2
- package/lib/mol-gl/webgl/extensions.js +7 -2
- package/lib/mol-gl/webgl/timer.d.ts +22 -0
- package/lib/mol-gl/webgl/timer.js +164 -0
- package/lib/mol-io/common/binary-cif/array-encoder.js +18 -18
- package/lib/mol-io/common/binary-cif/decoder.js +16 -16
- package/lib/mol-io/common/binary-cif/encoding.js +9 -9
- package/lib/mol-io/reader/cif/binary/field.js +3 -3
- package/lib/mol-io/reader/cif/data-model.js +14 -14
- package/lib/mol-io/reader/cif/schema.js +1 -1
- package/lib/mol-io/reader/cif/text/parser.js +23 -23
- package/lib/mol-io/reader/common/text/column/fixed.js +1 -1
- package/lib/mol-io/reader/common/text/column/token.js +1 -1
- package/lib/mol-io/reader/common/text/number-parser.js +6 -6
- package/lib/mol-io/reader/csv/parser.js +8 -8
- package/lib/mol-io/writer/cif/encoder/binary.js +10 -10
- package/lib/mol-io/writer/cif/encoder/text.js +7 -7
- package/lib/mol-io/writer/cif/encoder.js +8 -8
- package/lib/mol-io/writer/mol2/encoder.js +4 -4
- package/lib/mol-math/geometry/gaussian-density/gpu.js +13 -2
- package/lib/mol-model/sequence/alignment/sequence.js +3 -3
- package/lib/mol-model/sequence/sequence.js +9 -9
- package/lib/mol-model/structure/export/categories/atom_site_operator_mapping.js +3 -3
- package/lib/mol-model/structure/export/categories/secondary-structure.js +2 -2
- package/lib/mol-model/structure/export/categories/utils.js +1 -1
- package/lib/mol-model/structure/model/model.js +2 -2
- package/lib/mol-model/structure/model/properties/custom/indexed.js +6 -6
- package/lib/mol-model/structure/model/properties/utils/atomic-ranges.js +1 -1
- package/lib/mol-model/structure/model/types.js +116 -116
- package/lib/mol-model/structure/query/context.js +1 -1
- package/lib/mol-model/structure/query/queries/generators.js +5 -5
- package/lib/mol-model/structure/query/queries/internal.js +4 -4
- package/lib/mol-model/structure/query/queries/modifiers.js +4 -4
- package/lib/mol-model/structure/query/utils/structure-distance.d.ts +5 -54
- package/lib/mol-model/structure/query/utils/structure-distance.js +9 -9
- package/lib/mol-model/structure/structure/carbohydrates/constants.js +106 -106
- package/lib/mol-model/structure/structure/element/loci.js +5 -5
- package/lib/mol-model/structure/structure/element/stats.js +5 -5
- package/lib/mol-model/structure/structure/properties.js +5 -5
- package/lib/mol-model/structure/structure/structure.js +11 -11
- package/lib/mol-model/structure/structure/unit/bonds/inter-compute.js +5 -5
- package/lib/mol-model/structure/structure/unit/bonds/intra-compute.js +4 -4
- package/lib/mol-model/structure/structure/unit/bonds.js +2 -2
- package/lib/mol-model/structure/structure/unit/resonance.js +1 -1
- package/lib/mol-model/structure/structure/unit/rings/compute.js +6 -6
- package/lib/mol-model/structure/structure/unit/rings.js +6 -6
- package/lib/mol-model/structure/structure/unit.js +16 -16
- package/lib/mol-model/structure/structure/util/superposition-sifts-mapping.js +1 -1
- package/lib/mol-model/structure/util.js +4 -4
- package/lib/mol-model-formats/structure/basic/atomic.js +2 -2
- package/lib/mol-model-formats/structure/basic/parser.js +4 -4
- package/lib/mol-model-formats/structure/basic/properties.js +1 -1
- package/lib/mol-model-formats/structure/basic/sort.js +1 -1
- package/lib/mol-model-formats/structure/basic/util.js +1 -1
- package/lib/mol-model-formats/structure/cif-core.js +6 -6
- package/lib/mol-model-formats/structure/common/entity.js +1 -1
- package/lib/mol-model-formats/structure/cube.js +1 -1
- package/lib/mol-model-formats/structure/gro.js +1 -1
- package/lib/mol-model-formats/structure/mol.js +1 -1
- package/lib/mol-model-formats/structure/mol2.js +4 -4
- package/lib/mol-model-formats/structure/prmtop.js +1 -1
- package/lib/mol-model-formats/structure/property/bonds/chem_comp.js +3 -3
- package/lib/mol-model-formats/structure/property/bonds/index-pair.js +1 -1
- package/lib/mol-model-formats/structure/property/bonds/struct_conn.js +6 -6
- package/lib/mol-model-formats/structure/property/secondary-structure.js +8 -8
- package/lib/mol-model-formats/structure/psf.js +1 -1
- package/lib/mol-model-formats/structure/top.js +1 -1
- package/lib/mol-model-formats/structure/xyz.js +1 -1
- package/lib/mol-model-props/computed/accessible-surface-area/shrake-rupley/radii.js +2 -2
- package/lib/mol-model-props/computed/accessible-surface-area/shrake-rupley.js +3 -3
- package/lib/mol-model-props/computed/accessible-surface-area.js +2 -2
- package/lib/mol-model-props/computed/chemistry/functional-group.js +31 -31
- package/lib/mol-model-props/computed/chemistry/geometry.js +22 -22
- package/lib/mol-model-props/computed/chemistry/valence-model.js +32 -32
- package/lib/mol-model-props/computed/interactions/charged.js +39 -39
- package/lib/mol-model-props/computed/interactions/common.js +34 -34
- package/lib/mol-model-props/computed/interactions/contacts-builder.js +1 -1
- package/lib/mol-model-props/computed/interactions/contacts.js +1 -1
- package/lib/mol-model-props/computed/interactions/halogen-bonds.js +12 -12
- package/lib/mol-model-props/computed/interactions/hydrogen-bonds.js +32 -32
- package/lib/mol-model-props/computed/interactions/hydrophobic.js +9 -9
- package/lib/mol-model-props/computed/interactions/metal.js +26 -26
- package/lib/mol-model-props/computed/interactions/refine.js +20 -20
- package/lib/mol-model-props/computed/representations/interactions-inter-unit-cylinder.js +2 -2
- package/lib/mol-model-props/computed/representations/interactions-intra-unit-cylinder.js +2 -2
- package/lib/mol-model-props/computed/secondary-structure/dssp/bends.js +1 -1
- package/lib/mol-model-props/computed/secondary-structure/dssp/bridges.js +12 -12
- package/lib/mol-model-props/computed/secondary-structure/dssp/helices.js +6 -6
- package/lib/mol-model-props/computed/secondary-structure/dssp/ladders.js +3 -3
- package/lib/mol-model-props/computed/secondary-structure/dssp/sheets.js +11 -11
- package/lib/mol-model-props/computed/secondary-structure/dssp/turns.js +3 -3
- package/lib/mol-model-props/computed/secondary-structure/dssp.js +30 -30
- package/lib/mol-model-props/computed/themes/accessible-surface-area.js +1 -1
- package/lib/mol-model-props/computed/themes/interaction-type.js +10 -10
- package/lib/mol-model-props/integrative/cross-link-restraint/color.js +1 -1
- package/lib/mol-model-props/integrative/cross-link-restraint/format.js +3 -3
- package/lib/mol-model-props/sequence/sifts-mapping.js +1 -1
- package/lib/mol-model-props/sequence/themes/sifts-mapping.js +1 -1
- package/lib/mol-plugin/animation-loop.d.ts +2 -1
- package/lib/mol-plugin/animation-loop.js +18 -5
- package/lib/mol-plugin/behavior/dynamic/camera.js +12 -12
- package/lib/mol-plugin/behavior/dynamic/representation.js +7 -7
- package/lib/mol-plugin/context.d.ts +2 -2
- package/lib/mol-plugin/state.d.ts +1 -14
- package/lib/mol-plugin/version.js +2 -2
- package/lib/mol-plugin-state/formats/volume.d.ts +12 -11
- package/lib/mol-plugin-state/formats/volume.js +20 -13
- package/lib/mol-plugin-state/helpers/structure-selection-query.js +5 -5
- package/lib/mol-plugin-state/transforms/representation.js +2 -2
- package/lib/mol-plugin-ui/controls/parameters.d.ts +1 -1
- package/lib/mol-plugin-ui/sequence/polymer.js +1 -1
- package/lib/mol-plugin-ui/sequence/sequence.js +1 -1
- package/lib/mol-plugin-ui/structure/focus.js +1 -1
- package/lib/mol-plugin-ui/viewport.d.ts +2 -2
- package/lib/mol-repr/structure/visual/bond-inter-unit-cylinder.js +10 -10
- package/lib/mol-repr/structure/visual/bond-inter-unit-line.js +10 -10
- package/lib/mol-repr/structure/visual/bond-intra-unit-cylinder.js +12 -12
- package/lib/mol-repr/structure/visual/bond-intra-unit-line.js +12 -12
- package/lib/mol-repr/structure/visual/carbohydrate-symbol-mesh.js +16 -16
- package/lib/mol-repr/structure/visual/carbohydrate-terminal-link-cylinder.js +1 -1
- package/lib/mol-repr/structure/visual/gaussian-surface-mesh.js +9 -0
- package/lib/mol-repr/structure/visual/orientation-ellipsoid-mesh.js +4 -4
- package/lib/mol-repr/structure/visual/polymer-direction-wedge.js +1 -1
- package/lib/mol-repr/structure/visual/polymer-trace-mesh.js +2 -2
- package/lib/mol-repr/structure/visual/util/bond.js +2 -2
- package/lib/mol-repr/structure/visual/util/common.js +3 -3
- package/lib/mol-repr/structure/visual/util/link.js +30 -30
- package/lib/mol-repr/structure/visual/util/polymer/backbone.js +6 -6
- package/lib/mol-repr/structure/visual/util/polymer/gap-iterator.js +3 -3
- package/lib/mol-repr/structure/visual/util/polymer/trace-iterator.js +20 -20
- package/lib/mol-repr/structure/visual/util/polymer.js +6 -6
- package/lib/mol-script/language/symbol-table/core.d.ts +2 -2
- package/lib/mol-script/runtime/query/table.js +13 -13
- package/lib/mol-state/object.d.ts +3 -3
- package/lib/mol-task/util/user-timing.js +1 -1
- package/lib/mol-theme/clipping.js +19 -19
- package/lib/mol-theme/color/atom-id.js +1 -1
- package/lib/mol-theme/color/carbohydrate-symbol.js +1 -1
- package/lib/mol-theme/color/chain-id.js +4 -4
- package/lib/mol-theme/color/element-index.js +1 -1
- package/lib/mol-theme/color/element-symbol.js +1 -1
- package/lib/mol-theme/color/entity-id.js +4 -4
- package/lib/mol-theme/color/entity-source.js +5 -4
- package/lib/mol-theme/color/hydrophobicity.js +1 -1
- package/lib/mol-theme/color/illustrative.js +1 -1
- package/lib/mol-theme/color/model-index.js +1 -1
- package/lib/mol-theme/color/molecule-type.js +8 -8
- package/lib/mol-theme/color/occupancy.js +1 -1
- package/lib/mol-theme/color/operator-hkl.js +1 -1
- package/lib/mol-theme/color/operator-name.js +1 -1
- package/lib/mol-theme/color/partial-charge.js +1 -1
- package/lib/mol-theme/color/polymer-id.js +4 -4
- package/lib/mol-theme/color/polymer-index.js +1 -1
- package/lib/mol-theme/color/residue-name.js +1 -1
- package/lib/mol-theme/color/secondary-structure.js +12 -12
- package/lib/mol-theme/color/sequence-id.js +7 -7
- package/lib/mol-theme/color/shape-group.js +1 -1
- package/lib/mol-theme/color/uncertainty.js +1 -1
- package/lib/mol-theme/color/uniform.js +1 -1
- package/lib/mol-theme/color/unit-index.js +1 -1
- package/lib/mol-theme/color/volume-value.js +1 -1
- package/lib/mol-theme/label.js +3 -3
- package/lib/mol-util/binding.js +4 -4
- package/lib/mol-util/debug.d.ts +6 -1
- package/lib/mol-util/debug.js +9 -1
- package/lib/mol-util/input/input-observer.js +20 -20
- package/lib/mol-util/string-builder.js +1 -1
- package/lib/servers/model/preprocess/converter.js +1 -1
- package/lib/servers/model/server/query.js +1 -1
- package/lib/servers/model/utils/fetch-retry.js +3 -2
- package/lib/servers/volume/server/algebra/coordinate.js +6 -6
- package/lib/servers/volume/server/query/encode.js +1 -1
- package/package.json +8 -8
package/lib/apps/viewer/app.d.ts
CHANGED
|
@@ -19,7 +19,7 @@ import { StateObjectSelector } from '../../mol-state';
|
|
|
19
19
|
import { Color } from '../../mol-util/color';
|
|
20
20
|
import '../../mol-util/polyfill';
|
|
21
21
|
export { PLUGIN_VERSION as version } from '../../mol-plugin/version';
|
|
22
|
-
export { setDebugMode, setProductionMode } from '../../mol-util/debug';
|
|
22
|
+
export { setDebugMode, setProductionMode, setTimingMode } from '../../mol-util/debug';
|
|
23
23
|
declare const DefaultViewerOptions: {
|
|
24
24
|
customFormats: [string, DataFormatProvider<any, any, any>][];
|
|
25
25
|
extensions: ("cellpack" | "g3d" | "geo-export" | "model-export" | "mp4-export" | "pdbe-structure-quality-report" | "zenodo-import" | "dnatco-confal-pyramids" | "rcsb-assembly-symmetry" | "rcsb-validation-report" | "anvil-membrane-orientation" | "ma-quality-assessment")[];
|
package/lib/apps/viewer/app.js
CHANGED
|
@@ -35,7 +35,7 @@ import { Asset } from '../../mol-util/assets';
|
|
|
35
35
|
import '../../mol-util/polyfill';
|
|
36
36
|
import { ObjectKeys } from '../../mol-util/type-helpers';
|
|
37
37
|
export { PLUGIN_VERSION as version } from '../../mol-plugin/version';
|
|
38
|
-
export { setDebugMode, setProductionMode } from '../../mol-util/debug';
|
|
38
|
+
export { setDebugMode, setProductionMode, setTimingMode } from '../../mol-util/debug';
|
|
39
39
|
var CustomFormats = [
|
|
40
40
|
['g3d', G3dProvider]
|
|
41
41
|
];
|
|
@@ -46,7 +46,10 @@
|
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
var debugMode = getParam('debug-mode', '[^&]+').trim() === '1';
|
|
49
|
-
if (debugMode) molstar.setDebugMode(debugMode
|
|
49
|
+
if (debugMode) molstar.setDebugMode(debugMode);
|
|
50
|
+
|
|
51
|
+
var timingMode = getParam('timing-mode', '[^&]+').trim() === '1';
|
|
52
|
+
if (timingMode) molstar.setTimingMode(timingMode);
|
|
50
53
|
|
|
51
54
|
var hideControls = getParam('hide-controls', '[^&]+').trim() === '1';
|
|
52
55
|
var collapseLeftPanel = getParam('collapse-left-panel', '[^&]+').trim() === '1';
|
|
@@ -82,7 +82,7 @@ function getCategoryInstanceProvider(cat, fields) {
|
|
|
82
82
|
function classify(name, field) {
|
|
83
83
|
var type = getCifFieldType(field);
|
|
84
84
|
if (type['@type'] === 'str') {
|
|
85
|
-
return { name: name, type: 0 /* Str */, value: field.str, valueKind: field.valueKind };
|
|
85
|
+
return { name: name, type: 0 /* CifWriter.Field.Type.Str */, value: field.str, valueKind: field.valueKind };
|
|
86
86
|
}
|
|
87
87
|
else if (type['@type'] === 'float') {
|
|
88
88
|
var encoder = classifyFloatArray(field.toFloatArray({ array: Float64Array }));
|
|
@@ -19,7 +19,7 @@ import { StateObjectSelector } from '../../mol-state';
|
|
|
19
19
|
import { Color } from '../../mol-util/color';
|
|
20
20
|
import '../../mol-util/polyfill';
|
|
21
21
|
export { PLUGIN_VERSION as version } from '../../mol-plugin/version';
|
|
22
|
-
export { setDebugMode, setProductionMode } from '../../mol-util/debug';
|
|
22
|
+
export { setDebugMode, setProductionMode, setTimingMode } from '../../mol-util/debug';
|
|
23
23
|
declare const DefaultViewerOptions: {
|
|
24
24
|
customFormats: [string, DataFormatProvider<any, any, any>][];
|
|
25
25
|
extensions: ("cellpack" | "g3d" | "geo-export" | "model-export" | "mp4-export" | "pdbe-structure-quality-report" | "zenodo-import" | "dnatco-confal-pyramids" | "rcsb-assembly-symmetry" | "rcsb-validation-report" | "anvil-membrane-orientation" | "ma-quality-assessment")[];
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
7
7
|
*/
|
|
8
8
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
-
exports.ViewerAutoPreset = exports.Viewer = exports.setProductionMode = exports.setDebugMode = exports.version = void 0;
|
|
9
|
+
exports.ViewerAutoPreset = exports.Viewer = exports.setTimingMode = exports.setProductionMode = exports.setDebugMode = exports.version = void 0;
|
|
10
10
|
var tslib_1 = require("tslib");
|
|
11
11
|
var behavior_1 = require("../../extensions/anvil/behavior");
|
|
12
12
|
var cellpack_1 = require("../../extensions/cellpack");
|
|
@@ -42,6 +42,7 @@ Object.defineProperty(exports, "version", { enumerable: true, get: function () {
|
|
|
42
42
|
var debug_1 = require("../../mol-util/debug");
|
|
43
43
|
Object.defineProperty(exports, "setDebugMode", { enumerable: true, get: function () { return debug_1.setDebugMode; } });
|
|
44
44
|
Object.defineProperty(exports, "setProductionMode", { enumerable: true, get: function () { return debug_1.setProductionMode; } });
|
|
45
|
+
Object.defineProperty(exports, "setTimingMode", { enumerable: true, get: function () { return debug_1.setTimingMode; } });
|
|
45
46
|
var CustomFormats = [
|
|
46
47
|
['g3d', format_1.G3dProvider]
|
|
47
48
|
];
|
|
@@ -85,7 +85,7 @@ function getCategoryInstanceProvider(cat, fields) {
|
|
|
85
85
|
function classify(name, field) {
|
|
86
86
|
var type = (0, cif_1.getCifFieldType)(field);
|
|
87
87
|
if (type['@type'] === 'str') {
|
|
88
|
-
return { name: name, type: 0 /* Str */, value: field.str, valueKind: field.valueKind };
|
|
88
|
+
return { name: name, type: 0 /* CifWriter.Field.Type.Str */, value: field.str, valueKind: field.valueKind };
|
|
89
89
|
}
|
|
90
90
|
else if (type['@type'] === 'float') {
|
|
91
91
|
var encoder = (0, binary_cif_1.classifyFloatArray)(field.toFloatArray({ array: Float64Array }));
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* Copyright (c) 2020 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
|
+
* Copyright (c) 2020-2022 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
4
4
|
*
|
|
5
5
|
* @author David Sehnal <david.sehnal@gmail.com>
|
|
6
6
|
*/
|
|
@@ -21,6 +21,7 @@ var controls_1 = require("./controls");
|
|
|
21
21
|
var example_data_1 = require("./example-data");
|
|
22
22
|
require("./index.html");
|
|
23
23
|
require('mol-plugin-ui/skin/light.scss');
|
|
24
|
+
var debug_1 = require("../../mol-util/debug");
|
|
24
25
|
var AlphaOrbitalsExample = /** @class */ (function () {
|
|
25
26
|
function AlphaOrbitalsExample() {
|
|
26
27
|
this.params = new rxjs_1.BehaviorSubject({});
|
|
@@ -232,3 +233,5 @@ var AlphaOrbitalsExample = /** @class */ (function () {
|
|
|
232
233
|
}());
|
|
233
234
|
exports.AlphaOrbitalsExample = AlphaOrbitalsExample;
|
|
234
235
|
window.AlphaOrbitalsExample = new AlphaOrbitalsExample();
|
|
236
|
+
window.AlphaOrbitalsExample.setDebugMode = debug_1.setDebugMode;
|
|
237
|
+
window.AlphaOrbitalsExample.setTimingMode = debug_1.setTimingMode;
|
|
@@ -40,7 +40,7 @@ exports.CustomColorTheme = CustomColorTheme;
|
|
|
40
40
|
exports.CustomColorThemeProvider = {
|
|
41
41
|
name: 'basic-wrapper-custom-color-theme',
|
|
42
42
|
label: 'Custom Color Theme',
|
|
43
|
-
category: "Miscellaneous" /* Misc */,
|
|
43
|
+
category: "Miscellaneous" /* ColorTheme.Category.Misc */,
|
|
44
44
|
factory: CustomColorTheme,
|
|
45
45
|
getParams: function () { return ({}); },
|
|
46
46
|
defaultValues: {},
|
|
@@ -23,10 +23,10 @@ function createProteopediaCustomTheme(colors) {
|
|
|
23
23
|
}
|
|
24
24
|
function getAsymId(unit) {
|
|
25
25
|
switch (unit.kind) {
|
|
26
|
-
case 0 /* Atomic */:
|
|
26
|
+
case 0 /* Unit.Kind.Atomic */:
|
|
27
27
|
return structure_1.StructureProperties.chain.label_asym_id;
|
|
28
|
-
case 1 /* Spheres */:
|
|
29
|
-
case 2 /* Gaussians */:
|
|
28
|
+
case 1 /* Unit.Kind.Spheres */:
|
|
29
|
+
case 2 /* Unit.Kind.Gaussians */:
|
|
30
30
|
return structure_1.StructureProperties.coarse.asym_id;
|
|
31
31
|
}
|
|
32
32
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* Copyright (c) 2020 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
|
+
* Copyright (c) 2020-2022 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
4
4
|
*
|
|
5
5
|
* @author David Sehnal <david.sehnal@gmail.com>
|
|
6
6
|
*/
|
|
@@ -10,6 +10,7 @@ var tslib_1 = require("tslib");
|
|
|
10
10
|
var util_1 = require("../../mol-data/util");
|
|
11
11
|
var grid3d_1 = require("../../mol-gl/compute/grid3d");
|
|
12
12
|
var mol_task_1 = require("../../mol-task");
|
|
13
|
+
var debug_1 = require("../../mol-util/debug");
|
|
13
14
|
var data_model_1 = require("./data-model");
|
|
14
15
|
var compute_1 = require("./gpu/compute");
|
|
15
16
|
function createSphericalCollocationDensityGrid(params, orbitals, webgl) {
|
|
@@ -21,10 +22,13 @@ function createSphericalCollocationDensityGrid(params, orbitals, webgl) {
|
|
|
21
22
|
case 0:
|
|
22
23
|
cubeGrid = (0, data_model_1.initCubeGrid)(params);
|
|
23
24
|
if (!(0, grid3d_1.canComputeGrid3dOnGPU)(webgl)) return [3 /*break*/, 2];
|
|
25
|
+
if (debug_1.isTimingMode)
|
|
26
|
+
webgl.timer.mark('createSphericalCollocationDensityGrid');
|
|
24
27
|
return [4 /*yield*/, (0, compute_1.gpuComputeAlphaOrbitalsDensityGridValues)(ctx, webgl, cubeGrid, orbitals)];
|
|
25
28
|
case 1:
|
|
26
|
-
// console.time('gpu');
|
|
27
29
|
matrix = _a.sent();
|
|
30
|
+
if (debug_1.isTimingMode)
|
|
31
|
+
webgl.timer.markEnd('createSphericalCollocationDensityGrid');
|
|
28
32
|
return [3 /*break*/, 3];
|
|
29
33
|
case 2: throw new Error('Missing OES_texture_float WebGL extension.');
|
|
30
34
|
case 3:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/**
|
|
3
|
-
* Copyright (c) 2020 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
|
+
* Copyright (c) 2020-2022 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
4
4
|
*
|
|
5
5
|
* Inspired by https://github.com/dgasmith/gau2grid.
|
|
6
6
|
*
|
|
@@ -12,10 +12,10 @@ var tslib_1 = require("tslib");
|
|
|
12
12
|
var util_1 = require("../../mol-data/util");
|
|
13
13
|
var grid3d_1 = require("../../mol-gl/compute/grid3d");
|
|
14
14
|
var mol_task_1 = require("../../mol-task");
|
|
15
|
+
var debug_1 = require("../../mol-util/debug");
|
|
15
16
|
var collocation_1 = require("./collocation");
|
|
16
17
|
var data_model_1 = require("./data-model");
|
|
17
18
|
var compute_1 = require("./gpu/compute");
|
|
18
|
-
// setDebugMode(true);
|
|
19
19
|
function createSphericalCollocationGrid(params, orbital, webgl) {
|
|
20
20
|
var _this = this;
|
|
21
21
|
return mol_task_1.Task.create('Spherical Collocation Grid', function (ctx) { return tslib_1.__awaiter(_this, void 0, void 0, function () {
|
|
@@ -25,10 +25,13 @@ function createSphericalCollocationGrid(params, orbital, webgl) {
|
|
|
25
25
|
case 0:
|
|
26
26
|
cubeGrid = (0, data_model_1.initCubeGrid)(params);
|
|
27
27
|
if (!(0, grid3d_1.canComputeGrid3dOnGPU)(webgl)) return [3 /*break*/, 2];
|
|
28
|
+
if (debug_1.isTimingMode)
|
|
29
|
+
webgl.timer.mark('createSphericalCollocationGrid');
|
|
28
30
|
return [4 /*yield*/, (0, compute_1.gpuComputeAlphaOrbitalsGridValues)(ctx, webgl, cubeGrid, orbital)];
|
|
29
31
|
case 1:
|
|
30
|
-
// console.time('gpu');
|
|
31
32
|
matrix = _a.sent();
|
|
33
|
+
if (debug_1.isTimingMode)
|
|
34
|
+
webgl.timer.markEnd('createSphericalCollocationGrid');
|
|
32
35
|
return [3 /*break*/, 4];
|
|
33
36
|
case 2: return [4 /*yield*/, (0, collocation_1.sphericalCollocation)(cubeGrid, orbital, ctx)];
|
|
34
37
|
case 3:
|
|
@@ -97,7 +97,7 @@ function initialize(structure, props, accessibleSurfaceArea) {
|
|
|
97
97
|
eI = elements[j];
|
|
98
98
|
l.element = eI;
|
|
99
99
|
// consider only amino acids in chains
|
|
100
|
-
if ((0, util_1.getElementMoleculeType)(unit, eI) !== 5 /* Protein */ || !isPartOfEntity(l)) {
|
|
100
|
+
if ((0, util_1.getElementMoleculeType)(unit, eI) !== 5 /* MoleculeType.Protein */ || !isPartOfEntity(l)) {
|
|
101
101
|
continue;
|
|
102
102
|
}
|
|
103
103
|
// only CA is considered for downstream operations
|
|
@@ -74,7 +74,7 @@ exports.CellPackGenerateColorTheme = CellPackGenerateColorTheme;
|
|
|
74
74
|
exports.CellPackGenerateColorThemeProvider = {
|
|
75
75
|
name: 'cellpack-generate',
|
|
76
76
|
label: 'CellPack Generate',
|
|
77
|
-
category: "Chain Property" /* Chain */,
|
|
77
|
+
category: "Chain Property" /* ColorTheme.Category.Chain */,
|
|
78
78
|
factory: CellPackGenerateColorTheme,
|
|
79
79
|
getParams: getCellPackGenerateColorThemeParams,
|
|
80
80
|
defaultValues: param_definition_1.ParamDefinition.getDefaultValues(exports.CellPackGenerateColorThemeParams),
|
|
@@ -54,7 +54,7 @@ exports.CellPackProvidedColorTheme = CellPackProvidedColorTheme;
|
|
|
54
54
|
exports.CellPackProvidedColorThemeProvider = {
|
|
55
55
|
name: 'cellpack-provided',
|
|
56
56
|
label: 'CellPack Provided',
|
|
57
|
-
category: "Chain Property" /* Chain */,
|
|
57
|
+
category: "Chain Property" /* ColorTheme.Category.Chain */,
|
|
58
58
|
factory: CellPackProvidedColorTheme,
|
|
59
59
|
getParams: getCellPackProvidedColorThemeParams,
|
|
60
60
|
defaultValues: param_definition_1.ParamDefinition.getDefaultValues(exports.CellPackProvidedColorThemeParams),
|
|
@@ -338,7 +338,7 @@ var StructureFromAssemblies = objects_1.PluginStateTransform.BuiltIn({
|
|
|
338
338
|
invariantId = u.invariantId + offsetInvariantId;
|
|
339
339
|
if (u.invariantId > maxInvariantId)
|
|
340
340
|
maxInvariantId = u.invariantId;
|
|
341
|
-
builder.addUnit(u.kind, u.model, u.conformation.operator, u.elements, 0 /* None */, invariantId);
|
|
341
|
+
builder.addUnit(u.kind, u.model, u.conformation.operator, u.elements, 0 /* Unit.Trait.None */, invariantId);
|
|
342
342
|
}
|
|
343
343
|
offsetInvariantId += maxInvariantId + 1;
|
|
344
344
|
}
|
|
@@ -257,7 +257,7 @@ exports.ConfalPyramidsColorTheme = ConfalPyramidsColorTheme;
|
|
|
257
257
|
exports.ConfalPyramidsColorThemeProvider = {
|
|
258
258
|
name: 'confal-pyramids',
|
|
259
259
|
label: 'Confal Pyramids',
|
|
260
|
-
category: "Residue Property" /* Residue */,
|
|
260
|
+
category: "Residue Property" /* ColorTheme.Category.Residue */,
|
|
261
261
|
factory: ConfalPyramidsColorTheme,
|
|
262
262
|
getParams: getConfalPyramidsColorThemeParams,
|
|
263
263
|
defaultValues: param_definition_1.ParamDefinition.getDefaultValues(exports.ConfalPyramidsColorThemeParams),
|
|
@@ -96,7 +96,7 @@ function getTraj(ctx, data) {
|
|
|
96
96
|
for (i = 0; i < rowCount; ++i) {
|
|
97
97
|
e = normalized.entity_id[i];
|
|
98
98
|
eName.customName = e;
|
|
99
|
-
entityId = entityBuilder.getEntityId(e, 7 /* DNA */, e, eName);
|
|
99
|
+
entityId = entityBuilder.getEntityId(e, 7 /* MoleculeType.DNA */, e, eName);
|
|
100
100
|
entityIds[i] = entityId;
|
|
101
101
|
}
|
|
102
102
|
ihm_sphere_obj_site = db_1.Table.ofPartialColumns(schema_1.BasicSchema.ihm_sphere_obj_site, {
|
|
@@ -80,7 +80,7 @@ exports.PLDDTConfidenceColorTheme = PLDDTConfidenceColorTheme;
|
|
|
80
80
|
exports.PLDDTConfidenceColorThemeProvider = {
|
|
81
81
|
name: 'plddt-confidence',
|
|
82
82
|
label: 'pLDDT Confidence',
|
|
83
|
-
category: "Validation" /* Validation */,
|
|
83
|
+
category: "Validation" /* ColorTheme.Category.Validation */,
|
|
84
84
|
factory: PLDDTConfidenceColorTheme,
|
|
85
85
|
getParams: getPLDDTConfidenceColorThemeParams,
|
|
86
86
|
defaultValues: param_definition_1.ParamDefinition.getDefaultValues(getPLDDTConfidenceColorThemeParams({})),
|
|
@@ -66,7 +66,7 @@ exports.QmeanScoreColorTheme = QmeanScoreColorTheme;
|
|
|
66
66
|
exports.QmeanScoreColorThemeProvider = {
|
|
67
67
|
name: 'qmean-score',
|
|
68
68
|
label: 'QMEAN Score',
|
|
69
|
-
category: "Validation" /* Validation */,
|
|
69
|
+
category: "Validation" /* ColorTheme.Category.Validation */,
|
|
70
70
|
factory: QmeanScoreColorTheme,
|
|
71
71
|
getParams: getQmeanScoreColorThemeParams,
|
|
72
72
|
defaultValues: param_definition_1.ParamDefinition.getDefaultValues(getQmeanScoreColorThemeParams({})),
|
|
@@ -83,7 +83,7 @@ exports.StructureQualityReportColorTheme = StructureQualityReportColorTheme;
|
|
|
83
83
|
exports.StructureQualityReportColorThemeProvider = {
|
|
84
84
|
name: 'pdbe-structure-quality-report',
|
|
85
85
|
label: 'Structure Quality Report',
|
|
86
|
-
category: "Validation" /* Validation */,
|
|
86
|
+
category: "Validation" /* ColorTheme.Category.Validation */,
|
|
87
87
|
factory: StructureQualityReportColorTheme,
|
|
88
88
|
getParams: function (ctx) {
|
|
89
89
|
var issueTypes = prop_1.StructureQualityReport.getIssueTypes(ctx.structure);
|
|
@@ -15,10 +15,10 @@ var palette_1 = require("../../../mol-util/color/palette");
|
|
|
15
15
|
var DefaultColor = (0, color_1.Color)(0xCCCCCC);
|
|
16
16
|
function getAsymId(unit) {
|
|
17
17
|
switch (unit.kind) {
|
|
18
|
-
case 0 /* Atomic */:
|
|
18
|
+
case 0 /* Unit.Kind.Atomic */:
|
|
19
19
|
return structure_1.StructureProperties.chain.label_asym_id;
|
|
20
|
-
case 1 /* Spheres */:
|
|
21
|
-
case 2 /* Gaussians */:
|
|
20
|
+
case 1 /* Unit.Kind.Spheres */:
|
|
21
|
+
case 2 /* Unit.Kind.Gaussians */:
|
|
22
22
|
return structure_1.StructureProperties.coarse.asym_id;
|
|
23
23
|
}
|
|
24
24
|
}
|
|
@@ -88,7 +88,7 @@ exports.AssemblySymmetryClusterColorTheme = AssemblySymmetryClusterColorTheme;
|
|
|
88
88
|
exports.AssemblySymmetryClusterColorThemeProvider = {
|
|
89
89
|
name: prop_1.AssemblySymmetry.Tag.Cluster,
|
|
90
90
|
label: 'Assembly Symmetry Cluster',
|
|
91
|
-
category: "Symmetry" /* Symmetry */,
|
|
91
|
+
category: "Symmetry" /* ColorTheme.Category.Symmetry */,
|
|
92
92
|
factory: AssemblySymmetryClusterColorTheme,
|
|
93
93
|
getParams: getAssemblySymmetryClusterColorThemeParams,
|
|
94
94
|
defaultValues: param_definition_1.ParamDefinition.getDefaultValues(exports.AssemblySymmetryClusterColorThemeParams),
|
|
@@ -66,7 +66,7 @@ exports.DensityFitColorTheme = DensityFitColorTheme;
|
|
|
66
66
|
exports.DensityFitColorThemeProvider = {
|
|
67
67
|
name: prop_1.ValidationReport.Tag.DensityFit,
|
|
68
68
|
label: 'Density Fit',
|
|
69
|
-
category: "Validation" /* Validation */,
|
|
69
|
+
category: "Validation" /* ColorTheme.Category.Validation */,
|
|
70
70
|
factory: DensityFitColorTheme,
|
|
71
71
|
getParams: function () { return ({}); },
|
|
72
72
|
defaultValues: param_definition_1.ParamDefinition.getDefaultValues({}),
|
|
@@ -55,7 +55,7 @@ function GeometryQualityColorTheme(ctx, props) {
|
|
|
55
55
|
if (value === undefined)
|
|
56
56
|
return DefaultColor;
|
|
57
57
|
var count = set_1.SetUtils.differenceSize(value, ignore_1);
|
|
58
|
-
if (count > 0 && polymerType_1[rI] === 0 /* NA */) {
|
|
58
|
+
if (count > 0 && polymerType_1[rI] === 0 /* PolymerType.NA */) {
|
|
59
59
|
count = 0;
|
|
60
60
|
if (!ignore_1.has('clash') && clashes_1.getVertexEdgeCount(element) > 0)
|
|
61
61
|
count += 1;
|
|
@@ -97,7 +97,7 @@ exports.GeometryQualityColorTheme = GeometryQualityColorTheme;
|
|
|
97
97
|
exports.GeometryQualityColorThemeProvider = {
|
|
98
98
|
name: prop_1.ValidationReport.Tag.GeometryQuality,
|
|
99
99
|
label: 'Geometry Quality',
|
|
100
|
-
category: "Validation" /* Validation */,
|
|
100
|
+
category: "Validation" /* ColorTheme.Category.Validation */,
|
|
101
101
|
factory: GeometryQualityColorTheme,
|
|
102
102
|
getParams: getGeometricQualityColorThemeParams,
|
|
103
103
|
defaultValues: param_definition_1.ParamDefinition.getDefaultValues(getGeometricQualityColorThemeParams({})),
|
|
@@ -54,7 +54,7 @@ exports.RandomCoilIndexColorTheme = RandomCoilIndexColorTheme;
|
|
|
54
54
|
exports.RandomCoilIndexColorThemeProvider = {
|
|
55
55
|
name: prop_1.ValidationReport.Tag.RandomCoilIndex,
|
|
56
56
|
label: 'Random Coil Index',
|
|
57
|
-
category: "Validation" /* Validation */,
|
|
57
|
+
category: "Validation" /* ColorTheme.Category.Validation */,
|
|
58
58
|
factory: RandomCoilIndexColorTheme,
|
|
59
59
|
getParams: function () { return ({}); },
|
|
60
60
|
defaultValues: param_definition_1.ParamDefinition.getDefaultValues({}),
|
|
@@ -42,7 +42,7 @@ function createIntraUnitClashCylinderMesh(ctx, unit, structure, theme, props, me
|
|
|
42
42
|
pos(elements[a[edgeIndex]], posA);
|
|
43
43
|
pos(elements[b[edgeIndex]], posB);
|
|
44
44
|
},
|
|
45
|
-
style: function (edgeIndex) { return 6 /* Disk */; },
|
|
45
|
+
style: function (edgeIndex) { return 6 /* LinkStyle.Disk */; },
|
|
46
46
|
radius: function (edgeIndex) { return magnitude[edgeIndex] * sizeFactor; },
|
|
47
47
|
};
|
|
48
48
|
var _a = (0, link_1.createLinkCylinderMesh)(ctx, builderProps, props, mesh), m = _a.mesh, boundingSphere = _a.boundingSphere;
|
|
@@ -143,7 +143,7 @@ function createInterUnitClashCylinderMesh(ctx, structure, theme, props, mesh) {
|
|
|
143
143
|
uA.conformation.position(uA.elements[b.indexA], posA);
|
|
144
144
|
uB.conformation.position(uB.elements[b.indexB], posB);
|
|
145
145
|
},
|
|
146
|
-
style: function (edgeIndex) { return 6 /* Disk */; },
|
|
146
|
+
style: function (edgeIndex) { return 6 /* LinkStyle.Disk */; },
|
|
147
147
|
radius: function (edgeIndex) { return edges[edgeIndex].props.magnitude * sizeFactor; }
|
|
148
148
|
};
|
|
149
149
|
var _a = (0, link_1.createLinkCylinderMesh)(ctx, builderProps, props, mesh), m = _a.mesh, boundingSphere = _a.boundingSphere;
|
|
@@ -302,6 +302,8 @@ var Canvas3D;
|
|
|
302
302
|
stereoCamera.update();
|
|
303
303
|
cam = stereoCamera;
|
|
304
304
|
}
|
|
305
|
+
if (debug_1.isTimingMode)
|
|
306
|
+
webgl.timer.mark('Canvas3D.render');
|
|
305
307
|
var ctx = { renderer: renderer, camera: cam, scene: scene, helper: helper };
|
|
306
308
|
if (multi_sample_1.MultiSamplePass.isEnabled(p.multiSample)) {
|
|
307
309
|
var forceOn = !cameraChanged && markingUpdated && !controls.isAnimating;
|
|
@@ -310,6 +312,8 @@ var Canvas3D;
|
|
|
310
312
|
else {
|
|
311
313
|
passes.draw.render(ctx, p, true);
|
|
312
314
|
}
|
|
315
|
+
if (debug_1.isTimingMode)
|
|
316
|
+
webgl.timer.markEnd('Canvas3D.render');
|
|
313
317
|
// if only marking has updated, do not set the flag to dirty
|
|
314
318
|
pickHelper.dirty = pickHelper.dirty || shouldRender;
|
|
315
319
|
didRender = true;
|
|
@@ -21,14 +21,14 @@ var B = input_observer_1.ButtonsType;
|
|
|
21
21
|
var M = input_observer_1.ModifiersKeys;
|
|
22
22
|
var Trigger = binding_1.Binding.Trigger;
|
|
23
23
|
exports.DefaultTrackballBindings = {
|
|
24
|
-
dragRotate: (0, binding_1.Binding)([Trigger(1 /* Primary */, M.create())], 'Rotate', 'Drag using ${triggers}'),
|
|
25
|
-
dragRotateZ: (0, binding_1.Binding)([Trigger(1 /* Primary */, M.create({ shift: true }))], 'Rotate around z-axis', 'Drag using ${triggers}'),
|
|
26
|
-
dragPan: (0, binding_1.Binding)([Trigger(2 /* Secondary */, M.create()), Trigger(1 /* Primary */, M.create({ control: true }))], 'Pan', 'Drag using ${triggers}'),
|
|
24
|
+
dragRotate: (0, binding_1.Binding)([Trigger(1 /* B.Flag.Primary */, M.create())], 'Rotate', 'Drag using ${triggers}'),
|
|
25
|
+
dragRotateZ: (0, binding_1.Binding)([Trigger(1 /* B.Flag.Primary */, M.create({ shift: true }))], 'Rotate around z-axis', 'Drag using ${triggers}'),
|
|
26
|
+
dragPan: (0, binding_1.Binding)([Trigger(2 /* B.Flag.Secondary */, M.create()), Trigger(1 /* B.Flag.Primary */, M.create({ control: true }))], 'Pan', 'Drag using ${triggers}'),
|
|
27
27
|
dragZoom: binding_1.Binding.Empty,
|
|
28
|
-
dragFocus: (0, binding_1.Binding)([Trigger(8 /* Forth */, M.create())], 'Focus', 'Drag using ${triggers}'),
|
|
29
|
-
dragFocusZoom: (0, binding_1.Binding)([Trigger(4 /* Auxilary */, M.create())], 'Focus and zoom', 'Drag using ${triggers}'),
|
|
30
|
-
scrollZoom: (0, binding_1.Binding)([Trigger(4 /* Auxilary */, M.create())], 'Zoom', 'Scroll using ${triggers}'),
|
|
31
|
-
scrollFocus: (0, binding_1.Binding)([Trigger(4 /* Auxilary */, M.create({ shift: true }))], 'Clip', 'Scroll using ${triggers}'),
|
|
28
|
+
dragFocus: (0, binding_1.Binding)([Trigger(8 /* B.Flag.Forth */, M.create())], 'Focus', 'Drag using ${triggers}'),
|
|
29
|
+
dragFocusZoom: (0, binding_1.Binding)([Trigger(4 /* B.Flag.Auxilary */, M.create())], 'Focus and zoom', 'Drag using ${triggers}'),
|
|
30
|
+
scrollZoom: (0, binding_1.Binding)([Trigger(4 /* B.Flag.Auxilary */, M.create())], 'Zoom', 'Scroll using ${triggers}'),
|
|
31
|
+
scrollFocus: (0, binding_1.Binding)([Trigger(4 /* B.Flag.Auxilary */, M.create({ shift: true }))], 'Clip', 'Scroll using ${triggers}'),
|
|
32
32
|
scrollFocusZoom: binding_1.Binding.Empty,
|
|
33
33
|
};
|
|
34
34
|
exports.TrackballControlsParams = {
|
|
@@ -89,7 +89,7 @@ var CameraHelper = /** @class */ (function () {
|
|
|
89
89
|
});
|
|
90
90
|
CameraHelper.prototype.getLoci = function (pickingId) {
|
|
91
91
|
var objectId = pickingId.objectId, groupId = pickingId.groupId, instanceId = pickingId.instanceId;
|
|
92
|
-
if (!this.renderObject || objectId !== this.renderObject.id || groupId === 0 /* None */)
|
|
92
|
+
if (!this.renderObject || objectId !== this.renderObject.id || groupId === 0 /* CameraHelperAxis.None */)
|
|
93
93
|
return loci_1.EmptyLoci;
|
|
94
94
|
return CameraAxesLoci(this, groupId, instanceId);
|
|
95
95
|
};
|
|
@@ -117,12 +117,12 @@ var CameraHelper = /** @class */ (function () {
|
|
|
117
117
|
exports.CameraHelper = CameraHelper;
|
|
118
118
|
function getAxisLabel(axis) {
|
|
119
119
|
switch (axis) {
|
|
120
|
-
case 1 /* X */: return 'X Axis';
|
|
121
|
-
case 2 /* Y */: return 'Y Axis';
|
|
122
|
-
case 3 /* Z */: return 'Z Axis';
|
|
123
|
-
case 4 /* XY */: return 'XY Plane';
|
|
124
|
-
case 5 /* XZ */: return 'XZ Plane';
|
|
125
|
-
case 6 /* YZ */: return 'YZ Plane';
|
|
120
|
+
case 1 /* CameraHelperAxis.X */: return 'X Axis';
|
|
121
|
+
case 2 /* CameraHelperAxis.Y */: return 'Y Axis';
|
|
122
|
+
case 3 /* CameraHelperAxis.Z */: return 'Z Axis';
|
|
123
|
+
case 4 /* CameraHelperAxis.XY */: return 'XY Plane';
|
|
124
|
+
case 5 /* CameraHelperAxis.XZ */: return 'XZ Plane';
|
|
125
|
+
case 6 /* CameraHelperAxis.YZ */: return 'YZ Plane';
|
|
126
126
|
default: return 'Axes';
|
|
127
127
|
}
|
|
128
128
|
}
|
|
@@ -164,33 +164,33 @@ function createAxesMesh(scale, mesh) {
|
|
|
164
164
|
var y = linear_algebra_1.Vec3.scale((0, linear_algebra_1.Vec3)(), linear_algebra_1.Vec3.unitY, scale);
|
|
165
165
|
var z = linear_algebra_1.Vec3.scale((0, linear_algebra_1.Vec3)(), linear_algebra_1.Vec3.unitZ, scale);
|
|
166
166
|
var cylinderProps = { radiusTop: radius, radiusBottom: radius, radialSegments: 32 };
|
|
167
|
-
state.currentGroup = 0 /* None */;
|
|
167
|
+
state.currentGroup = 0 /* CameraHelperAxis.None */;
|
|
168
168
|
(0, sphere_1.addSphere)(state, linear_algebra_1.Vec3.origin, radius, 2);
|
|
169
|
-
state.currentGroup = 1 /* X */;
|
|
169
|
+
state.currentGroup = 1 /* CameraHelperAxis.X */;
|
|
170
170
|
(0, sphere_1.addSphere)(state, x, radius, 2);
|
|
171
171
|
(0, cylinder_1.addCylinder)(state, linear_algebra_1.Vec3.origin, x, 1, cylinderProps);
|
|
172
|
-
state.currentGroup = 2 /* Y */;
|
|
172
|
+
state.currentGroup = 2 /* CameraHelperAxis.Y */;
|
|
173
173
|
(0, sphere_1.addSphere)(state, y, radius, 2);
|
|
174
174
|
(0, cylinder_1.addCylinder)(state, linear_algebra_1.Vec3.origin, y, 1, cylinderProps);
|
|
175
|
-
state.currentGroup = 3 /* Z */;
|
|
175
|
+
state.currentGroup = 3 /* CameraHelperAxis.Z */;
|
|
176
176
|
(0, sphere_1.addSphere)(state, z, radius, 2);
|
|
177
177
|
(0, cylinder_1.addCylinder)(state, linear_algebra_1.Vec3.origin, z, 1, cylinderProps);
|
|
178
178
|
linear_algebra_1.Vec3.scale(x, x, 0.5);
|
|
179
179
|
linear_algebra_1.Vec3.scale(y, y, 0.5);
|
|
180
180
|
linear_algebra_1.Vec3.scale(z, z, 0.5);
|
|
181
|
-
state.currentGroup = 4 /* XY */;
|
|
181
|
+
state.currentGroup = 4 /* CameraHelperAxis.XY */;
|
|
182
182
|
mesh_builder_1.MeshBuilder.addTriangle(state, linear_algebra_1.Vec3.origin, x, y);
|
|
183
183
|
mesh_builder_1.MeshBuilder.addTriangle(state, linear_algebra_1.Vec3.origin, y, x);
|
|
184
184
|
var xy = linear_algebra_1.Vec3.add((0, linear_algebra_1.Vec3)(), x, y);
|
|
185
185
|
mesh_builder_1.MeshBuilder.addTriangle(state, xy, x, y);
|
|
186
186
|
mesh_builder_1.MeshBuilder.addTriangle(state, xy, y, x);
|
|
187
|
-
state.currentGroup = 5 /* XZ */;
|
|
187
|
+
state.currentGroup = 5 /* CameraHelperAxis.XZ */;
|
|
188
188
|
mesh_builder_1.MeshBuilder.addTriangle(state, linear_algebra_1.Vec3.origin, x, z);
|
|
189
189
|
mesh_builder_1.MeshBuilder.addTriangle(state, linear_algebra_1.Vec3.origin, z, x);
|
|
190
190
|
var xz = linear_algebra_1.Vec3.add((0, linear_algebra_1.Vec3)(), x, z);
|
|
191
191
|
mesh_builder_1.MeshBuilder.addTriangle(state, xz, x, z);
|
|
192
192
|
mesh_builder_1.MeshBuilder.addTriangle(state, xz, z, x);
|
|
193
|
-
state.currentGroup = 6 /* YZ */;
|
|
193
|
+
state.currentGroup = 6 /* CameraHelperAxis.YZ */;
|
|
194
194
|
mesh_builder_1.MeshBuilder.addTriangle(state, linear_algebra_1.Vec3.origin, y, z);
|
|
195
195
|
mesh_builder_1.MeshBuilder.addTriangle(state, linear_algebra_1.Vec3.origin, z, y);
|
|
196
196
|
var yz = linear_algebra_1.Vec3.add((0, linear_algebra_1.Vec3)(), y, z);
|
|
@@ -88,7 +88,7 @@ var Canvas3dInteractionHelper = /** @class */ (function () {
|
|
|
88
88
|
};
|
|
89
89
|
Canvas3dInteractionHelper.prototype.identify = function (e, t) {
|
|
90
90
|
var xyChanged = this.startX !== this.endX || this.startY !== this.endY;
|
|
91
|
-
if (e === 2 /* Drag */) {
|
|
91
|
+
if (e === 2 /* InputEvent.Drag */) {
|
|
92
92
|
if (xyChanged && !this.outsideViewport(this.startX, this.startY)) {
|
|
93
93
|
this.events.drag.next({ current: this.prevLoci, buttons: this.buttons, button: this.button, modifiers: this.modifiers, pageStart: linear_algebra_1.Vec2.create(this.startX, this.startY), pageEnd: linear_algebra_1.Vec2.create(this.endX, this.endY) });
|
|
94
94
|
this.startX = this.endX;
|
|
@@ -103,7 +103,7 @@ var Canvas3dInteractionHelper = /** @class */ (function () {
|
|
|
103
103
|
this.startX = this.endX;
|
|
104
104
|
this.startY = this.endY;
|
|
105
105
|
}
|
|
106
|
-
if (e === 1 /* Click */) {
|
|
106
|
+
if (e === 1 /* InputEvent.Click */) {
|
|
107
107
|
var loci_1 = this.getLoci(this.id, this.position);
|
|
108
108
|
this.events.click.next({ current: loci_1, buttons: this.buttons, button: this.button, modifiers: this.modifiers, page: linear_algebra_1.Vec2.create(this.endX, this.endY), position: this.position });
|
|
109
109
|
this.prevLoci = loci_1;
|
|
@@ -119,7 +119,7 @@ var Canvas3dInteractionHelper = /** @class */ (function () {
|
|
|
119
119
|
if (this.inside && t - this.prevT > 1000 / this.props.maxFps) {
|
|
120
120
|
this.prevT = t;
|
|
121
121
|
this.currentIdentifyT = t;
|
|
122
|
-
this.identify(this.isInteracting ? 2 /* Drag */ : 0 /* Move */, t);
|
|
122
|
+
this.identify(this.isInteracting ? 2 /* InputEvent.Drag */ : 0 /* InputEvent.Move */, t);
|
|
123
123
|
}
|
|
124
124
|
};
|
|
125
125
|
Canvas3dInteractionHelper.prototype.leave = function () {
|
|
@@ -143,7 +143,7 @@ var Canvas3dInteractionHelper = /** @class */ (function () {
|
|
|
143
143
|
this.buttons = buttons;
|
|
144
144
|
this.button = button;
|
|
145
145
|
this.modifiers = modifiers;
|
|
146
|
-
this.identify(1 /* Click */, 0);
|
|
146
|
+
this.identify(1 /* InputEvent.Click */, 0);
|
|
147
147
|
};
|
|
148
148
|
Canvas3dInteractionHelper.prototype.drag = function (x, y, buttons, button, modifiers) {
|
|
149
149
|
this.endX = x;
|
|
@@ -151,7 +151,7 @@ var Canvas3dInteractionHelper = /** @class */ (function () {
|
|
|
151
151
|
this.buttons = buttons;
|
|
152
152
|
this.button = button;
|
|
153
153
|
this.modifiers = modifiers;
|
|
154
|
-
this.identify(2 /* Drag */, 0);
|
|
154
|
+
this.identify(2 /* InputEvent.Drag */, 0);
|
|
155
155
|
};
|
|
156
156
|
Canvas3dInteractionHelper.prototype.modify = function (modifiers) {
|
|
157
157
|
if (input_observer_1.ModifiersKeys.areEqual(modifiers, this.modifiers))
|