Skip to content

Commit 0f86036

Browse files
authored
Merge pull request #4344 from plotly/surface-cut-noOpacity
remove noOpacity flag from surface index
2 parents 7665753 + 0dd8748 commit 0f86036

File tree

3 files changed

+176
-1
lines changed

3 files changed

+176
-1
lines changed

src/traces/surface/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ module.exports = {
2121
moduleType: 'trace',
2222
name: 'surface',
2323
basePlotModule: require('../../plots/gl3d'),
24-
categories: ['gl3d', '2dMap', 'noOpacity'],
24+
categories: ['gl3d', '2dMap'],
2525
meta: {
2626
description: [
2727
'The data the describes the coordinates of the surface is set in `z`.',
Loading
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,175 @@
1+
{
2+
"data": [{
3+
"x": [-1, 0, 1],
4+
"y": [-1, 0, 1],
5+
"z": [
6+
[0, 1, 0],
7+
[1, 0, 1],
8+
[0, 1, 0]
9+
],
10+
"lightposition": { "x": 1000, "y": 1000, "z": 0 },
11+
"opacity": 1,
12+
"colorscale": [[0, "#FF0"], [1, "#FF0"]],
13+
"showscale": false,
14+
"type": "surface",
15+
"name": "surface",
16+
"scene": "scene1"
17+
}, {
18+
"x": [0, 1, 0, 1, 0, 1, 0, 1],
19+
"y": [0, 0, 1, 1, 0, 0, 1, 1],
20+
"z": [0, 0, 0, 0, 1, 1, 1, 1],
21+
"i": [0, 3, 4, 7, 0, 6, 1, 7, 0, 5, 2, 7],
22+
"j": [1, 2, 5, 6, 2, 4, 3, 5, 4, 1, 6, 3],
23+
"k": [3, 0, 7, 4, 6, 0, 7, 1, 5, 0, 7, 2],
24+
"flatshading": true,
25+
"lightposition": { "x": 1000, "y": 1000, "z": 0 },
26+
"opacity": 1,
27+
"color": "#FF0",
28+
"type": "mesh3d",
29+
"name": "mesh3d",
30+
"scene": "scene2"
31+
}, {
32+
"x": [-1, 0, 1],
33+
"y": [-1, 0, 1],
34+
"z": [
35+
[0, 1, 0],
36+
[1, 0, 1],
37+
[0, 1, 0]
38+
],
39+
"lightposition": { "x": 1000, "y": 1000, "z": 0 },
40+
"opacity": 0.5,
41+
"showscale": false,
42+
"type": "surface",
43+
"name": "surface",
44+
"scene": "scene3"
45+
}, {
46+
"x": [0, 1, 0, 1, 0, 1, 0, 1],
47+
"y": [0, 0, 1, 1, 0, 0, 1, 1],
48+
"z": [0, 0, 0, 0, 1, 1, 1, 1],
49+
"i": [0, 3, 4, 7, 0, 6, 1, 7, 0, 5, 2, 7],
50+
"j": [1, 2, 5, 6, 2, 4, 3, 5, 4, 1, 6, 3],
51+
"k": [3, 0, 7, 4, 6, 0, 7, 1, 5, 0, 7, 2],
52+
"flatshading": true,
53+
"lightposition": { "x": 1000, "y": 1000, "z": 0 },
54+
"opacity": 0.5,
55+
"type": "mesh3d",
56+
"name": "mesh3d",
57+
"scene": "scene4"
58+
}, {
59+
"x": [0, 0, 1, 1, 0, 0, 1, 1],
60+
"y": [0, 1, 1, 0, 0, 1, 1, 0],
61+
"z": [0, 0, 0, 0, 1, 1, 1, 1],
62+
"u": [0, 0, 1, 1, 0, 0, 1, 1],
63+
"v": [0, 1, 1, 0, 0, 1, 1, 0],
64+
"w": [0, 0, 0, 0, 1, 1, 1, 1],
65+
"lightposition": { "x": 1000, "y": 1000, "z": 0 },
66+
"opacity": 0.5,
67+
"showscale": false,
68+
"type": "cone",
69+
"name": "cone",
70+
"scene": "scene5"
71+
}, {
72+
"x": [0, 0, 1, 1, 0, 0, 1, 1],
73+
"y": [0, 1, 1, 0, 0, 1, 1, 0],
74+
"z": [0, 0, 0, 0, 1, 1, 1, 1],
75+
"u": [0, 0, 1, 1, 0, 0, 1, 1],
76+
"v": [0, 1, 1, 0, 0, 1, 1, 0],
77+
"w": [0, 0, 0, 0, 1, 1, 1, 1],
78+
"lightposition": { "x": 1000, "y": 1000, "z": 0 },
79+
"opacity": 0.5,
80+
"showscale": false,
81+
"type": "streamtube",
82+
"name": "streamtube",
83+
"scene": "scene6"
84+
}, {
85+
"x": [0, 0, 0, 0, 1, 1, 1, 1],
86+
"y": [0, 0, 1, 1, 0, 0, 1, 1],
87+
"z": [0, 1, 0, 1, 0, 1, 0, 1],
88+
"value": [0, 0, 0, 1, 1, 0, 0, 0],
89+
"lightposition": { "x": 1000, "y": 1000, "z": 0 },
90+
"opacity": 0.5,
91+
"showscale": false,
92+
"type": "isosurface",
93+
"name": "isosurface",
94+
"scene": "scene7"
95+
}, {
96+
"x": [0, 0, 0, 0, 1, 1, 1, 1],
97+
"y": [0, 0, 1, 1, 0, 0, 1, 1],
98+
"z": [0, 1, 0, 1, 0, 1, 0, 1],
99+
"value": [0, 0, 0, 1, 1, 0, 0, 0],
100+
"lightposition": { "x": 1000, "y": 1000, "z": 0 },
101+
"opacityscale": "max",
102+
"opacity": 0.5,
103+
"showscale": false,
104+
"type": "volume",
105+
"name": "volume",
106+
"scene": "scene8"
107+
}],
108+
"layout": {
109+
"paper_bgcolor": "rgba(0,0,255, 0.5)",
110+
"margin": {
111+
"t": 0,
112+
"b": 0,
113+
"l": 0,
114+
"r": 0
115+
},
116+
"width": 1000,
117+
"height": 500,
118+
"scene1": {
119+
"domain": {
120+
"x": [0, 0.25],
121+
"y": [0, 0.5]
122+
},
123+
"camera": { "eye": { "x": 1.5, "y": 3, "z": 1 } }
124+
},
125+
"scene2": {
126+
"domain": {
127+
"x": [0, 0.25],
128+
"y": [0.5, 1]
129+
},
130+
"camera": { "eye": { "x": 1.5, "y": 3, "z": 1 } }
131+
},
132+
"scene3": {
133+
"domain": {
134+
"x": [0.25, 0.5],
135+
"y": [0, 0.5]
136+
},
137+
"camera": { "eye": { "x": 1.5, "y": 3, "z": 1 } }
138+
},
139+
"scene4": {
140+
"domain": {
141+
"x": [0.25, 0.5],
142+
"y": [0.5, 1]
143+
},
144+
"camera": { "eye": { "x": 1.5, "y": 3, "z": 1 } }
145+
},
146+
"scene5": {
147+
"domain": {
148+
"x": [0.5, 0.75],
149+
"y": [0, 0.5]
150+
},
151+
"camera": { "eye": { "x": 1.5, "y": 3, "z": 1 } }
152+
},
153+
"scene6": {
154+
"domain": {
155+
"x": [0.5, 0.75],
156+
"y": [0.5, 1]
157+
},
158+
"camera": { "eye": { "x": 1.5, "y": 3, "z": 1 } }
159+
},
160+
"scene7": {
161+
"domain": {
162+
"x": [0.75, 1],
163+
"y": [0, 0.5]
164+
},
165+
"camera": { "eye": { "x": 1.5, "y": 3, "z": 1 } }
166+
},
167+
"scene8": {
168+
"domain": {
169+
"x": [0.75, 1],
170+
"y": [0.5, 1]
171+
},
172+
"camera": { "eye": { "x": 1.5, "y": 3, "z": 1 } }
173+
}
174+
}
175+
}

0 commit comments

Comments
 (0)