molstar 3.4.0 → 3.5.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/LICENSE +20 -20
- package/README.md +202 -197
- package/build/viewer/embedded.html +43 -43
- package/build/viewer/index.html +106 -106
- package/build/viewer/molstar.js +1 -1
- package/lib/apps/docking-viewer/index.html +36 -36
- package/lib/apps/viewer/embedded.html +43 -43
- package/lib/apps/viewer/index.html +106 -106
- package/lib/cli/cif2bcif/converter.js +1 -1
- package/lib/cli/cif2bcif/index.js +4 -4
- package/lib/commonjs/cli/cif2bcif/converter.js +1 -1
- package/lib/commonjs/cli/cif2bcif/index.js +4 -4
- package/lib/commonjs/extensions/dnatco/confal-pyramids/color.d.ts +397 -2
- package/lib/commonjs/extensions/dnatco/confal-pyramids/color.js +223 -131
- package/lib/commonjs/extensions/dnatco/confal-pyramids/property.js +1 -3
- package/lib/commonjs/extensions/dnatco/confal-pyramids/util.js +18 -19
- package/lib/commonjs/mol-geo/geometry/cylinders/cylinders.d.ts +2 -2
- package/lib/commonjs/mol-geo/geometry/lines/lines.d.ts +0 -1
- package/lib/commonjs/mol-geo/geometry/mesh/color-smoothing.d.ts +1 -1
- package/lib/commonjs/mol-geo/geometry/mesh/color-smoothing.js +5 -3
- package/lib/commonjs/mol-geo/geometry/points/points.d.ts +1 -1
- package/lib/commonjs/mol-geo/geometry/texture-mesh/color-smoothing.d.ts +1 -1
- package/lib/commonjs/mol-geo/geometry/texture-mesh/color-smoothing.js +6 -4
- package/lib/commonjs/mol-gl/webgl/context.d.ts +1 -1
- package/lib/commonjs/mol-gl/webgl/context.js +2 -2
- package/lib/commonjs/mol-math/geometry/common.d.ts +2 -1
- package/lib/commonjs/mol-math/geometry/common.js +1 -1
- package/lib/commonjs/mol-math/geometry/gaussian-density/cpu.d.ts +1 -1
- package/lib/commonjs/mol-math/geometry/gaussian-density/cpu.js +2 -2
- package/lib/commonjs/mol-math/geometry/gaussian-density/gpu.d.ts +1 -1
- package/lib/commonjs/mol-math/geometry/gaussian-density/gpu.js +7 -7
- package/lib/commonjs/mol-math/geometry/gaussian-density.d.ts +2 -2
- package/lib/commonjs/mol-math/geometry/gaussian-density.js +1 -1
- package/lib/commonjs/mol-math/geometry/molecular-surface.d.ts +2 -1
- package/lib/commonjs/mol-math/geometry/molecular-surface.js +2 -2
- package/lib/commonjs/mol-math/geometry/primitives/box3d.js +2 -1
- package/lib/commonjs/mol-math/geometry/primitives/sphere3d.js +12 -6
- package/lib/commonjs/mol-plugin/behavior/dynamic/volume-streaming/model.d.ts +2 -3
- package/lib/commonjs/mol-repr/structure/visual/gaussian-density-volume.js +2 -3
- package/lib/commonjs/mol-repr/structure/visual/gaussian-surface-mesh.d.ts +1 -1
- package/lib/commonjs/mol-repr/structure/visual/gaussian-surface-mesh.js +9 -9
- package/lib/commonjs/mol-repr/structure/visual/gaussian-surface-wireframe.d.ts +1 -1
- package/lib/commonjs/mol-repr/structure/visual/gaussian-surface-wireframe.js +4 -5
- package/lib/commonjs/mol-repr/structure/visual/molecular-surface-mesh.js +3 -3
- package/lib/commonjs/mol-repr/structure/visual/molecular-surface-wireframe.d.ts +1 -1
- package/lib/commonjs/mol-repr/structure/visual/molecular-surface-wireframe.js +4 -4
- package/lib/commonjs/mol-repr/structure/visual/util/common.d.ts +1 -3
- package/lib/commonjs/mol-repr/structure/visual/util/common.js +2 -27
- package/lib/commonjs/mol-script/language/builder.d.ts +1 -0
- package/lib/examples/alpha-orbitals/index.html +61 -61
- package/lib/examples/basic-wrapper/index.html +137 -137
- package/lib/examples/lighting/index.html +88 -88
- package/lib/examples/proteopedia-wrapper/index.html +236 -236
- package/lib/extensions/dnatco/confal-pyramids/color.d.ts +397 -2
- package/lib/extensions/dnatco/confal-pyramids/color.js +224 -132
- package/lib/extensions/dnatco/confal-pyramids/property.js +1 -3
- package/lib/extensions/dnatco/confal-pyramids/util.js +19 -20
- package/lib/mol-geo/geometry/cylinders/cylinders.d.ts +2 -2
- package/lib/mol-geo/geometry/lines/lines.d.ts +0 -1
- package/lib/mol-geo/geometry/mesh/color-smoothing.d.ts +1 -1
- package/lib/mol-geo/geometry/mesh/color-smoothing.js +5 -3
- package/lib/mol-geo/geometry/points/points.d.ts +1 -1
- package/lib/mol-geo/geometry/texture-mesh/color-smoothing.d.ts +1 -1
- package/lib/mol-geo/geometry/texture-mesh/color-smoothing.js +6 -4
- package/lib/mol-gl/webgl/context.d.ts +1 -1
- package/lib/mol-gl/webgl/context.js +2 -2
- package/lib/mol-math/geometry/common.d.ts +2 -1
- package/lib/mol-math/geometry/common.js +1 -1
- package/lib/mol-math/geometry/gaussian-density/cpu.d.ts +1 -1
- package/lib/mol-math/geometry/gaussian-density/cpu.js +2 -2
- package/lib/mol-math/geometry/gaussian-density/gpu.d.ts +1 -1
- package/lib/mol-math/geometry/gaussian-density/gpu.js +7 -7
- package/lib/mol-math/geometry/gaussian-density.d.ts +2 -2
- package/lib/mol-math/geometry/gaussian-density.js +1 -1
- package/lib/mol-math/geometry/molecular-surface.d.ts +2 -1
- package/lib/mol-math/geometry/molecular-surface.js +2 -2
- package/lib/mol-math/geometry/primitives/box3d.js +2 -1
- package/lib/mol-math/geometry/primitives/sphere3d.js +12 -6
- package/lib/mol-plugin/behavior/dynamic/volume-streaming/model.d.ts +2 -3
- package/lib/mol-plugin/version.js +2 -2
- 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 -643
- 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 +128 -128
- 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/structure/visual/gaussian-density-volume.js +2 -3
- package/lib/mol-repr/structure/visual/gaussian-surface-mesh.d.ts +1 -1
- package/lib/mol-repr/structure/visual/gaussian-surface-mesh.js +10 -10
- package/lib/mol-repr/structure/visual/gaussian-surface-wireframe.d.ts +1 -1
- package/lib/mol-repr/structure/visual/gaussian-surface-wireframe.js +4 -5
- package/lib/mol-repr/structure/visual/molecular-surface-mesh.js +4 -4
- package/lib/mol-repr/structure/visual/molecular-surface-wireframe.d.ts +1 -1
- package/lib/mol-repr/structure/visual/molecular-surface-wireframe.js +5 -5
- package/lib/mol-repr/structure/visual/util/common.d.ts +1 -3
- package/lib/mol-repr/structure/visual/util/common.js +1 -24
- package/lib/mol-script/language/builder.d.ts +1 -0
- package/package.json +160 -160
|
@@ -6,141 +6,239 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { ConfalPyramids, ConfalPyramidsProvider } from './property';
|
|
8
8
|
import { ConfalPyramidsTypes as CPT } from './types';
|
|
9
|
-
import { Color } from '../../../mol-util/color';
|
|
9
|
+
import { Color, ColorMap } from '../../../mol-util/color';
|
|
10
|
+
import { getColorMapParams } from '../../../mol-util/color/params';
|
|
10
11
|
import { ParamDefinition as PD } from '../../../mol-util/param-definition';
|
|
11
12
|
import { TableLegend } from '../../../mol-util/legend';
|
|
12
|
-
import {
|
|
13
|
-
var DefaultColor = Color(0xCCCCCC);
|
|
13
|
+
import { ObjectKeys } from '../../../mol-util/type-helpers';
|
|
14
14
|
var Description = 'Assigns colors to confal pyramids';
|
|
15
|
+
var DefaultClassColors = {
|
|
16
|
+
A: 0xFFC1C1,
|
|
17
|
+
B: 0xC8CFFF,
|
|
18
|
+
BII: 0x0059DA,
|
|
19
|
+
miB: 0x3BE8FB,
|
|
20
|
+
Z: 0x01F60E,
|
|
21
|
+
IC: 0xFA5CFB,
|
|
22
|
+
OPN: 0xE90000,
|
|
23
|
+
SYN: 0xFFFF01,
|
|
24
|
+
N: 0xF2F2F2,
|
|
25
|
+
};
|
|
15
26
|
var ErrorColor = Color(0xFFA10A);
|
|
16
|
-
var
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
27
|
+
var PyramidsColors = ColorMap({
|
|
28
|
+
NANT_Upr: DefaultClassColors.N,
|
|
29
|
+
NANT_Lwr: DefaultClassColors.N,
|
|
30
|
+
AA00_Upr: DefaultClassColors.A,
|
|
31
|
+
AA00_Lwr: DefaultClassColors.A,
|
|
32
|
+
AA02_Upr: DefaultClassColors.A,
|
|
33
|
+
AA02_Lwr: DefaultClassColors.A,
|
|
34
|
+
AA03_Upr: DefaultClassColors.A,
|
|
35
|
+
AA03_Lwr: DefaultClassColors.A,
|
|
36
|
+
AA04_Upr: DefaultClassColors.A,
|
|
37
|
+
AA04_Lwr: DefaultClassColors.A,
|
|
38
|
+
AA08_Upr: DefaultClassColors.A,
|
|
39
|
+
AA08_Lwr: DefaultClassColors.A,
|
|
40
|
+
AA09_Upr: DefaultClassColors.A,
|
|
41
|
+
AA09_Lwr: DefaultClassColors.A,
|
|
42
|
+
AA01_Upr: DefaultClassColors.A,
|
|
43
|
+
AA01_Lwr: DefaultClassColors.A,
|
|
44
|
+
AA05_Upr: DefaultClassColors.A,
|
|
45
|
+
AA05_Lwr: DefaultClassColors.A,
|
|
46
|
+
AA06_Upr: DefaultClassColors.A,
|
|
47
|
+
AA06_Lwr: DefaultClassColors.A,
|
|
48
|
+
AA10_Upr: DefaultClassColors.A,
|
|
49
|
+
AA10_Lwr: DefaultClassColors.A,
|
|
50
|
+
AA11_Upr: DefaultClassColors.A,
|
|
51
|
+
AA11_Lwr: DefaultClassColors.A,
|
|
52
|
+
AA07_Upr: DefaultClassColors.A,
|
|
53
|
+
AA07_Lwr: DefaultClassColors.A,
|
|
54
|
+
AA12_Upr: DefaultClassColors.A,
|
|
55
|
+
AA12_Lwr: DefaultClassColors.A,
|
|
56
|
+
AA13_Upr: DefaultClassColors.A,
|
|
57
|
+
AA13_Lwr: DefaultClassColors.A,
|
|
58
|
+
AB01_Upr: DefaultClassColors.A,
|
|
59
|
+
AB01_Lwr: DefaultClassColors.B,
|
|
60
|
+
AB02_Upr: DefaultClassColors.A,
|
|
61
|
+
AB02_Lwr: DefaultClassColors.B,
|
|
62
|
+
AB03_Upr: DefaultClassColors.A,
|
|
63
|
+
AB03_Lwr: DefaultClassColors.B,
|
|
64
|
+
AB04_Upr: DefaultClassColors.A,
|
|
65
|
+
AB04_Lwr: DefaultClassColors.B,
|
|
66
|
+
AB05_Upr: DefaultClassColors.A,
|
|
67
|
+
AB05_Lwr: DefaultClassColors.B,
|
|
68
|
+
BA01_Upr: DefaultClassColors.B,
|
|
69
|
+
BA01_Lwr: DefaultClassColors.A,
|
|
70
|
+
BA05_Upr: DefaultClassColors.B,
|
|
71
|
+
BA05_Lwr: DefaultClassColors.A,
|
|
72
|
+
BA09_Upr: DefaultClassColors.B,
|
|
73
|
+
BA09_Lwr: DefaultClassColors.A,
|
|
74
|
+
BA08_Upr: DefaultClassColors.BII,
|
|
75
|
+
BA08_Lwr: DefaultClassColors.A,
|
|
76
|
+
BA10_Upr: DefaultClassColors.B,
|
|
77
|
+
BA10_Lwr: DefaultClassColors.A,
|
|
78
|
+
BA13_Upr: DefaultClassColors.BII,
|
|
79
|
+
BA13_Lwr: DefaultClassColors.A,
|
|
80
|
+
BA16_Upr: DefaultClassColors.BII,
|
|
81
|
+
BA16_Lwr: DefaultClassColors.A,
|
|
82
|
+
BA17_Upr: DefaultClassColors.BII,
|
|
83
|
+
BA17_Lwr: DefaultClassColors.A,
|
|
84
|
+
BB00_Upr: DefaultClassColors.B,
|
|
85
|
+
BB00_Lwr: DefaultClassColors.B,
|
|
86
|
+
BB01_Upr: DefaultClassColors.B,
|
|
87
|
+
BB01_Lwr: DefaultClassColors.B,
|
|
88
|
+
BB17_Upr: DefaultClassColors.B,
|
|
89
|
+
BB17_Lwr: DefaultClassColors.B,
|
|
90
|
+
BB02_Upr: DefaultClassColors.B,
|
|
91
|
+
BB02_Lwr: DefaultClassColors.B,
|
|
92
|
+
BB03_Upr: DefaultClassColors.B,
|
|
93
|
+
BB03_Lwr: DefaultClassColors.B,
|
|
94
|
+
BB11_Upr: DefaultClassColors.B,
|
|
95
|
+
BB11_Lwr: DefaultClassColors.B,
|
|
96
|
+
BB16_Upr: DefaultClassColors.B,
|
|
97
|
+
BB16_Lwr: DefaultClassColors.B,
|
|
98
|
+
BB04_Upr: DefaultClassColors.B,
|
|
99
|
+
BB04_Lwr: DefaultClassColors.BII,
|
|
100
|
+
BB05_Upr: DefaultClassColors.B,
|
|
101
|
+
BB05_Lwr: DefaultClassColors.BII,
|
|
102
|
+
BB07_Upr: DefaultClassColors.BII,
|
|
103
|
+
BB07_Lwr: DefaultClassColors.BII,
|
|
104
|
+
BB08_Upr: DefaultClassColors.BII,
|
|
105
|
+
BB08_Lwr: DefaultClassColors.BII,
|
|
106
|
+
BB10_Upr: DefaultClassColors.miB,
|
|
107
|
+
BB10_Lwr: DefaultClassColors.miB,
|
|
108
|
+
BB12_Upr: DefaultClassColors.miB,
|
|
109
|
+
BB12_Lwr: DefaultClassColors.miB,
|
|
110
|
+
BB13_Upr: DefaultClassColors.miB,
|
|
111
|
+
BB13_Lwr: DefaultClassColors.miB,
|
|
112
|
+
BB14_Upr: DefaultClassColors.miB,
|
|
113
|
+
BB14_Lwr: DefaultClassColors.miB,
|
|
114
|
+
BB15_Upr: DefaultClassColors.miB,
|
|
115
|
+
BB15_Lwr: DefaultClassColors.miB,
|
|
116
|
+
BB20_Upr: DefaultClassColors.miB,
|
|
117
|
+
BB20_Lwr: DefaultClassColors.miB,
|
|
118
|
+
IC01_Upr: DefaultClassColors.IC,
|
|
119
|
+
IC01_Lwr: DefaultClassColors.IC,
|
|
120
|
+
IC02_Upr: DefaultClassColors.IC,
|
|
121
|
+
IC02_Lwr: DefaultClassColors.IC,
|
|
122
|
+
IC03_Upr: DefaultClassColors.IC,
|
|
123
|
+
IC03_Lwr: DefaultClassColors.IC,
|
|
124
|
+
IC04_Upr: DefaultClassColors.IC,
|
|
125
|
+
IC04_Lwr: DefaultClassColors.IC,
|
|
126
|
+
IC05_Upr: DefaultClassColors.IC,
|
|
127
|
+
IC05_Lwr: DefaultClassColors.IC,
|
|
128
|
+
IC06_Upr: DefaultClassColors.IC,
|
|
129
|
+
IC06_Lwr: DefaultClassColors.IC,
|
|
130
|
+
IC07_Upr: DefaultClassColors.IC,
|
|
131
|
+
IC07_Lwr: DefaultClassColors.IC,
|
|
132
|
+
OP01_Upr: DefaultClassColors.OPN,
|
|
133
|
+
OP01_Lwr: DefaultClassColors.OPN,
|
|
134
|
+
OP02_Upr: DefaultClassColors.OPN,
|
|
135
|
+
OP02_Lwr: DefaultClassColors.OPN,
|
|
136
|
+
OP03_Upr: DefaultClassColors.OPN,
|
|
137
|
+
OP03_Lwr: DefaultClassColors.OPN,
|
|
138
|
+
OP04_Upr: DefaultClassColors.OPN,
|
|
139
|
+
OP04_Lwr: DefaultClassColors.OPN,
|
|
140
|
+
OP05_Upr: DefaultClassColors.OPN,
|
|
141
|
+
OP05_Lwr: DefaultClassColors.OPN,
|
|
142
|
+
OP06_Upr: DefaultClassColors.OPN,
|
|
143
|
+
OP06_Lwr: DefaultClassColors.OPN,
|
|
144
|
+
OP07_Upr: DefaultClassColors.OPN,
|
|
145
|
+
OP07_Lwr: DefaultClassColors.OPN,
|
|
146
|
+
OP08_Upr: DefaultClassColors.OPN,
|
|
147
|
+
OP08_Lwr: DefaultClassColors.OPN,
|
|
148
|
+
OP09_Upr: DefaultClassColors.OPN,
|
|
149
|
+
OP09_Lwr: DefaultClassColors.OPN,
|
|
150
|
+
OP10_Upr: DefaultClassColors.OPN,
|
|
151
|
+
OP10_Lwr: DefaultClassColors.OPN,
|
|
152
|
+
OP11_Upr: DefaultClassColors.OPN,
|
|
153
|
+
OP11_Lwr: DefaultClassColors.OPN,
|
|
154
|
+
OP12_Upr: DefaultClassColors.OPN,
|
|
155
|
+
OP12_Lwr: DefaultClassColors.OPN,
|
|
156
|
+
OP13_Upr: DefaultClassColors.OPN,
|
|
157
|
+
OP13_Lwr: DefaultClassColors.OPN,
|
|
158
|
+
OP14_Upr: DefaultClassColors.OPN,
|
|
159
|
+
OP14_Lwr: DefaultClassColors.OPN,
|
|
160
|
+
OP15_Upr: DefaultClassColors.OPN,
|
|
161
|
+
OP15_Lwr: DefaultClassColors.OPN,
|
|
162
|
+
OP16_Upr: DefaultClassColors.OPN,
|
|
163
|
+
OP16_Lwr: DefaultClassColors.OPN,
|
|
164
|
+
OP17_Upr: DefaultClassColors.OPN,
|
|
165
|
+
OP17_Lwr: DefaultClassColors.OPN,
|
|
166
|
+
OP18_Upr: DefaultClassColors.OPN,
|
|
167
|
+
OP18_Lwr: DefaultClassColors.OPN,
|
|
168
|
+
OP19_Upr: DefaultClassColors.OPN,
|
|
169
|
+
OP19_Lwr: DefaultClassColors.OPN,
|
|
170
|
+
OP20_Upr: DefaultClassColors.OPN,
|
|
171
|
+
OP20_Lwr: DefaultClassColors.OPN,
|
|
172
|
+
OP21_Upr: DefaultClassColors.OPN,
|
|
173
|
+
OP21_Lwr: DefaultClassColors.OPN,
|
|
174
|
+
OP22_Upr: DefaultClassColors.OPN,
|
|
175
|
+
OP22_Lwr: DefaultClassColors.OPN,
|
|
176
|
+
OP23_Upr: DefaultClassColors.OPN,
|
|
177
|
+
OP23_Lwr: DefaultClassColors.OPN,
|
|
178
|
+
OP24_Upr: DefaultClassColors.OPN,
|
|
179
|
+
OP24_Lwr: DefaultClassColors.OPN,
|
|
180
|
+
OP25_Upr: DefaultClassColors.OPN,
|
|
181
|
+
OP25_Lwr: DefaultClassColors.OPN,
|
|
182
|
+
OP26_Upr: DefaultClassColors.OPN,
|
|
183
|
+
OP26_Lwr: DefaultClassColors.OPN,
|
|
184
|
+
OP27_Upr: DefaultClassColors.OPN,
|
|
185
|
+
OP27_Lwr: DefaultClassColors.OPN,
|
|
186
|
+
OP28_Upr: DefaultClassColors.OPN,
|
|
187
|
+
OP28_Lwr: DefaultClassColors.OPN,
|
|
188
|
+
OP29_Upr: DefaultClassColors.OPN,
|
|
189
|
+
OP29_Lwr: DefaultClassColors.OPN,
|
|
190
|
+
OP30_Upr: DefaultClassColors.OPN,
|
|
191
|
+
OP30_Lwr: DefaultClassColors.OPN,
|
|
192
|
+
OP31_Upr: DefaultClassColors.OPN,
|
|
193
|
+
OP31_Lwr: DefaultClassColors.OPN,
|
|
194
|
+
OPS1_Upr: DefaultClassColors.OPN,
|
|
195
|
+
OPS1_Lwr: DefaultClassColors.OPN,
|
|
196
|
+
OP1S_Upr: DefaultClassColors.OPN,
|
|
197
|
+
OP1S_Lwr: DefaultClassColors.SYN,
|
|
198
|
+
AAS1_Upr: DefaultClassColors.SYN,
|
|
199
|
+
AAS1_Lwr: DefaultClassColors.A,
|
|
200
|
+
AB1S_Upr: DefaultClassColors.A,
|
|
201
|
+
AB1S_Lwr: DefaultClassColors.SYN,
|
|
202
|
+
AB2S_Upr: DefaultClassColors.A,
|
|
203
|
+
AB2S_Lwr: DefaultClassColors.SYN,
|
|
204
|
+
BB1S_Upr: DefaultClassColors.B,
|
|
205
|
+
BB1S_Lwr: DefaultClassColors.SYN,
|
|
206
|
+
BB2S_Upr: DefaultClassColors.B,
|
|
207
|
+
BB2S_Lwr: DefaultClassColors.SYN,
|
|
208
|
+
BBS1_Upr: DefaultClassColors.SYN,
|
|
209
|
+
BBS1_Lwr: DefaultClassColors.B,
|
|
210
|
+
ZZ01_Upr: DefaultClassColors.Z,
|
|
211
|
+
ZZ01_Lwr: DefaultClassColors.Z,
|
|
212
|
+
ZZ02_Upr: DefaultClassColors.Z,
|
|
213
|
+
ZZ02_Lwr: DefaultClassColors.Z,
|
|
214
|
+
ZZ1S_Upr: DefaultClassColors.Z,
|
|
215
|
+
ZZ1S_Lwr: DefaultClassColors.SYN,
|
|
216
|
+
ZZ2S_Upr: DefaultClassColors.Z,
|
|
217
|
+
ZZ2S_Lwr: DefaultClassColors.SYN,
|
|
218
|
+
ZZS1_Upr: DefaultClassColors.SYN,
|
|
219
|
+
ZZS1_Lwr: DefaultClassColors.Z,
|
|
220
|
+
ZZS2_Upr: DefaultClassColors.SYN,
|
|
221
|
+
ZZS2_Lwr: DefaultClassColors.Z,
|
|
222
|
+
});
|
|
223
|
+
export var ConfalPyramidsColorThemeParams = {
|
|
224
|
+
colors: PD.MappedStatic('default', {
|
|
225
|
+
'default': PD.EmptyGroup(),
|
|
226
|
+
'custom': PD.Group(getColorMapParams(PyramidsColors))
|
|
227
|
+
}),
|
|
228
|
+
};
|
|
134
229
|
export function getConfalPyramidsColorThemeParams(ctx) {
|
|
135
|
-
return ConfalPyramidsColorThemeParams;
|
|
230
|
+
return PD.clone(ConfalPyramidsColorThemeParams);
|
|
136
231
|
}
|
|
137
232
|
export function ConfalPyramidsColorTheme(ctx, props) {
|
|
233
|
+
var colorMap = props.colors.name === 'default' ? PyramidsColors : props.colors.params;
|
|
138
234
|
function color(location, isSecondary) {
|
|
235
|
+
var _a;
|
|
139
236
|
if (CPT.isLocation(location)) {
|
|
140
|
-
var
|
|
141
|
-
|
|
237
|
+
var _b = location.data, pyramid = _b.pyramid, isLower = _b.isLower;
|
|
238
|
+
var key = pyramid.NtC + "_".concat(isLower ? 'Lwr' : 'Upr');
|
|
239
|
+
return (_a = colorMap[key]) !== null && _a !== void 0 ? _a : ErrorColor;
|
|
142
240
|
}
|
|
143
|
-
return
|
|
241
|
+
return ErrorColor;
|
|
144
242
|
}
|
|
145
243
|
return {
|
|
146
244
|
factory: ConfalPyramidsColorTheme,
|
|
@@ -148,13 +246,7 @@ export function ConfalPyramidsColorTheme(ctx, props) {
|
|
|
148
246
|
color: color,
|
|
149
247
|
props: props,
|
|
150
248
|
description: Description,
|
|
151
|
-
legend: TableLegend(
|
|
152
|
-
var conformer = _a[0], color = _a[1];
|
|
153
|
-
return [conformer, color];
|
|
154
|
-
}).concat([
|
|
155
|
-
['Error', ErrorColor],
|
|
156
|
-
['Unknown', DefaultColor]
|
|
157
|
-
]))
|
|
249
|
+
legend: TableLegend(ObjectKeys(colorMap).map(function (k) { return [k.replace('_', ' '), colorMap[k]]; }).concat([['Error', ErrorColor]])),
|
|
158
250
|
};
|
|
159
251
|
}
|
|
160
252
|
export var ConfalPyramidsColorThemeProvider = {
|
|
@@ -112,10 +112,8 @@ function createPyramidsFromCif(model, steps, stepsSummary) {
|
|
|
112
112
|
throw new Error('Inconsistent mmCIF data');
|
|
113
113
|
for (var i = 0; i < _rowCount; i++) {
|
|
114
114
|
var model_num = PDB_model_number.value(i);
|
|
115
|
-
if (model_num !== model.modelNum)
|
|
115
|
+
if (model_num !== model.modelNum)
|
|
116
116
|
hasMultipleModels = true;
|
|
117
|
-
continue; // We are only interested in data for the current model
|
|
118
|
-
}
|
|
119
117
|
var _a = getNtCAndConfalScore(id.value(i), i, stepsSummary), _NtC = _a._NtC, _confal_score = _a._confal_score;
|
|
120
118
|
var pyramid = {
|
|
121
119
|
PDB_model_number: model_num,
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { __extends } from "tslib";
|
|
8
8
|
import { ConfalPyramidsProvider } from './property';
|
|
9
|
-
import {
|
|
9
|
+
import { Segmentation } from '../../../mol-data/int';
|
|
10
10
|
import { Vec3 } from '../../../mol-math/linear-algebra';
|
|
11
11
|
import { StructureElement, StructureProperties } from '../../../mol-model/structure';
|
|
12
12
|
export var ConfalPyramidsUtil;
|
|
@@ -30,22 +30,17 @@ export var ConfalPyramidsUtil;
|
|
|
30
30
|
return prop.data.hasMultipleModels;
|
|
31
31
|
}
|
|
32
32
|
ConfalPyramidsUtil.hasMultipleModels = hasMultipleModels;
|
|
33
|
-
function
|
|
34
|
-
var loc = StructureElement.Location.create(structure, unit, -1);
|
|
35
|
-
var uIFirst = OrderedSet.indexOf(unit.elements, eIFirst);
|
|
36
|
-
var uILast = OrderedSet.indexOf(unit.elements, eILast);
|
|
33
|
+
function getPossibleAltIds(residue, structure, unit) {
|
|
37
34
|
var possibleAltIds = [];
|
|
38
|
-
|
|
39
|
-
|
|
35
|
+
var loc = StructureElement.Location.create(structure, unit, -1);
|
|
36
|
+
for (var rI = residue.start; rI <= residue.end - 1; rI++) {
|
|
37
|
+
loc.element = unit.elements[rI];
|
|
40
38
|
var altId = StructureProperties.atom.label_alt_id(loc);
|
|
41
39
|
if (altId !== '' && !possibleAltIds.includes(altId))
|
|
42
40
|
possibleAltIds.push(altId);
|
|
43
41
|
}
|
|
44
42
|
return possibleAltIds;
|
|
45
43
|
}
|
|
46
|
-
function getPossibleAltIdsResidue(residue, structure, unit) {
|
|
47
|
-
return getPossibleAltIdsIndices(unit.elements[residue.start], unit.elements[residue.end - 1], structure, unit);
|
|
48
|
-
}
|
|
49
44
|
var Utility = /** @class */ (function () {
|
|
50
45
|
function Utility(unit) {
|
|
51
46
|
var prop = ConfalPyramidsProvider.get(unit.model).value;
|
|
@@ -86,18 +81,22 @@ export var ConfalPyramidsUtil;
|
|
|
86
81
|
return _this;
|
|
87
82
|
}
|
|
88
83
|
UnitWalker.prototype.getAtomIndices = function (names, residue) {
|
|
89
|
-
var rI = residue.start;
|
|
90
|
-
var rILast = residue.end - 1;
|
|
91
84
|
var indices = [];
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
85
|
+
var loc = StructureElement.Location.create(this.structure, this.unit, -1);
|
|
86
|
+
for (var rI = residue.start; rI <= residue.end - 1; rI++) {
|
|
87
|
+
loc.element = this.unit.elements[rI];
|
|
95
88
|
var thisName = StructureProperties.atom.label_atom_id(loc);
|
|
96
89
|
if (names.includes(thisName))
|
|
97
|
-
indices.push(
|
|
90
|
+
indices.push(loc.element);
|
|
91
|
+
}
|
|
92
|
+
if (indices.length === 0) {
|
|
93
|
+
var namesStr = '';
|
|
94
|
+
for (var _i = 0, names_1 = names; _i < names_1.length; _i++) {
|
|
95
|
+
var n = names_1[_i];
|
|
96
|
+
namesStr += "".concat(n, " ");
|
|
97
|
+
}
|
|
98
|
+
throw new Error("Element [".concat(namesStr, "] not found on residue ").concat(residue.index));
|
|
98
99
|
}
|
|
99
|
-
if (indices.length === 0)
|
|
100
|
-
throw new Error("Element ".concat(name, " not found on residue ").concat(residue.index));
|
|
101
100
|
return indices;
|
|
102
101
|
};
|
|
103
102
|
UnitWalker.prototype.getAtomPositions = function (indices) {
|
|
@@ -201,10 +200,10 @@ export var ConfalPyramidsUtil;
|
|
|
201
200
|
return altPos;
|
|
202
201
|
};
|
|
203
202
|
UnitWalker.prototype.step = function (residue) {
|
|
204
|
-
var firstPossibleAltIds =
|
|
203
|
+
var firstPossibleAltIds = getPossibleAltIds(residue, this.structure, this.unit);
|
|
205
204
|
var firstAtoms = this.processFirstResidue(residue, firstPossibleAltIds);
|
|
206
205
|
residue = this.residueIt.move();
|
|
207
|
-
var secondPossibleAltIds =
|
|
206
|
+
var secondPossibleAltIds = getPossibleAltIds(residue, this.structure, this.unit);
|
|
208
207
|
var secondAtoms = this.processSecondResidue(residue, secondPossibleAltIds);
|
|
209
208
|
return { firstAtoms: firstAtoms, secondAtoms: secondAtoms };
|
|
210
209
|
};
|
|
@@ -48,8 +48,8 @@ export declare namespace Cylinders {
|
|
|
48
48
|
alpha: PD.Numeric;
|
|
49
49
|
quality: PD.Select<"auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest">;
|
|
50
50
|
material: PD.Group<PD.Normalize<{
|
|
51
|
-
metalness: number;
|
|
52
|
-
roughness: number;
|
|
51
|
+
metalness: number;
|
|
52
|
+
roughness: number; /** Number of cylinders */
|
|
53
53
|
bumpiness: number;
|
|
54
54
|
}>>;
|
|
55
55
|
clip: PD.Group<PD.Normalize<{
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright (c) 2021 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
2
|
+
* Copyright (c) 2021-2022 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
3
|
*
|
|
4
4
|
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
5
5
|
*/
|
|
@@ -13,12 +13,14 @@ export function calcMeshColorSmoothing(input, resolution, stride, webgl, texture
|
|
|
13
13
|
var colorType = input.colorType, vertexCount = input.vertexCount, groupCount = input.groupCount, positionBuffer = input.positionBuffer, transformBuffer = input.transformBuffer, groupBuffer = input.groupBuffer, itemSize = input.itemSize;
|
|
14
14
|
var isInstanceType = colorType.endsWith('Instance');
|
|
15
15
|
var box = Box3D.fromSphere3D(Box3D(), isInstanceType ? input.boundingSphere : input.invariantBoundingSphere);
|
|
16
|
+
var pad = 1 + resolution;
|
|
17
|
+
var expandedBox = Box3D.expand(Box3D(), box, Vec3.create(pad, pad, pad));
|
|
16
18
|
var scaleFactor = 1 / resolution;
|
|
17
|
-
var scaledBox = Box3D.scale(Box3D(),
|
|
19
|
+
var scaledBox = Box3D.scale(Box3D(), expandedBox, scaleFactor);
|
|
18
20
|
var gridDim = Box3D.size(Vec3(), scaledBox);
|
|
19
21
|
Vec3.ceil(gridDim, gridDim);
|
|
20
22
|
Vec3.add(gridDim, gridDim, Vec3.create(2, 2, 2));
|
|
21
|
-
var min =
|
|
23
|
+
var min = expandedBox.min;
|
|
22
24
|
var xn = gridDim[0], yn = gridDim[1];
|
|
23
25
|
var _a = getVolumeTexture2dLayout(gridDim), width = _a.width, height = _a.height;
|
|
24
26
|
// console.log({ width, height, dim });
|
|
@@ -43,7 +43,7 @@ export declare namespace Points {
|
|
|
43
43
|
quality: PD.Select<"auto" | "medium" | "high" | "low" | "custom" | "highest" | "higher" | "lower" | "lowest">;
|
|
44
44
|
material: PD.Group<PD.Normalize<{
|
|
45
45
|
metalness: number;
|
|
46
|
-
roughness: number;
|
|
46
|
+
roughness: number; /** Number of vertices in the point cloud */
|
|
47
47
|
bumpiness: number;
|
|
48
48
|
}>>;
|
|
49
49
|
clip: PD.Group<PD.Normalize<{
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright (c) 2021 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
2
|
+
* Copyright (c) 2021-2022 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
3
|
*
|
|
4
4
|
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
5
5
|
*/
|
|
@@ -188,12 +188,14 @@ export function calcTextureMeshColorSmoothing(input, resolution, stride, webgl,
|
|
|
188
188
|
var gl = webgl.gl, resources = webgl.resources, state = webgl.state, _a = webgl.extensions, colorBufferHalfFloat = _a.colorBufferHalfFloat, textureHalfFloat = _a.textureHalfFloat;
|
|
189
189
|
var isInstanceType = input.colorType.endsWith('Instance');
|
|
190
190
|
var box = Box3D.fromSphere3D(Box3D(), isInstanceType ? input.boundingSphere : input.invariantBoundingSphere);
|
|
191
|
+
var pad = 1 + resolution;
|
|
192
|
+
var expandedBox = Box3D.expand(Box3D(), box, Vec3.create(pad, pad, pad));
|
|
191
193
|
var scaleFactor = 1 / resolution;
|
|
192
|
-
var scaledBox = Box3D.scale(Box3D(),
|
|
194
|
+
var scaledBox = Box3D.scale(Box3D(), expandedBox, scaleFactor);
|
|
193
195
|
var gridDim = Box3D.size(Vec3(), scaledBox);
|
|
194
196
|
Vec3.ceil(gridDim, gridDim);
|
|
195
197
|
Vec3.add(gridDim, gridDim, Vec3.create(2, 2, 2));
|
|
196
|
-
var min =
|
|
198
|
+
var min = expandedBox.min;
|
|
197
199
|
var dx = gridDim[0], dy = gridDim[1], dz = gridDim[2];
|
|
198
200
|
var _b = getTexture2dSize(gridDim), width = _b.texDimX, height = _b.texDimY, texCols = _b.texCols;
|
|
199
201
|
// console.log({ width, height, texCols, dim, resolution });
|
|
@@ -227,7 +229,7 @@ export function calcTextureMeshColorSmoothing(input, resolution, stride, webgl,
|
|
|
227
229
|
countTexture.define(width, height);
|
|
228
230
|
accumulateTexture.attachFramebuffer(framebuffer, 0);
|
|
229
231
|
countTexture.attachFramebuffer(framebuffer, 1);
|
|
230
|
-
var accumulateRenderable = getAccumulateRenderable(webgl, input,
|
|
232
|
+
var accumulateRenderable = getAccumulateRenderable(webgl, input, expandedBox, resolution, stride);
|
|
231
233
|
state.currentRenderItemId = -1;
|
|
232
234
|
framebuffer.bind();
|
|
233
235
|
drawBuffers.drawBuffers([
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright (c) 2018-
|
|
2
|
+
* Copyright (c) 2018-2022 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
3
|
*
|
|
4
4
|
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
5
5
|
*/
|
|
@@ -226,7 +226,7 @@ export function createContext(gl, props) {
|
|
|
226
226
|
gl: gl,
|
|
227
227
|
isWebGL2: isWebGL2(gl),
|
|
228
228
|
get pixelRatio() {
|
|
229
|
-
var dpr = (typeof window !== 'undefined') ? window.devicePixelRatio : 1;
|
|
229
|
+
var dpr = (typeof window !== 'undefined') ? (window.devicePixelRatio || 1) : 1;
|
|
230
230
|
return dpr * (props.pixelScale || 1);
|
|
231
231
|
},
|
|
232
232
|
extensions: extensions,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright (c) 2018-
|
|
2
|
+
* Copyright (c) 2018-2022 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
3
|
*
|
|
4
4
|
* @author David Sehnal <david.sehnal@gmail.com>
|
|
5
5
|
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
@@ -24,6 +24,7 @@ export declare type DensityData = {
|
|
|
24
24
|
field: Tensor;
|
|
25
25
|
idField: Tensor;
|
|
26
26
|
resolution: number;
|
|
27
|
+
maxRadius: number;
|
|
27
28
|
};
|
|
28
29
|
export declare type DensityTextureData = {
|
|
29
30
|
transform: Mat4;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Copyright (c) 2018-
|
|
2
|
+
* Copyright (c) 2018-2022 mol* contributors, licensed under MIT, See LICENSE file for more info.
|
|
3
3
|
*
|
|
4
4
|
* @author David Sehnal <david.sehnal@gmail.com>
|
|
5
5
|
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|