molstar 3.0.0-dev.2 → 3.0.0-dev.6
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/LICENSE +20 -20
- package/README.md +187 -187
- package/build/viewer/embedded.html +43 -43
- package/build/viewer/index.html +102 -94
- package/build/viewer/molstar.css +1 -1
- package/build/viewer/molstar.js +1 -1
- package/lib/apps/docking-viewer/index.d.ts +2 -1
- package/lib/apps/docking-viewer/index.html +36 -36
- package/lib/apps/docking-viewer/index.js +87 -74
- package/lib/apps/docking-viewer/viewport.js +2 -1
- package/lib/apps/viewer/embedded.html +43 -43
- package/lib/apps/viewer/index.d.ts +36 -215
- package/lib/apps/viewer/index.html +102 -94
- package/lib/apps/viewer/index.js +139 -52
- package/lib/cli/cifschema/index.d.ts +1 -1
- package/lib/cli/cifschema/index.js +15 -35
- package/lib/commonjs/apps/docking-viewer/index.d.ts +2 -1
- package/lib/commonjs/apps/docking-viewer/index.js +86 -73
- package/lib/commonjs/apps/docking-viewer/viewport.js +2 -1
- package/lib/commonjs/apps/viewer/index.d.ts +36 -215
- package/lib/commonjs/apps/viewer/index.js +139 -52
- package/lib/commonjs/cli/cifschema/index.d.ts +1 -1
- package/lib/commonjs/cli/cifschema/index.js +15 -35
- package/lib/commonjs/examples/alpha-orbitals/index.js +2 -3
- package/lib/commonjs/examples/basic-wrapper/index.js +23 -11
- package/lib/commonjs/examples/lighting/index.d.ts +1 -1
- package/lib/commonjs/examples/lighting/index.js +58 -41
- package/lib/commonjs/examples/proteopedia-wrapper/index.js +26 -14
- package/lib/commonjs/extensions/alpha-orbitals/transforms.d.ts +0 -1
- package/lib/commonjs/extensions/alpha-orbitals/transforms.js +1 -14
- package/lib/commonjs/extensions/anvil/behavior.d.ts +3 -0
- package/lib/commonjs/extensions/anvil/representation.d.ts +13 -0
- package/lib/commonjs/extensions/cellpack/representation.d.ts +3 -0
- package/lib/commonjs/extensions/dnatco/confal-pyramids/representation.d.ts +9 -0
- package/lib/commonjs/extensions/geo-export/obj-exporter.js +1 -1
- package/lib/commonjs/extensions/geo-export/usdz-exporter.js +1 -1
- package/lib/commonjs/extensions/model-archive/quality-assessment/behavior.d.ts +68 -0
- package/lib/commonjs/extensions/model-archive/quality-assessment/behavior.js +236 -0
- package/lib/commonjs/extensions/model-archive/quality-assessment/color/plddt.d.ts +14 -0
- package/lib/commonjs/extensions/model-archive/quality-assessment/color/plddt.js +125 -0
- package/lib/commonjs/extensions/model-archive/quality-assessment/color/qmean.d.ts +12 -0
- package/lib/commonjs/extensions/model-archive/quality-assessment/color/qmean.js +111 -0
- package/lib/commonjs/extensions/model-archive/quality-assessment/prop.d.ts +28 -0
- package/lib/commonjs/extensions/model-archive/quality-assessment/prop.js +130 -0
- package/lib/commonjs/extensions/mp4-export/controls.d.ts +1 -0
- package/lib/commonjs/extensions/mp4-export/controls.js +9 -7
- package/lib/commonjs/extensions/pdbe/structure-quality-report/prop.js +1 -1
- package/lib/commonjs/extensions/rcsb/assembly-symmetry/behavior.d.ts +3 -0
- package/lib/commonjs/extensions/rcsb/assembly-symmetry/prop.js +1 -1
- package/lib/commonjs/extensions/rcsb/assembly-symmetry/representation.d.ts +3 -0
- package/lib/commonjs/extensions/rcsb/validation-report/prop.js +1 -1
- package/lib/commonjs/extensions/rcsb/validation-report/representation.d.ts +15 -0
- package/lib/commonjs/mol-canvas3d/canvas3d.d.ts +6 -0
- package/lib/commonjs/mol-canvas3d/canvas3d.js +10 -3
- package/lib/commonjs/mol-canvas3d/helper/camera-helper.d.ts +3 -0
- package/lib/commonjs/mol-canvas3d/helper/handle-helper.d.ts +3 -0
- package/lib/commonjs/mol-canvas3d/helper/helper.d.ts +4 -0
- package/lib/commonjs/mol-canvas3d/passes/image.d.ts +3 -0
- package/lib/commonjs/mol-canvas3d/passes/multi-sample.d.ts +2 -1
- package/lib/commonjs/mol-canvas3d/passes/multi-sample.js +4 -2
- package/lib/commonjs/mol-canvas3d/passes/postprocessing.d.ts +1 -0
- package/lib/commonjs/mol-canvas3d/passes/postprocessing.js +4 -2
- package/lib/commonjs/mol-geo/geometry/base.d.ts +2 -0
- package/lib/commonjs/mol-geo/geometry/base.js +2 -0
- package/lib/commonjs/mol-geo/geometry/cylinders/cylinders.d.ts +4 -1
- package/lib/commonjs/mol-geo/geometry/cylinders/cylinders.js +4 -2
- package/lib/commonjs/mol-geo/geometry/direct-volume/direct-volume.d.ts +1 -0
- package/lib/commonjs/mol-geo/geometry/image/image.d.ts +1 -0
- package/lib/commonjs/mol-geo/geometry/lines/lines.d.ts +2 -0
- package/lib/commonjs/mol-geo/geometry/mesh/color-smoothing.js +1 -1
- package/lib/commonjs/mol-geo/geometry/mesh/mesh.d.ts +3 -0
- package/lib/commonjs/mol-geo/geometry/mesh/mesh.js +4 -2
- package/lib/commonjs/mol-geo/geometry/points/points.d.ts +1 -0
- package/lib/commonjs/mol-geo/geometry/spheres/spheres.d.ts +3 -0
- package/lib/commonjs/mol-geo/geometry/spheres/spheres.js +4 -2
- package/lib/commonjs/mol-geo/geometry/substance-data.js +3 -3
- package/lib/commonjs/mol-geo/geometry/text/text.d.ts +1 -0
- package/lib/commonjs/mol-geo/geometry/texture-mesh/color-smoothing.js +3 -3
- package/lib/commonjs/mol-geo/geometry/texture-mesh/texture-mesh.d.ts +3 -0
- package/lib/commonjs/mol-geo/geometry/texture-mesh/texture-mesh.js +4 -2
- package/lib/commonjs/mol-gl/renderable/cylinders.d.ts +31 -28
- package/lib/commonjs/mol-gl/renderable/cylinders.js +2 -2
- package/lib/commonjs/mol-gl/renderable/direct-volume.d.ts +1 -0
- package/lib/commonjs/mol-gl/renderable/image.d.ts +1 -0
- package/lib/commonjs/mol-gl/renderable/lines.d.ts +1 -0
- package/lib/commonjs/mol-gl/renderable/mesh.d.ts +28 -25
- package/lib/commonjs/mol-gl/renderable/mesh.js +2 -2
- package/lib/commonjs/mol-gl/renderable/points.d.ts +1 -0
- package/lib/commonjs/mol-gl/renderable/schema.d.ts +1 -0
- package/lib/commonjs/mol-gl/renderable/schema.js +3 -3
- package/lib/commonjs/mol-gl/renderable/spheres.d.ts +31 -28
- package/lib/commonjs/mol-gl/renderable/spheres.js +2 -2
- package/lib/commonjs/mol-gl/renderable/text.d.ts +1 -0
- package/lib/commonjs/mol-gl/renderable/texture-mesh.d.ts +3 -0
- package/lib/commonjs/mol-gl/renderable/texture-mesh.js +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/apply-light-color.glsl.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/apply-light-color.glsl.js +1 -1
- 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/chunks/common-frag-params.glsl.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/common-frag-params.glsl.js +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/common.glsl.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/common.glsl.js +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/light-frag-params.glsl.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/chunks/light-frag-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/mesh.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/mesh.frag.js +1 -1
- package/lib/commonjs/mol-gl/shader/postprocessing.frag.d.ts +1 -1
- package/lib/commonjs/mol-gl/shader/postprocessing.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-io/reader/cif/schema/mmcif.d.ts +326 -1
- package/lib/commonjs/mol-io/reader/cif/schema/mmcif.js +326 -1
- package/lib/commonjs/mol-math/geometry/symmetry-operator.js +3 -2
- package/lib/commonjs/mol-model/structure/model/model.d.ts +1 -0
- package/lib/commonjs/mol-model/structure/model/model.js +15 -5
- package/lib/commonjs/mol-model/structure/model/properties/atomic/hierarchy.d.ts +6 -1
- package/lib/commonjs/mol-model/structure/model/properties/atomic/hierarchy.js +1 -1
- package/lib/commonjs/mol-model/structure/model/properties/utils/atomic-derived.d.ts +1 -1
- package/lib/commonjs/mol-model/structure/model/properties/utils/atomic-derived.js +4 -1
- package/lib/commonjs/mol-model/structure/model/properties/utils/atomic-index.d.ts +1 -1
- package/lib/commonjs/mol-model/structure/model/properties/utils/atomic-index.js +12 -1
- package/lib/commonjs/mol-model/structure/model/types.js +9 -0
- package/lib/commonjs/mol-model/structure/structure/unit/rings.js +2 -0
- package/lib/commonjs/mol-model-formats/shape/ply.d.ts +6 -0
- package/lib/commonjs/mol-model-props/computed/representations/interactions-inter-unit-cylinder.d.ts +3 -0
- package/lib/commonjs/mol-model-props/computed/representations/interactions-intra-unit-cylinder.d.ts +3 -0
- package/lib/commonjs/mol-model-props/computed/representations/interactions.d.ts +9 -0
- package/lib/commonjs/mol-model-props/integrative/cross-link-restraint/representation.d.ts +12 -0
- package/lib/commonjs/mol-plugin/behavior/dynamic/selection/structure-focus-representation.d.ts +1 -0
- package/lib/commonjs/mol-plugin/behavior/dynamic/volume-streaming/model.d.ts +3 -2
- package/lib/commonjs/mol-plugin/commands.d.ts +3 -0
- package/lib/commonjs/mol-plugin/config.d.ts +2 -0
- package/lib/commonjs/mol-plugin/config.js +10 -3
- package/lib/commonjs/mol-plugin/util/viewport-screenshot.d.ts +9 -0
- package/lib/commonjs/mol-plugin-state/actions/structure.d.ts +7 -1
- package/lib/commonjs/mol-plugin-state/actions/structure.js +150 -72
- package/lib/commonjs/mol-plugin-state/builder/structure/hierarchy-preset.d.ts +5 -355
- package/lib/commonjs/mol-plugin-state/builder/structure/hierarchy-preset.js +13 -8
- package/lib/commonjs/mol-plugin-state/builder/structure/hierarchy.d.ts +1 -71
- package/lib/commonjs/mol-plugin-state/helpers/structure-selection-query.js +33 -19
- package/lib/commonjs/mol-plugin-state/manager/structure/component.d.ts +2 -0
- package/lib/commonjs/mol-plugin-state/manager/structure/component.js +1 -1
- package/lib/commonjs/mol-plugin-state/transforms/representation.d.ts +22 -0
- package/lib/commonjs/mol-plugin-ui/controls/parameters.d.ts +3 -2
- package/lib/commonjs/mol-plugin-ui/controls/parameters.js +11 -6
- package/lib/commonjs/mol-plugin-ui/hooks/use-behavior.d.ts +1 -1
- package/lib/commonjs/mol-plugin-ui/hooks/use-behavior.js +8 -17
- package/lib/commonjs/mol-plugin-ui/index.d.ts +4 -4
- package/lib/commonjs/mol-plugin-ui/index.js +13 -16
- package/lib/commonjs/mol-plugin-ui/plugin.d.ts +1 -1
- package/lib/commonjs/mol-plugin-ui/plugin.js +76 -10
- package/lib/commonjs/mol-repr/shape/loci/angle.d.ts +3 -0
- package/lib/commonjs/mol-repr/shape/loci/common.d.ts +1 -0
- package/lib/commonjs/mol-repr/shape/loci/dihedral.d.ts +3 -0
- package/lib/commonjs/mol-repr/shape/loci/distance.d.ts +1 -0
- package/lib/commonjs/mol-repr/shape/loci/label.d.ts +1 -0
- package/lib/commonjs/mol-repr/shape/loci/orientation.d.ts +3 -0
- package/lib/commonjs/mol-repr/shape/loci/plane.d.ts +3 -0
- package/lib/commonjs/mol-repr/shape/model/unitcell.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/complex-visual.d.ts +12 -0
- package/lib/commonjs/mol-repr/structure/params.d.ts +16 -0
- package/lib/commonjs/mol-repr/structure/registry.d.ts +35 -1
- package/lib/commonjs/mol-repr/structure/representation/backbone.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/backbone.js +2 -1
- package/lib/commonjs/mol-repr/structure/representation/ball-and-stick.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/ball-and-stick.js +2 -1
- package/lib/commonjs/mol-repr/structure/representation/carbohydrate.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/carbohydrate.js +2 -1
- package/lib/commonjs/mol-repr/structure/representation/cartoon.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/cartoon.js +2 -1
- package/lib/commonjs/mol-repr/structure/representation/ellipsoid.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/ellipsoid.js +2 -1
- package/lib/commonjs/mol-repr/structure/representation/gaussian-surface.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/gaussian-surface.js +2 -1
- package/lib/commonjs/mol-repr/structure/representation/gaussian-volume.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/representation/label.d.ts +6 -3
- package/lib/commonjs/mol-repr/structure/representation/line.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/representation/molecular-surface.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/molecular-surface.js +2 -1
- package/lib/commonjs/mol-repr/structure/representation/orientation.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/orientation.js +2 -1
- package/lib/commonjs/mol-repr/structure/representation/point.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/representation/putty.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/putty.js +2 -1
- package/lib/commonjs/mol-repr/structure/representation/spacefill.d.ts +9 -0
- package/lib/commonjs/mol-repr/structure/representation/spacefill.js +2 -1
- package/lib/commonjs/mol-repr/structure/units-visual.d.ts +16 -0
- package/lib/commonjs/mol-repr/structure/visual/bond-inter-unit-cylinder.d.ts +6 -0
- package/lib/commonjs/mol-repr/structure/visual/bond-inter-unit-line.d.ts +1 -0
- package/lib/commonjs/mol-repr/structure/visual/bond-intra-unit-cylinder.d.ts +6 -0
- package/lib/commonjs/mol-repr/structure/visual/bond-intra-unit-cylinder.js +2 -2
- package/lib/commonjs/mol-repr/structure/visual/bond-intra-unit-line.d.ts +1 -0
- package/lib/commonjs/mol-repr/structure/visual/bond-intra-unit-line.js +2 -2
- package/lib/commonjs/mol-repr/structure/visual/carbohydrate-link-cylinder.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/carbohydrate-symbol-mesh.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/carbohydrate-terminal-link-cylinder.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/element-cross.d.ts +1 -0
- package/lib/commonjs/mol-repr/structure/visual/element-point.d.ts +1 -0
- package/lib/commonjs/mol-repr/structure/visual/element-sphere.d.ts +6 -0
- package/lib/commonjs/mol-repr/structure/visual/ellipsoid-mesh.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/gaussian-density-volume.d.ts +2 -0
- package/lib/commonjs/mol-repr/structure/visual/gaussian-surface-mesh.d.ts +12 -0
- package/lib/commonjs/mol-repr/structure/visual/gaussian-surface-wireframe.d.ts +1 -0
- package/lib/commonjs/mol-repr/structure/visual/label-text.d.ts +3 -2
- package/lib/commonjs/mol-repr/structure/visual/label-text.js +2 -2
- package/lib/commonjs/mol-repr/structure/visual/molecular-surface-mesh.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/molecular-surface-wireframe.d.ts +1 -0
- package/lib/commonjs/mol-repr/structure/visual/nucleotide-block-mesh.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/nucleotide-ring-mesh.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/orientation-ellipsoid-mesh.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/polymer-backbone-cylinder.d.ts +6 -0
- package/lib/commonjs/mol-repr/structure/visual/polymer-backbone-sphere.d.ts +6 -0
- package/lib/commonjs/mol-repr/structure/visual/polymer-direction-wedge.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/polymer-gap-cylinder.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/polymer-trace-mesh.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/polymer-trace-mesh.js +1 -1
- package/lib/commonjs/mol-repr/structure/visual/polymer-tube-mesh.d.ts +3 -0
- package/lib/commonjs/mol-repr/structure/visual/util/bond.js +1 -1
- package/lib/commonjs/mol-repr/volume/direct-volume.d.ts +3 -0
- package/lib/commonjs/mol-repr/volume/isosurface.d.ts +16 -0
- package/lib/commonjs/mol-repr/volume/isosurface.js +2 -1
- package/lib/commonjs/mol-repr/volume/registry.d.ts +5 -0
- package/lib/commonjs/mol-repr/volume/representation.d.ts +1 -0
- package/lib/commonjs/mol-repr/volume/slice.d.ts +3 -0
- package/lib/commonjs/mol-script/language/builder.d.ts +0 -1
- package/lib/commonjs/mol-theme/color/illustrative.d.ts +2 -0
- package/lib/commonjs/mol-theme/color/illustrative.js +2 -2
- package/lib/commonjs/mol-theme/color.d.ts +1 -0
- package/lib/commonjs/mol-util/material.d.ts +5 -1
- package/lib/commonjs/mol-util/material.js +9 -7
- package/lib/examples/alpha-orbitals/index.html +61 -60
- package/lib/examples/alpha-orbitals/index.js +3 -4
- package/lib/examples/basic-wrapper/index.html +137 -136
- package/lib/examples/basic-wrapper/index.js +24 -12
- package/lib/examples/lighting/index.d.ts +1 -1
- package/lib/examples/lighting/index.html +88 -86
- package/lib/examples/lighting/index.js +59 -42
- package/lib/examples/proteopedia-wrapper/index.html +236 -235
- package/lib/examples/proteopedia-wrapper/index.js +27 -15
- package/lib/extensions/alpha-orbitals/transforms.d.ts +0 -1
- package/lib/extensions/alpha-orbitals/transforms.js +1 -14
- package/lib/extensions/anvil/behavior.d.ts +3 -0
- package/lib/extensions/anvil/representation.d.ts +13 -0
- package/lib/extensions/cellpack/representation.d.ts +3 -0
- package/lib/extensions/dnatco/confal-pyramids/representation.d.ts +9 -0
- package/lib/extensions/geo-export/obj-exporter.js +1 -1
- package/lib/extensions/geo-export/usdz-exporter.js +1 -1
- package/lib/extensions/model-archive/quality-assessment/behavior.d.ts +68 -0
- package/lib/extensions/model-archive/quality-assessment/behavior.js +233 -0
- package/lib/extensions/model-archive/quality-assessment/color/plddt.d.ts +14 -0
- package/lib/extensions/model-archive/quality-assessment/color/plddt.js +120 -0
- package/lib/extensions/model-archive/quality-assessment/color/qmean.d.ts +12 -0
- package/lib/extensions/model-archive/quality-assessment/color/qmean.js +106 -0
- package/lib/extensions/model-archive/quality-assessment/prop.d.ts +28 -0
- package/lib/extensions/model-archive/quality-assessment/prop.js +127 -0
- package/lib/extensions/mp4-export/controls.d.ts +1 -0
- package/lib/extensions/mp4-export/controls.js +9 -7
- package/lib/extensions/pdbe/structure-quality-report/prop.js +1 -1
- package/lib/extensions/rcsb/assembly-symmetry/behavior.d.ts +3 -0
- package/lib/extensions/rcsb/assembly-symmetry/prop.js +1 -1
- package/lib/extensions/rcsb/assembly-symmetry/representation.d.ts +3 -0
- package/lib/extensions/rcsb/validation-report/prop.js +1 -1
- package/lib/extensions/rcsb/validation-report/representation.d.ts +15 -0
- package/lib/mol-canvas3d/canvas3d.d.ts +6 -0
- package/lib/mol-canvas3d/canvas3d.js +10 -3
- package/lib/mol-canvas3d/helper/camera-helper.d.ts +3 -0
- package/lib/mol-canvas3d/helper/handle-helper.d.ts +3 -0
- package/lib/mol-canvas3d/helper/helper.d.ts +4 -0
- package/lib/mol-canvas3d/passes/image.d.ts +3 -0
- package/lib/mol-canvas3d/passes/multi-sample.d.ts +2 -1
- package/lib/mol-canvas3d/passes/multi-sample.js +4 -2
- package/lib/mol-canvas3d/passes/postprocessing.d.ts +1 -0
- package/lib/mol-canvas3d/passes/postprocessing.js +4 -2
- package/lib/mol-geo/geometry/base.d.ts +2 -0
- package/lib/mol-geo/geometry/base.js +2 -0
- package/lib/mol-geo/geometry/cylinders/cylinders.d.ts +4 -1
- package/lib/mol-geo/geometry/cylinders/cylinders.js +4 -2
- package/lib/mol-geo/geometry/direct-volume/direct-volume.d.ts +1 -0
- package/lib/mol-geo/geometry/image/image.d.ts +1 -0
- package/lib/mol-geo/geometry/lines/lines.d.ts +2 -0
- package/lib/mol-geo/geometry/mesh/color-smoothing.js +1 -1
- package/lib/mol-geo/geometry/mesh/mesh.d.ts +3 -0
- package/lib/mol-geo/geometry/mesh/mesh.js +4 -2
- package/lib/mol-geo/geometry/points/points.d.ts +1 -0
- package/lib/mol-geo/geometry/spheres/spheres.d.ts +3 -0
- package/lib/mol-geo/geometry/spheres/spheres.js +4 -2
- package/lib/mol-geo/geometry/substance-data.js +3 -3
- package/lib/mol-geo/geometry/text/text.d.ts +1 -0
- package/lib/mol-geo/geometry/texture-mesh/color-smoothing.js +3 -3
- package/lib/mol-geo/geometry/texture-mesh/texture-mesh.d.ts +3 -0
- package/lib/mol-geo/geometry/texture-mesh/texture-mesh.js +4 -2
- package/lib/mol-gl/renderable/cylinders.d.ts +31 -28
- package/lib/mol-gl/renderable/cylinders.js +3 -3
- package/lib/mol-gl/renderable/direct-volume.d.ts +1 -0
- package/lib/mol-gl/renderable/image.d.ts +1 -0
- package/lib/mol-gl/renderable/lines.d.ts +1 -0
- package/lib/mol-gl/renderable/mesh.d.ts +28 -25
- package/lib/mol-gl/renderable/mesh.js +3 -3
- package/lib/mol-gl/renderable/points.d.ts +1 -0
- package/lib/mol-gl/renderable/schema.d.ts +1 -0
- package/lib/mol-gl/renderable/schema.js +3 -3
- package/lib/mol-gl/renderable/spheres.d.ts +31 -28
- package/lib/mol-gl/renderable/spheres.js +3 -3
- package/lib/mol-gl/renderable/text.d.ts +1 -0
- package/lib/mol-gl/renderable/texture-mesh.d.ts +3 -0
- package/lib/mol-gl/renderable/texture-mesh.js +1 -1
- package/lib/mol-gl/shader/chunks/apply-light-color.glsl.d.ts +1 -1
- package/lib/mol-gl/shader/chunks/apply-light-color.glsl.js +1 -1
- 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/chunks/common-frag-params.glsl.d.ts +1 -1
- package/lib/mol-gl/shader/chunks/common-frag-params.glsl.js +1 -1
- package/lib/mol-gl/shader/chunks/common.glsl.d.ts +1 -1
- package/lib/mol-gl/shader/chunks/common.glsl.js +1 -1
- package/lib/mol-gl/shader/chunks/light-frag-params.glsl.d.ts +1 -1
- package/lib/mol-gl/shader/chunks/light-frag-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/mesh.frag.d.ts +1 -1
- package/lib/mol-gl/shader/mesh.frag.js +1 -1
- package/lib/mol-gl/shader/postprocessing.frag.d.ts +1 -1
- package/lib/mol-gl/shader/postprocessing.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-io/reader/cif/schema/mmcif.d.ts +326 -1
- package/lib/mol-io/reader/cif/schema/mmcif.js +326 -1
- package/lib/mol-math/geometry/symmetry-operator.js +3 -2
- package/lib/mol-model/structure/model/model.d.ts +1 -0
- package/lib/mol-model/structure/model/model.js +15 -5
- package/lib/mol-model/structure/model/properties/atomic/hierarchy.d.ts +6 -1
- package/lib/mol-model/structure/model/properties/atomic/hierarchy.js +1 -1
- package/lib/mol-model/structure/model/properties/utils/atomic-derived.d.ts +1 -1
- package/lib/mol-model/structure/model/properties/utils/atomic-derived.js +5 -2
- package/lib/mol-model/structure/model/properties/utils/atomic-index.d.ts +1 -1
- package/lib/mol-model/structure/model/properties/utils/atomic-index.js +12 -1
- package/lib/mol-model/structure/model/types.js +9 -0
- package/lib/mol-model/structure/structure/unit/rings.js +2 -0
- package/lib/mol-model-formats/shape/ply.d.ts +6 -0
- package/lib/mol-model-props/computed/representations/interactions-inter-unit-cylinder.d.ts +3 -0
- package/lib/mol-model-props/computed/representations/interactions-intra-unit-cylinder.d.ts +3 -0
- package/lib/mol-model-props/computed/representations/interactions.d.ts +9 -0
- package/lib/mol-model-props/integrative/cross-link-restraint/representation.d.ts +12 -0
- package/lib/mol-plugin/behavior/dynamic/selection/structure-focus-representation.d.ts +1 -0
- package/lib/mol-plugin/behavior/dynamic/volume-streaming/model.d.ts +3 -2
- package/lib/mol-plugin/commands.d.ts +3 -0
- package/lib/mol-plugin/config.d.ts +2 -0
- package/lib/mol-plugin/config.js +9 -3
- package/lib/mol-plugin/util/viewport-screenshot.d.ts +9 -0
- package/lib/mol-plugin/version.js +2 -2
- package/lib/mol-plugin-state/actions/structure.d.ts +7 -1
- package/lib/mol-plugin-state/actions/structure.js +150 -72
- package/lib/mol-plugin-state/builder/structure/hierarchy-preset.d.ts +5 -355
- package/lib/mol-plugin-state/builder/structure/hierarchy-preset.js +14 -9
- package/lib/mol-plugin-state/builder/structure/hierarchy.d.ts +1 -71
- package/lib/mol-plugin-state/helpers/structure-selection-query.js +34 -20
- package/lib/mol-plugin-state/manager/structure/component.d.ts +2 -0
- package/lib/mol-plugin-state/manager/structure/component.js +2 -2
- package/lib/mol-plugin-state/transforms/representation.d.ts +22 -0
- package/lib/mol-plugin-ui/controls/parameters.d.ts +3 -2
- package/lib/mol-plugin-ui/controls/parameters.js +12 -7
- package/lib/mol-plugin-ui/hooks/use-behavior.d.ts +1 -1
- package/lib/mol-plugin-ui/hooks/use-behavior.js +9 -18
- package/lib/mol-plugin-ui/index.d.ts +4 -4
- package/lib/mol-plugin-ui/index.js +11 -13
- package/lib/mol-plugin-ui/plugin.d.ts +1 -1
- package/lib/mol-plugin-ui/plugin.js +76 -10
- package/lib/mol-plugin-ui/skin/base/base.scss +32 -32
- package/lib/mol-plugin-ui/skin/base/components/controls-base.scss +333 -333
- package/lib/mol-plugin-ui/skin/base/components/controls.scss +418 -418
- package/lib/mol-plugin-ui/skin/base/components/help.scss +27 -27
- package/lib/mol-plugin-ui/skin/base/components/line-graph.scss +67 -67
- package/lib/mol-plugin-ui/skin/base/components/log.scss +100 -100
- package/lib/mol-plugin-ui/skin/base/components/misc.scss +643 -616
- package/lib/mol-plugin-ui/skin/base/components/sequence.scss +125 -125
- package/lib/mol-plugin-ui/skin/base/components/slider.scss +165 -165
- package/lib/mol-plugin-ui/skin/base/components/tasks.scss +99 -99
- package/lib/mol-plugin-ui/skin/base/components/toast.scss +83 -83
- package/lib/mol-plugin-ui/skin/base/components/transformer.scss +163 -163
- package/lib/mol-plugin-ui/skin/base/components/viewport.scss +127 -127
- package/lib/mol-plugin-ui/skin/base/layout/common.scss +71 -71
- package/lib/mol-plugin-ui/skin/base/layout/controls-landscape.scss +89 -89
- package/lib/mol-plugin-ui/skin/base/layout/controls-outside.scss +98 -98
- package/lib/mol-plugin-ui/skin/base/layout/controls-portrait.scss +108 -108
- package/lib/mol-plugin-ui/skin/base/layout.scss +40 -40
- package/lib/mol-plugin-ui/skin/base/logo.scss +12 -12
- package/lib/mol-plugin-ui/skin/base/normalize.scss +209 -209
- package/lib/mol-plugin-ui/skin/base/ui.scss +40 -40
- package/lib/mol-plugin-ui/skin/base/variables.scss +85 -85
- package/lib/mol-plugin-ui/skin/blue.scss +1 -1
- package/lib/mol-plugin-ui/skin/colors/blue.scss +23 -23
- package/lib/mol-plugin-ui/skin/colors/dark.scss +23 -23
- package/lib/mol-plugin-ui/skin/colors/light.scss +29 -29
- package/lib/mol-plugin-ui/skin/dark.scss +1 -1
- package/lib/mol-plugin-ui/skin/light.scss +1 -1
- package/lib/mol-repr/shape/loci/angle.d.ts +3 -0
- package/lib/mol-repr/shape/loci/common.d.ts +1 -0
- package/lib/mol-repr/shape/loci/dihedral.d.ts +3 -0
- package/lib/mol-repr/shape/loci/distance.d.ts +1 -0
- package/lib/mol-repr/shape/loci/label.d.ts +1 -0
- package/lib/mol-repr/shape/loci/orientation.d.ts +3 -0
- package/lib/mol-repr/shape/loci/plane.d.ts +3 -0
- package/lib/mol-repr/shape/model/unitcell.d.ts +3 -0
- package/lib/mol-repr/structure/complex-visual.d.ts +12 -0
- package/lib/mol-repr/structure/params.d.ts +16 -0
- package/lib/mol-repr/structure/registry.d.ts +35 -1
- package/lib/mol-repr/structure/representation/backbone.d.ts +9 -0
- package/lib/mol-repr/structure/representation/backbone.js +2 -1
- package/lib/mol-repr/structure/representation/ball-and-stick.d.ts +9 -0
- package/lib/mol-repr/structure/representation/ball-and-stick.js +2 -1
- package/lib/mol-repr/structure/representation/carbohydrate.d.ts +9 -0
- package/lib/mol-repr/structure/representation/carbohydrate.js +2 -1
- package/lib/mol-repr/structure/representation/cartoon.d.ts +9 -0
- package/lib/mol-repr/structure/representation/cartoon.js +2 -1
- package/lib/mol-repr/structure/representation/ellipsoid.d.ts +9 -0
- package/lib/mol-repr/structure/representation/ellipsoid.js +2 -1
- package/lib/mol-repr/structure/representation/gaussian-surface.d.ts +9 -0
- package/lib/mol-repr/structure/representation/gaussian-surface.js +2 -1
- package/lib/mol-repr/structure/representation/gaussian-volume.d.ts +3 -0
- package/lib/mol-repr/structure/representation/label.d.ts +6 -3
- package/lib/mol-repr/structure/representation/line.d.ts +3 -0
- package/lib/mol-repr/structure/representation/molecular-surface.d.ts +9 -0
- package/lib/mol-repr/structure/representation/molecular-surface.js +2 -1
- package/lib/mol-repr/structure/representation/orientation.d.ts +9 -0
- package/lib/mol-repr/structure/representation/orientation.js +2 -1
- package/lib/mol-repr/structure/representation/point.d.ts +3 -0
- package/lib/mol-repr/structure/representation/putty.d.ts +9 -0
- package/lib/mol-repr/structure/representation/putty.js +2 -1
- package/lib/mol-repr/structure/representation/spacefill.d.ts +9 -0
- package/lib/mol-repr/structure/representation/spacefill.js +2 -1
- package/lib/mol-repr/structure/units-visual.d.ts +16 -0
- package/lib/mol-repr/structure/visual/bond-inter-unit-cylinder.d.ts +6 -0
- package/lib/mol-repr/structure/visual/bond-inter-unit-line.d.ts +1 -0
- package/lib/mol-repr/structure/visual/bond-intra-unit-cylinder.d.ts +6 -0
- package/lib/mol-repr/structure/visual/bond-intra-unit-cylinder.js +2 -2
- package/lib/mol-repr/structure/visual/bond-intra-unit-line.d.ts +1 -0
- package/lib/mol-repr/structure/visual/bond-intra-unit-line.js +2 -2
- package/lib/mol-repr/structure/visual/carbohydrate-link-cylinder.d.ts +3 -0
- package/lib/mol-repr/structure/visual/carbohydrate-symbol-mesh.d.ts +3 -0
- package/lib/mol-repr/structure/visual/carbohydrate-terminal-link-cylinder.d.ts +3 -0
- package/lib/mol-repr/structure/visual/element-cross.d.ts +1 -0
- package/lib/mol-repr/structure/visual/element-point.d.ts +1 -0
- package/lib/mol-repr/structure/visual/element-sphere.d.ts +6 -0
- package/lib/mol-repr/structure/visual/ellipsoid-mesh.d.ts +3 -0
- package/lib/mol-repr/structure/visual/gaussian-density-volume.d.ts +2 -0
- package/lib/mol-repr/structure/visual/gaussian-surface-mesh.d.ts +12 -0
- package/lib/mol-repr/structure/visual/gaussian-surface-wireframe.d.ts +1 -0
- package/lib/mol-repr/structure/visual/label-text.d.ts +3 -2
- package/lib/mol-repr/structure/visual/label-text.js +2 -2
- package/lib/mol-repr/structure/visual/molecular-surface-mesh.d.ts +3 -0
- package/lib/mol-repr/structure/visual/molecular-surface-wireframe.d.ts +1 -0
- package/lib/mol-repr/structure/visual/nucleotide-block-mesh.d.ts +3 -0
- package/lib/mol-repr/structure/visual/nucleotide-ring-mesh.d.ts +3 -0
- package/lib/mol-repr/structure/visual/orientation-ellipsoid-mesh.d.ts +3 -0
- package/lib/mol-repr/structure/visual/polymer-backbone-cylinder.d.ts +6 -0
- package/lib/mol-repr/structure/visual/polymer-backbone-sphere.d.ts +6 -0
- package/lib/mol-repr/structure/visual/polymer-direction-wedge.d.ts +3 -0
- package/lib/mol-repr/structure/visual/polymer-gap-cylinder.d.ts +3 -0
- package/lib/mol-repr/structure/visual/polymer-trace-mesh.d.ts +3 -0
- package/lib/mol-repr/structure/visual/polymer-trace-mesh.js +1 -1
- package/lib/mol-repr/structure/visual/polymer-tube-mesh.d.ts +3 -0
- package/lib/mol-repr/structure/visual/util/bond.js +1 -1
- package/lib/mol-repr/volume/direct-volume.d.ts +3 -0
- package/lib/mol-repr/volume/isosurface.d.ts +16 -0
- package/lib/mol-repr/volume/isosurface.js +2 -1
- package/lib/mol-repr/volume/registry.d.ts +5 -0
- package/lib/mol-repr/volume/representation.d.ts +1 -0
- package/lib/mol-repr/volume/slice.d.ts +3 -0
- package/lib/mol-script/language/builder.d.ts +0 -1
- package/lib/mol-theme/color/illustrative.d.ts +2 -0
- package/lib/mol-theme/color/illustrative.js +2 -2
- package/lib/mol-theme/color.d.ts +1 -0
- package/lib/mol-util/material.d.ts +5 -1
- package/lib/mol-util/material.js +9 -7
- package/package.json +162 -160
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2021 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
|
+
*
|
|
4
|
+
* @author Mandar Deshpande <mandar@ebi.ac.uk>
|
|
5
|
+
* @author Sebastian Bittrich <sebastian.bittrich@rcsb.org>
|
|
6
|
+
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
7
|
+
*/
|
|
8
|
+
import { __awaiter, __generator } from "tslib";
|
|
9
|
+
import { QualityAssessment, QualityAssessmentProvider } from '../prop';
|
|
10
|
+
import { Bond, StructureElement, Unit } from '../../../../mol-model/structure';
|
|
11
|
+
import { Color } from '../../../../mol-util/color';
|
|
12
|
+
import { ParamDefinition as PD } from '../../../../mol-util/param-definition';
|
|
13
|
+
import { TableLegend } from '../../../../mol-util/legend';
|
|
14
|
+
var DefaultColor = Color(0xaaaaaa);
|
|
15
|
+
var ConfidenceColors = {
|
|
16
|
+
'No Score': DefaultColor,
|
|
17
|
+
'Very Low': Color(0xff7d45),
|
|
18
|
+
'Low': Color(0xffdb13),
|
|
19
|
+
'Confident': Color(0x65cbf3),
|
|
20
|
+
'Very High': Color(0x0053d6)
|
|
21
|
+
};
|
|
22
|
+
var ConfidenceColorLegend = TableLegend(Object.entries(ConfidenceColors));
|
|
23
|
+
export function getPLDDTConfidenceColorThemeParams(ctx) {
|
|
24
|
+
return {};
|
|
25
|
+
}
|
|
26
|
+
export function PLDDTConfidenceColorTheme(ctx, props) {
|
|
27
|
+
var color = function () { return DefaultColor; };
|
|
28
|
+
if (ctx.structure) {
|
|
29
|
+
var l_1 = StructureElement.Location.create(ctx.structure.root);
|
|
30
|
+
var getColor_1 = function (location) {
|
|
31
|
+
var _a, _b;
|
|
32
|
+
var unit = location.unit, element = location.element;
|
|
33
|
+
if (!Unit.isAtomic(unit))
|
|
34
|
+
return DefaultColor;
|
|
35
|
+
var qualityAssessment = QualityAssessmentProvider.get(unit.model).value;
|
|
36
|
+
var score = (_b = (_a = qualityAssessment === null || qualityAssessment === void 0 ? void 0 : qualityAssessment.pLDDT) === null || _a === void 0 ? void 0 : _a.get(unit.model.atomicHierarchy.residueAtomSegments.index[element])) !== null && _b !== void 0 ? _b : -1;
|
|
37
|
+
if (score < 0) {
|
|
38
|
+
return DefaultColor;
|
|
39
|
+
}
|
|
40
|
+
else if (score <= 50) {
|
|
41
|
+
return Color(0xff7d45);
|
|
42
|
+
}
|
|
43
|
+
else if (score <= 70) {
|
|
44
|
+
return Color(0xffdb13);
|
|
45
|
+
}
|
|
46
|
+
else if (score <= 90) {
|
|
47
|
+
return Color(0x65cbf3);
|
|
48
|
+
}
|
|
49
|
+
else {
|
|
50
|
+
return Color(0x0053d6);
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
color = function (location) {
|
|
54
|
+
if (StructureElement.Location.is(location)) {
|
|
55
|
+
return getColor_1(location);
|
|
56
|
+
}
|
|
57
|
+
else if (Bond.isLocation(location)) {
|
|
58
|
+
l_1.unit = location.aUnit;
|
|
59
|
+
l_1.element = location.aUnit.elements[location.aIndex];
|
|
60
|
+
return getColor_1(l_1);
|
|
61
|
+
}
|
|
62
|
+
return DefaultColor;
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
return {
|
|
66
|
+
factory: PLDDTConfidenceColorTheme,
|
|
67
|
+
granularity: 'group',
|
|
68
|
+
preferSmoothing: true,
|
|
69
|
+
color: color,
|
|
70
|
+
props: props,
|
|
71
|
+
description: 'Assigns residue colors according to the pLDDT Confidence score.',
|
|
72
|
+
legend: ConfidenceColorLegend
|
|
73
|
+
};
|
|
74
|
+
}
|
|
75
|
+
export var PLDDTConfidenceColorThemeProvider = {
|
|
76
|
+
name: 'plddt-confidence',
|
|
77
|
+
label: 'pLDDT Confidence',
|
|
78
|
+
category: "Validation" /* Validation */,
|
|
79
|
+
factory: PLDDTConfidenceColorTheme,
|
|
80
|
+
getParams: getPLDDTConfidenceColorThemeParams,
|
|
81
|
+
defaultValues: PD.getDefaultValues(getPLDDTConfidenceColorThemeParams({})),
|
|
82
|
+
isApplicable: function (ctx) { var _a; return !!((_a = ctx.structure) === null || _a === void 0 ? void 0 : _a.models.some(function (m) { return QualityAssessment.isApplicable(m, 'pLDDT'); })); },
|
|
83
|
+
ensureCustomProperties: {
|
|
84
|
+
attach: function (ctx, data) { return __awaiter(void 0, void 0, void 0, function () {
|
|
85
|
+
var _i, _a, m;
|
|
86
|
+
return __generator(this, function (_b) {
|
|
87
|
+
switch (_b.label) {
|
|
88
|
+
case 0:
|
|
89
|
+
if (!data.structure) return [3 /*break*/, 4];
|
|
90
|
+
_i = 0, _a = data.structure.models;
|
|
91
|
+
_b.label = 1;
|
|
92
|
+
case 1:
|
|
93
|
+
if (!(_i < _a.length)) return [3 /*break*/, 4];
|
|
94
|
+
m = _a[_i];
|
|
95
|
+
return [4 /*yield*/, QualityAssessmentProvider.attach(ctx, m, void 0, true)];
|
|
96
|
+
case 2:
|
|
97
|
+
_b.sent();
|
|
98
|
+
_b.label = 3;
|
|
99
|
+
case 3:
|
|
100
|
+
_i++;
|
|
101
|
+
return [3 /*break*/, 1];
|
|
102
|
+
case 4: return [2 /*return*/];
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
}); },
|
|
106
|
+
detach: function (data) { return __awaiter(void 0, void 0, void 0, function () {
|
|
107
|
+
var _i, _a, m;
|
|
108
|
+
return __generator(this, function (_b) {
|
|
109
|
+
if (data.structure) {
|
|
110
|
+
for (_i = 0, _a = data.structure.models; _i < _a.length; _i++) {
|
|
111
|
+
m = _a[_i];
|
|
112
|
+
QualityAssessmentProvider.ref(m, false);
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
return [2 /*return*/];
|
|
116
|
+
});
|
|
117
|
+
}); }
|
|
118
|
+
}
|
|
119
|
+
};
|
|
120
|
+
//# sourceMappingURL=plddt.js.map
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2021 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
|
+
*
|
|
4
|
+
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
5
|
+
*/
|
|
6
|
+
import { ColorTheme } from '../../../../mol-theme/color';
|
|
7
|
+
import { ThemeDataContext } from '../../../../mol-theme/theme';
|
|
8
|
+
import { ParamDefinition as PD } from '../../../../mol-util/param-definition';
|
|
9
|
+
export declare function getQmeanScoreColorThemeParams(ctx: ThemeDataContext): {};
|
|
10
|
+
export declare type QmeanScoreColorThemeParams = ReturnType<typeof getQmeanScoreColorThemeParams>;
|
|
11
|
+
export declare function QmeanScoreColorTheme(ctx: ThemeDataContext, props: PD.Values<QmeanScoreColorThemeParams>): ColorTheme<QmeanScoreColorThemeParams>;
|
|
12
|
+
export declare const QmeanScoreColorThemeProvider: ColorTheme.Provider<QmeanScoreColorThemeParams, 'qmean-score'>;
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2021 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
|
+
*
|
|
4
|
+
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
5
|
+
*/
|
|
6
|
+
import { __awaiter, __generator } from "tslib";
|
|
7
|
+
import { QualityAssessment, QualityAssessmentProvider } from '../prop';
|
|
8
|
+
import { Bond, StructureElement, Unit } from '../../../../mol-model/structure';
|
|
9
|
+
import { Color, ColorScale } from '../../../../mol-util/color';
|
|
10
|
+
import { ParamDefinition as PD } from '../../../../mol-util/param-definition';
|
|
11
|
+
var DefaultColor = Color(0xaaaaaa);
|
|
12
|
+
export function getQmeanScoreColorThemeParams(ctx) {
|
|
13
|
+
return {};
|
|
14
|
+
}
|
|
15
|
+
export function QmeanScoreColorTheme(ctx, props) {
|
|
16
|
+
var color = function () { return DefaultColor; };
|
|
17
|
+
var scale = ColorScale.create({
|
|
18
|
+
domain: [0, 1],
|
|
19
|
+
listOrName: [
|
|
20
|
+
[Color(0xFF5000), 0.5], [Color(0x025AFD), 1.0]
|
|
21
|
+
]
|
|
22
|
+
});
|
|
23
|
+
if (ctx.structure) {
|
|
24
|
+
var l_1 = StructureElement.Location.create(ctx.structure.root);
|
|
25
|
+
var getColor_1 = function (location) {
|
|
26
|
+
var _a, _b;
|
|
27
|
+
var unit = location.unit, element = location.element;
|
|
28
|
+
if (!Unit.isAtomic(unit))
|
|
29
|
+
return DefaultColor;
|
|
30
|
+
var qualityAssessment = QualityAssessmentProvider.get(unit.model).value;
|
|
31
|
+
var score = (_b = (_a = qualityAssessment === null || qualityAssessment === void 0 ? void 0 : qualityAssessment.qmean) === null || _a === void 0 ? void 0 : _a.get(unit.model.atomicHierarchy.residueAtomSegments.index[element])) !== null && _b !== void 0 ? _b : -1;
|
|
32
|
+
if (score < 0) {
|
|
33
|
+
return DefaultColor;
|
|
34
|
+
}
|
|
35
|
+
else {
|
|
36
|
+
return scale.color(score);
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
color = function (location) {
|
|
40
|
+
if (StructureElement.Location.is(location)) {
|
|
41
|
+
return getColor_1(location);
|
|
42
|
+
}
|
|
43
|
+
else if (Bond.isLocation(location)) {
|
|
44
|
+
l_1.unit = location.aUnit;
|
|
45
|
+
l_1.element = location.aUnit.elements[location.aIndex];
|
|
46
|
+
return getColor_1(l_1);
|
|
47
|
+
}
|
|
48
|
+
return DefaultColor;
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
return {
|
|
52
|
+
factory: QmeanScoreColorTheme,
|
|
53
|
+
granularity: 'group',
|
|
54
|
+
preferSmoothing: true,
|
|
55
|
+
color: color,
|
|
56
|
+
props: props,
|
|
57
|
+
description: 'Assigns residue colors according to the QMEAN score.',
|
|
58
|
+
legend: scale.legend
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
export var QmeanScoreColorThemeProvider = {
|
|
62
|
+
name: 'qmean-score',
|
|
63
|
+
label: 'QMEAN Score',
|
|
64
|
+
category: "Validation" /* Validation */,
|
|
65
|
+
factory: QmeanScoreColorTheme,
|
|
66
|
+
getParams: getQmeanScoreColorThemeParams,
|
|
67
|
+
defaultValues: PD.getDefaultValues(getQmeanScoreColorThemeParams({})),
|
|
68
|
+
isApplicable: function (ctx) { var _a; return !!((_a = ctx.structure) === null || _a === void 0 ? void 0 : _a.models.some(function (m) { return QualityAssessment.isApplicable(m, 'qmean'); })); },
|
|
69
|
+
ensureCustomProperties: {
|
|
70
|
+
attach: function (ctx, data) { return __awaiter(void 0, void 0, void 0, function () {
|
|
71
|
+
var _i, _a, m;
|
|
72
|
+
return __generator(this, function (_b) {
|
|
73
|
+
switch (_b.label) {
|
|
74
|
+
case 0:
|
|
75
|
+
if (!data.structure) return [3 /*break*/, 4];
|
|
76
|
+
_i = 0, _a = data.structure.models;
|
|
77
|
+
_b.label = 1;
|
|
78
|
+
case 1:
|
|
79
|
+
if (!(_i < _a.length)) return [3 /*break*/, 4];
|
|
80
|
+
m = _a[_i];
|
|
81
|
+
return [4 /*yield*/, QualityAssessmentProvider.attach(ctx, m, void 0, true)];
|
|
82
|
+
case 2:
|
|
83
|
+
_b.sent();
|
|
84
|
+
_b.label = 3;
|
|
85
|
+
case 3:
|
|
86
|
+
_i++;
|
|
87
|
+
return [3 /*break*/, 1];
|
|
88
|
+
case 4: return [2 /*return*/];
|
|
89
|
+
}
|
|
90
|
+
});
|
|
91
|
+
}); },
|
|
92
|
+
detach: function (data) { return __awaiter(void 0, void 0, void 0, function () {
|
|
93
|
+
var _i, _a, m;
|
|
94
|
+
return __generator(this, function (_b) {
|
|
95
|
+
if (data.structure) {
|
|
96
|
+
for (_i = 0, _a = data.structure.models; _i < _a.length; _i++) {
|
|
97
|
+
m = _a[_i];
|
|
98
|
+
QualityAssessmentProvider.ref(m, false);
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
return [2 /*return*/];
|
|
102
|
+
});
|
|
103
|
+
}); }
|
|
104
|
+
}
|
|
105
|
+
};
|
|
106
|
+
//# sourceMappingURL=qmean.js.map
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2021 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
|
+
*
|
|
4
|
+
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
5
|
+
*/
|
|
6
|
+
import { ParamDefinition as PD } from '../../../mol-util/param-definition';
|
|
7
|
+
import { CustomProperty } from '../../../mol-model-props/common/custom-property';
|
|
8
|
+
import { CustomModelProperty } from '../../../mol-model-props/common/custom-model-property';
|
|
9
|
+
import { Model, ResidueIndex } from '../../../mol-model/structure/model';
|
|
10
|
+
import { QuerySymbolRuntime } from '../../../mol-script/runtime/query/compiler';
|
|
11
|
+
export { QualityAssessment };
|
|
12
|
+
interface QualityAssessment {
|
|
13
|
+
localMetrics: Map<string, Map<ResidueIndex, number>>;
|
|
14
|
+
pLDDT?: Map<ResidueIndex, number>;
|
|
15
|
+
qmean?: Map<ResidueIndex, number>;
|
|
16
|
+
}
|
|
17
|
+
declare namespace QualityAssessment {
|
|
18
|
+
function isApplicable(model?: Model, localMetricName?: 'pLDDT' | 'qmean'): boolean;
|
|
19
|
+
function obtain(ctx: CustomProperty.Context, model: Model, props: QualityAssessmentProps): Promise<CustomProperty.Data<QualityAssessment>>;
|
|
20
|
+
const symbols: {
|
|
21
|
+
pLDDT: QuerySymbolRuntime;
|
|
22
|
+
qmean: QuerySymbolRuntime;
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
export declare const QualityAssessmentParams: {};
|
|
26
|
+
export declare type QualityAssessmentParams = typeof QualityAssessmentParams;
|
|
27
|
+
export declare type QualityAssessmentProps = PD.Values<QualityAssessmentParams>;
|
|
28
|
+
export declare const QualityAssessmentProvider: CustomModelProperty.Provider<QualityAssessmentParams, QualityAssessment>;
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2021 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
|
+
*
|
|
4
|
+
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
5
|
+
*/
|
|
6
|
+
import { __assign, __awaiter, __generator } from "tslib";
|
|
7
|
+
import { ParamDefinition as PD } from '../../../mol-util/param-definition';
|
|
8
|
+
import { Unit } from '../../../mol-model/structure';
|
|
9
|
+
import { CustomModelProperty } from '../../../mol-model-props/common/custom-model-property';
|
|
10
|
+
import { QuerySymbolRuntime } from '../../../mol-script/runtime/query/compiler';
|
|
11
|
+
import { CustomPropSymbol } from '../../../mol-script/language/symbol';
|
|
12
|
+
import { Type } from '../../../mol-script/language/type';
|
|
13
|
+
import { CustomPropertyDescriptor } from '../../../mol-model/custom-property';
|
|
14
|
+
import { MmcifFormat } from '../../../mol-model-formats/structure/mmcif';
|
|
15
|
+
export { QualityAssessment };
|
|
16
|
+
var QualityAssessment;
|
|
17
|
+
(function (QualityAssessment) {
|
|
18
|
+
var Empty = {
|
|
19
|
+
value: {
|
|
20
|
+
localMetrics: new Map()
|
|
21
|
+
}
|
|
22
|
+
};
|
|
23
|
+
function isApplicable(model, localMetricName) {
|
|
24
|
+
if (!model || !MmcifFormat.is(model.sourceData))
|
|
25
|
+
return false;
|
|
26
|
+
var db = model.sourceData.data.db;
|
|
27
|
+
var hasLocalMetric = (db.ma_qa_metric.id.isDefined &&
|
|
28
|
+
db.ma_qa_metric_local.ordinal_id.isDefined);
|
|
29
|
+
if (localMetricName && hasLocalMetric) {
|
|
30
|
+
for (var i = 0, il = db.ma_qa_metric._rowCount; i < il; i++) {
|
|
31
|
+
if (db.ma_qa_metric.mode.value(i) !== 'local')
|
|
32
|
+
continue;
|
|
33
|
+
if (localMetricName === db.ma_qa_metric.name.value(i))
|
|
34
|
+
return true;
|
|
35
|
+
}
|
|
36
|
+
return false;
|
|
37
|
+
}
|
|
38
|
+
else {
|
|
39
|
+
return hasLocalMetric;
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
QualityAssessment.isApplicable = isApplicable;
|
|
43
|
+
function obtain(ctx, model, props) {
|
|
44
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
45
|
+
var _a, ma_qa_metric, ma_qa_metric_local, model_id, label_asym_id, label_seq_id, metric_id, metric_value, index, localMetrics, localNames, i, il, name_1, i, il, labelAsymId, entityIndex, rI, name_2;
|
|
46
|
+
return __generator(this, function (_b) {
|
|
47
|
+
if (!model || !MmcifFormat.is(model.sourceData))
|
|
48
|
+
return [2 /*return*/, Empty];
|
|
49
|
+
_a = model.sourceData.data.db, ma_qa_metric = _a.ma_qa_metric, ma_qa_metric_local = _a.ma_qa_metric_local;
|
|
50
|
+
model_id = ma_qa_metric_local.model_id, label_asym_id = ma_qa_metric_local.label_asym_id, label_seq_id = ma_qa_metric_local.label_seq_id, metric_id = ma_qa_metric_local.metric_id, metric_value = ma_qa_metric_local.metric_value;
|
|
51
|
+
index = model.atomicHierarchy.index;
|
|
52
|
+
localMetrics = new Map();
|
|
53
|
+
localNames = new Map();
|
|
54
|
+
for (i = 0, il = ma_qa_metric._rowCount; i < il; i++) {
|
|
55
|
+
if (ma_qa_metric.mode.value(i) !== 'local')
|
|
56
|
+
continue;
|
|
57
|
+
name_1 = ma_qa_metric.name.value(i);
|
|
58
|
+
if (localMetrics.has(name_1)) {
|
|
59
|
+
console.warn("local ma_qa_metric with name '".concat(name_1, "' already added"));
|
|
60
|
+
continue;
|
|
61
|
+
}
|
|
62
|
+
localMetrics.set(name_1, new Map());
|
|
63
|
+
localNames.set(ma_qa_metric.id.value(i), name_1);
|
|
64
|
+
}
|
|
65
|
+
for (i = 0, il = ma_qa_metric_local._rowCount; i < il; i++) {
|
|
66
|
+
if (model_id.value(i) !== model.modelNum)
|
|
67
|
+
continue;
|
|
68
|
+
labelAsymId = label_asym_id.value(i);
|
|
69
|
+
entityIndex = index.findEntity(labelAsymId);
|
|
70
|
+
rI = index.findResidue(model.entities.data.id.value(entityIndex), labelAsymId, label_seq_id.value(i));
|
|
71
|
+
name_2 = localNames.get(metric_id.value(i));
|
|
72
|
+
localMetrics.get(name_2).set(rI, metric_value.value(i));
|
|
73
|
+
}
|
|
74
|
+
return [2 /*return*/, {
|
|
75
|
+
value: {
|
|
76
|
+
localMetrics: localMetrics,
|
|
77
|
+
pLDDT: localMetrics.get('pLDDT'),
|
|
78
|
+
qmean: localMetrics.get('qmean'),
|
|
79
|
+
}
|
|
80
|
+
}];
|
|
81
|
+
});
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
QualityAssessment.obtain = obtain;
|
|
85
|
+
QualityAssessment.symbols = {
|
|
86
|
+
pLDDT: QuerySymbolRuntime.Dynamic(CustomPropSymbol('ma', 'quality-assessment.pLDDT', Type.Num), function (ctx) {
|
|
87
|
+
var _a, _b;
|
|
88
|
+
var _c = ctx.element, unit = _c.unit, element = _c.element;
|
|
89
|
+
if (!Unit.isAtomic(unit))
|
|
90
|
+
return -1;
|
|
91
|
+
var qualityAssessment = QualityAssessmentProvider.get(unit.model).value;
|
|
92
|
+
return (_b = (_a = qualityAssessment === null || qualityAssessment === void 0 ? void 0 : qualityAssessment.pLDDT) === null || _a === void 0 ? void 0 : _a.get(unit.model.atomicHierarchy.residueAtomSegments.index[element])) !== null && _b !== void 0 ? _b : -1;
|
|
93
|
+
}),
|
|
94
|
+
qmean: QuerySymbolRuntime.Dynamic(CustomPropSymbol('ma', 'quality-assessment.qmean', Type.Num), function (ctx) {
|
|
95
|
+
var _a, _b;
|
|
96
|
+
var _c = ctx.element, unit = _c.unit, element = _c.element;
|
|
97
|
+
if (!Unit.isAtomic(unit))
|
|
98
|
+
return -1;
|
|
99
|
+
var qualityAssessment = QualityAssessmentProvider.get(unit.model).value;
|
|
100
|
+
return (_b = (_a = qualityAssessment === null || qualityAssessment === void 0 ? void 0 : qualityAssessment.qmean) === null || _a === void 0 ? void 0 : _a.get(unit.model.atomicHierarchy.residueAtomSegments.index[element])) !== null && _b !== void 0 ? _b : -1;
|
|
101
|
+
}),
|
|
102
|
+
};
|
|
103
|
+
})(QualityAssessment || (QualityAssessment = {}));
|
|
104
|
+
export var QualityAssessmentParams = {};
|
|
105
|
+
export var QualityAssessmentProvider = CustomModelProperty.createProvider({
|
|
106
|
+
label: 'QualityAssessment',
|
|
107
|
+
descriptor: CustomPropertyDescriptor({
|
|
108
|
+
name: 'ma_quality_assessment',
|
|
109
|
+
symbols: QualityAssessment.symbols
|
|
110
|
+
}),
|
|
111
|
+
type: 'static',
|
|
112
|
+
defaultParams: QualityAssessmentParams,
|
|
113
|
+
getParams: function (data) { return QualityAssessmentParams; },
|
|
114
|
+
isApplicable: function (data) { return QualityAssessment.isApplicable(data); },
|
|
115
|
+
obtain: function (ctx, data, props) { return __awaiter(void 0, void 0, void 0, function () {
|
|
116
|
+
var p;
|
|
117
|
+
return __generator(this, function (_a) {
|
|
118
|
+
switch (_a.label) {
|
|
119
|
+
case 0:
|
|
120
|
+
p = __assign(__assign({}, PD.getDefaultValues(QualityAssessmentParams)), props);
|
|
121
|
+
return [4 /*yield*/, QualityAssessment.obtain(ctx, data, p)];
|
|
122
|
+
case 1: return [2 /*return*/, _a.sent()];
|
|
123
|
+
}
|
|
124
|
+
});
|
|
125
|
+
}); }
|
|
126
|
+
});
|
|
127
|
+
//# sourceMappingURL=prop.js.map
|
|
@@ -121,16 +121,18 @@ var Mp4Controls = /** @class */ (function (_super) {
|
|
|
121
121
|
});
|
|
122
122
|
this.subscribe((_a = this.plugin.canvas3d) === null || _a === void 0 ? void 0 : _a.resized, function () { return _this.syncInfo(); });
|
|
123
123
|
this.subscribe((_b = this.plugin.helpers.viewportScreenshot) === null || _b === void 0 ? void 0 : _b.events.previewed, function () { return _this.syncInfo(); });
|
|
124
|
-
this.subscribe(this.plugin.behaviors.state.isBusy, function (b) {
|
|
125
|
-
|
|
126
|
-
var anim = _this.current;
|
|
127
|
-
if (!b && anim) {
|
|
128
|
-
_this.behaviors.canApply.next((_c = (_b = (_a = anim.anim).canApply) === null || _b === void 0 ? void 0 : _b.call(_a, _this.plugin)) !== null && _c !== void 0 ? _c : { canApply: true });
|
|
129
|
-
}
|
|
130
|
-
});
|
|
124
|
+
this.subscribe(this.plugin.behaviors.state.isBusy, function (b) { return _this.updateCanApply(b); });
|
|
125
|
+
this.subscribe(this.plugin.managers.snapshot.events.changed, function (b) { return _this.updateCanApply(b); });
|
|
131
126
|
this.sync();
|
|
132
127
|
this.syncInfo();
|
|
133
128
|
};
|
|
129
|
+
Mp4Controls.prototype.updateCanApply = function (b) {
|
|
130
|
+
var _a, _b, _c;
|
|
131
|
+
var anim = this.current;
|
|
132
|
+
if (!b && anim) {
|
|
133
|
+
this.behaviors.canApply.next((_c = (_b = (_a = anim.anim).canApply) === null || _b === void 0 ? void 0 : _b.call(_a, this.plugin)) !== null && _c !== void 0 ? _c : { canApply: true });
|
|
134
|
+
}
|
|
135
|
+
};
|
|
134
136
|
return Mp4Controls;
|
|
135
137
|
}(PluginComponent));
|
|
136
138
|
export { Mp4Controls };
|
|
@@ -30,7 +30,7 @@ var StructureQualityReport;
|
|
|
30
30
|
}
|
|
31
31
|
StructureQualityReport.getEntryUrl = getEntryUrl;
|
|
32
32
|
function isApplicable(model) {
|
|
33
|
-
return !!model && Model.
|
|
33
|
+
return !!model && Model.hasPdbId(model);
|
|
34
34
|
}
|
|
35
35
|
StructureQualityReport.isApplicable = isApplicable;
|
|
36
36
|
StructureQualityReport.Schema = {
|
|
@@ -24,11 +24,14 @@ declare const AssemblySymmetry3D: StateTransformer<PluginStateObject.Molecule.St
|
|
|
24
24
|
flatShaded: boolean;
|
|
25
25
|
ignoreLight: boolean;
|
|
26
26
|
xrayShaded: boolean;
|
|
27
|
+
bumpFrequency: number;
|
|
28
|
+
bumpAmplitude: number;
|
|
27
29
|
alpha: number;
|
|
28
30
|
quality: "auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest";
|
|
29
31
|
material: PD.Normalize<{
|
|
30
32
|
metalness: number;
|
|
31
33
|
roughness: number;
|
|
34
|
+
bumpiness: number;
|
|
32
35
|
}>;
|
|
33
36
|
axesColor: PD.NamedParams<PD.Normalize<{
|
|
34
37
|
colorValue: any;
|
|
@@ -49,7 +49,7 @@ export var AssemblySymmetry;
|
|
|
49
49
|
AssemblySymmetry.DefaultServerUrl = 'https://data.rcsb.org/graphql';
|
|
50
50
|
function isApplicable(structure) {
|
|
51
51
|
return (!!structure && structure.models.length === 1 &&
|
|
52
|
-
Model.
|
|
52
|
+
Model.hasPdbId(structure.models[0]) &&
|
|
53
53
|
isBiologicalAssembly(structure));
|
|
54
54
|
}
|
|
55
55
|
AssemblySymmetry.isApplicable = isApplicable;
|
|
@@ -16,11 +16,14 @@ export declare const AssemblySymmetryParams: {
|
|
|
16
16
|
flatShaded: PD.BooleanParam;
|
|
17
17
|
ignoreLight: PD.BooleanParam;
|
|
18
18
|
xrayShaded: PD.BooleanParam;
|
|
19
|
+
bumpFrequency: PD.Numeric;
|
|
20
|
+
bumpAmplitude: PD.Numeric;
|
|
19
21
|
alpha: PD.Numeric;
|
|
20
22
|
quality: PD.Select<"auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest">;
|
|
21
23
|
material: PD.Group<PD.Normalize<{
|
|
22
24
|
metalness: number;
|
|
23
25
|
roughness: number;
|
|
26
|
+
bumpiness: number;
|
|
24
27
|
}>>;
|
|
25
28
|
axesColor: PD.Mapped<PD.NamedParams<PD.Normalize<{
|
|
26
29
|
colorValue: Color;
|
|
@@ -37,7 +37,7 @@ var ValidationReport;
|
|
|
37
37
|
}
|
|
38
38
|
ValidationReport.getEntryUrl = getEntryUrl;
|
|
39
39
|
function isApplicable(model) {
|
|
40
|
-
return !!model && Model.
|
|
40
|
+
return !!model && Model.hasPdbId(model);
|
|
41
41
|
}
|
|
42
42
|
ValidationReport.isApplicable = isApplicable;
|
|
43
43
|
function fromXml(xml, model) {
|
|
@@ -31,11 +31,14 @@ export declare const IntraUnitClashParams: {
|
|
|
31
31
|
flatShaded: PD.BooleanParam;
|
|
32
32
|
ignoreLight: PD.BooleanParam;
|
|
33
33
|
xrayShaded: PD.BooleanParam;
|
|
34
|
+
bumpFrequency: PD.Numeric;
|
|
35
|
+
bumpAmplitude: PD.Numeric;
|
|
34
36
|
alpha: PD.Numeric;
|
|
35
37
|
quality: PD.Select<"auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest">;
|
|
36
38
|
material: PD.Group<PD.Normalize<{
|
|
37
39
|
metalness: number;
|
|
38
40
|
roughness: number;
|
|
41
|
+
bumpiness: number;
|
|
39
42
|
}>>;
|
|
40
43
|
};
|
|
41
44
|
export declare type IntraUnitClashParams = typeof IntraUnitClashParams;
|
|
@@ -60,11 +63,14 @@ export declare const InterUnitClashParams: {
|
|
|
60
63
|
flatShaded: PD.BooleanParam;
|
|
61
64
|
ignoreLight: PD.BooleanParam;
|
|
62
65
|
xrayShaded: PD.BooleanParam;
|
|
66
|
+
bumpFrequency: PD.Numeric;
|
|
67
|
+
bumpAmplitude: PD.Numeric;
|
|
63
68
|
alpha: PD.Numeric;
|
|
64
69
|
quality: PD.Select<"auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest">;
|
|
65
70
|
material: PD.Group<PD.Normalize<{
|
|
66
71
|
metalness: number;
|
|
67
72
|
roughness: number;
|
|
73
|
+
bumpiness: number;
|
|
68
74
|
}>>;
|
|
69
75
|
};
|
|
70
76
|
export declare type InterUnitClashParams = typeof InterUnitClashParams;
|
|
@@ -90,11 +96,14 @@ export declare const ClashesParams: {
|
|
|
90
96
|
flatShaded: PD.BooleanParam;
|
|
91
97
|
ignoreLight: PD.BooleanParam;
|
|
92
98
|
xrayShaded: PD.BooleanParam;
|
|
99
|
+
bumpFrequency: PD.Numeric;
|
|
100
|
+
bumpAmplitude: PD.Numeric;
|
|
93
101
|
alpha: PD.Numeric;
|
|
94
102
|
quality: PD.Select<"auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest">;
|
|
95
103
|
material: PD.Group<PD.Normalize<{
|
|
96
104
|
metalness: number;
|
|
97
105
|
roughness: number;
|
|
106
|
+
bumpiness: number;
|
|
98
107
|
}>>;
|
|
99
108
|
};
|
|
100
109
|
export declare type ClashesParams = typeof ClashesParams;
|
|
@@ -119,11 +128,14 @@ export declare function getClashesParams(ctx: ThemeRegistryContext, structure: S
|
|
|
119
128
|
flatShaded: PD.BooleanParam;
|
|
120
129
|
ignoreLight: PD.BooleanParam;
|
|
121
130
|
xrayShaded: PD.BooleanParam;
|
|
131
|
+
bumpFrequency: PD.Numeric;
|
|
132
|
+
bumpAmplitude: PD.Numeric;
|
|
122
133
|
alpha: PD.Numeric;
|
|
123
134
|
quality: PD.Select<"auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest">;
|
|
124
135
|
material: PD.Group<PD.Normalize<{
|
|
125
136
|
metalness: number;
|
|
126
137
|
roughness: number;
|
|
138
|
+
bumpiness: number;
|
|
127
139
|
}>>;
|
|
128
140
|
};
|
|
129
141
|
export declare type ClashesRepresentation = StructureRepresentation<ClashesParams>;
|
|
@@ -149,10 +161,13 @@ export declare const ClashesRepresentationProvider: StructureRepresentationProvi
|
|
|
149
161
|
flatShaded: PD.BooleanParam;
|
|
150
162
|
ignoreLight: PD.BooleanParam;
|
|
151
163
|
xrayShaded: PD.BooleanParam;
|
|
164
|
+
bumpFrequency: PD.Numeric;
|
|
165
|
+
bumpAmplitude: PD.Numeric;
|
|
152
166
|
alpha: PD.Numeric;
|
|
153
167
|
quality: PD.Select<"auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest">;
|
|
154
168
|
material: PD.Group<PD.Normalize<{
|
|
155
169
|
metalness: number;
|
|
156
170
|
roughness: number;
|
|
171
|
+
bumpiness: number;
|
|
157
172
|
}>>;
|
|
158
173
|
}, ValidationReport.Tag.Clashes>;
|
|
@@ -67,6 +67,7 @@ export declare const Canvas3DParams: {
|
|
|
67
67
|
outline: PD.NamedParams<PD.Normalize<unknown>, "off"> | PD.NamedParams<PD.Normalize<{
|
|
68
68
|
scale: any;
|
|
69
69
|
threshold: any;
|
|
70
|
+
color: any;
|
|
70
71
|
}>, "on">;
|
|
71
72
|
antialiasing: PD.NamedParams<PD.Normalize<unknown>, "off"> | PD.NamedParams<PD.Normalize<{
|
|
72
73
|
edgeThreshold: any;
|
|
@@ -164,6 +165,8 @@ export declare const Canvas3DParams: {
|
|
|
164
165
|
flipSided: any;
|
|
165
166
|
flatShaded: any;
|
|
166
167
|
xrayShaded: any;
|
|
168
|
+
bumpFrequency: any;
|
|
169
|
+
bumpAmplitude: any;
|
|
167
170
|
quality: any;
|
|
168
171
|
material: any;
|
|
169
172
|
}>, "on">;
|
|
@@ -215,6 +218,7 @@ export declare const DefaultCanvas3DParams: PD.Values<{
|
|
|
215
218
|
outline: PD.NamedParams<PD.Normalize<unknown>, "off"> | PD.NamedParams<PD.Normalize<{
|
|
216
219
|
scale: any;
|
|
217
220
|
threshold: any;
|
|
221
|
+
color: any;
|
|
218
222
|
}>, "on">;
|
|
219
223
|
antialiasing: PD.NamedParams<PD.Normalize<unknown>, "off"> | PD.NamedParams<PD.Normalize<{
|
|
220
224
|
edgeThreshold: any;
|
|
@@ -312,6 +316,8 @@ export declare const DefaultCanvas3DParams: PD.Values<{
|
|
|
312
316
|
flipSided: any;
|
|
313
317
|
flatShaded: any;
|
|
314
318
|
xrayShaded: any;
|
|
319
|
+
bumpFrequency: any;
|
|
320
|
+
bumpAmplitude: any;
|
|
315
321
|
quality: any;
|
|
316
322
|
material: any;
|
|
317
323
|
}>, "on">;
|
|
@@ -286,7 +286,13 @@ var Canvas3D;
|
|
|
286
286
|
cam = stereoCamera;
|
|
287
287
|
}
|
|
288
288
|
if (MultiSamplePass.isEnabled(p.multiSample)) {
|
|
289
|
-
|
|
289
|
+
if (!cameraChanged) {
|
|
290
|
+
while (!multiSampleHelper.render(renderer, cam, scene, helper, true, p.transparentBackground, p))
|
|
291
|
+
;
|
|
292
|
+
}
|
|
293
|
+
else {
|
|
294
|
+
multiSampleHelper.render(renderer, cam, scene, helper, true, p.transparentBackground, p);
|
|
295
|
+
}
|
|
290
296
|
}
|
|
291
297
|
else {
|
|
292
298
|
passes.draw.render(renderer, cam, scene, helper, true, p.transparentBackground, p.postprocessing, p.marking);
|
|
@@ -391,7 +397,7 @@ var Canvas3D;
|
|
|
391
397
|
return true;
|
|
392
398
|
if (camera.transition.inTransition || nextCameraResetSnapshot)
|
|
393
399
|
return false;
|
|
394
|
-
var cameraSphereOverlapsNone = true;
|
|
400
|
+
var cameraSphereOverlapsNone = true, isEmpty = true;
|
|
395
401
|
Sphere3D.set(cameraSphere, camera.state.target, camera.state.radius);
|
|
396
402
|
// check if any renderable has moved outside of the old bounding sphere
|
|
397
403
|
// and if no renderable is overlapping with the camera sphere
|
|
@@ -402,13 +408,14 @@ var Canvas3D;
|
|
|
402
408
|
var b = r.values.boundingSphere.ref.value;
|
|
403
409
|
if (!b.radius)
|
|
404
410
|
continue;
|
|
411
|
+
isEmpty = false;
|
|
405
412
|
var cameraDist = Vec3.distance(cameraSphere.center, b.center);
|
|
406
413
|
if ((cameraDist > cameraSphere.radius || cameraDist > b.radius || b.radius > camera.state.radiusMax) && !Sphere3D.includes(oldBoundingSphereVisible, b))
|
|
407
414
|
return true;
|
|
408
415
|
if (Sphere3D.overlaps(cameraSphere, b))
|
|
409
416
|
cameraSphereOverlapsNone = false;
|
|
410
417
|
}
|
|
411
|
-
return cameraSphereOverlapsNone;
|
|
418
|
+
return cameraSphereOverlapsNone || (!isEmpty && cameraSphere.radius <= 0.1);
|
|
412
419
|
}
|
|
413
420
|
var sceneCommitTimeoutMs = 250;
|
|
414
421
|
function commitScene(isSynchronous) {
|
|
@@ -22,10 +22,13 @@ export declare const CameraHelperParams: {
|
|
|
22
22
|
flipSided: boolean;
|
|
23
23
|
flatShaded: boolean;
|
|
24
24
|
xrayShaded: boolean;
|
|
25
|
+
bumpFrequency: number;
|
|
26
|
+
bumpAmplitude: number;
|
|
25
27
|
quality: "auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest";
|
|
26
28
|
material: PD.Normalize<{
|
|
27
29
|
metalness: number;
|
|
28
30
|
roughness: number;
|
|
31
|
+
bumpiness: number;
|
|
29
32
|
}>;
|
|
30
33
|
}>, "on">>;
|
|
31
34
|
};
|