Skip to content

Commit 012830b

Browse files
committed
unify mesh3d lighting with surface
1 parent 70b2d6c commit 012830b

File tree

6 files changed

+118
-0
lines changed

6 files changed

+118
-0
lines changed
-1.72 KB
Loading
-365 Bytes
Loading
727 Bytes
Loading
867 Bytes
Loading
-204 Bytes
Loading
Lines changed: 118 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
{
2+
"data": [
3+
{
4+
"x": [0, 0, 0, 1, 1, 1, 2, 2, 2],
5+
"y": [100, 101, 102, 100, 101, 102, 100, 101, 102],
6+
"z": [1, 1, 1, 1, 2, 2, 1, 3, 5],
7+
"type": "mesh3d",
8+
"color": "grey",
9+
"lighting": { "ambient": 0.25, "diffuse": 0.75, "specular": 0.5, "roughness": 0.25, "fresnel": 0.25 },
10+
"lightposition": { "x": 0, "y": 2000, "z": 1000 }
11+
},
12+
{
13+
"x": [0, 0, 0, 1, 1, 1, 2, 2, 2],
14+
"y": [100, 99, 98, 100, 99, 98, 100, 99, 98],
15+
"z": [1, 1, 1, 1, 2, 2, 1, 3, 5],
16+
"type": "mesh3d",
17+
"color": "grey",
18+
"lighting": { "ambient": 0.25, "diffuse": 0.75, "specular": 0.5, "roughness": 0.25, "fresnel": 0.25 },
19+
"lightposition": { "x": 0, "y": 2000, "z": 1000 }
20+
},
21+
{
22+
"x": [0, 0, 0, -1, -1, -1, -2, -2, -2],
23+
"y": [100, 99, 98, 100, 99, 98, 100, 99, 98],
24+
"z": [1, 1, 1, 1, 2, 2, 1, 3, 5],
25+
"type": "mesh3d",
26+
"color": "grey",
27+
"lighting": { "ambient": 0.25, "diffuse": 0.75, "specular": 0.5, "roughness": 0.25, "fresnel": 0.25 },
28+
"lightposition": { "x": 0, "y": 2000, "z": 1000 }
29+
},
30+
{
31+
"x": [0, 0, 0, -1, -1, -1, -2, -2, -2],
32+
"y": [100, 101, 102, 100, 101, 102, 100, 101, 102],
33+
"z": [1, 1, 1, 1, 2, 2, 1, 3, 5],
34+
"type": "mesh3d",
35+
"color": "grey",
36+
"lighting": { "ambient": 0.25, "diffuse": 0.75, "specular": 0.5, "roughness": 0.25, "fresnel": 0.25 },
37+
"lightposition": { "x": 0, "y": 2000, "z": 1000 }
38+
},
39+
{
40+
"x": [0, 1, 2],
41+
"y": [100, 101, 102],
42+
"z": [
43+
[0, 0, 0],
44+
[0, 1, 1],
45+
[0, 2, 4]
46+
],
47+
"type": "surface",
48+
"colorscale": [[0, "grey"], [1, "grey"]],
49+
"showscale": false,
50+
"lighting": { "ambient": 0.25, "diffuse": 0.75, "specular": 0.5, "roughness": 0.25, "fresnel": 0.25 },
51+
"lightposition": { "x": 0, "y": 2000, "z": 1000 }
52+
},
53+
{
54+
"x": [0, 1, 2],
55+
"y": [100, 99, 98],
56+
"z": [
57+
[0, 0, 0],
58+
[0, 1, 1],
59+
[0, 2, 4]
60+
],
61+
"type": "surface",
62+
"colorscale": [[0, "grey"], [1, "grey"]],
63+
"showscale": false,
64+
"lighting": { "ambient": 0.25, "diffuse": 0.75, "specular": 0.5, "roughness": 0.25, "fresnel": 0.25 },
65+
"lightposition": { "x": 0, "y": 2000, "z": 1000 }
66+
},
67+
{
68+
"x": [0, -1, -2],
69+
"y": [100, 99, 98],
70+
"z": [
71+
[0, 0, 0],
72+
[0, 1, 1],
73+
[0, 2, 4]
74+
],
75+
"type": "surface",
76+
"colorscale": [[0, "grey"], [1, "grey"]],
77+
"showscale": false,
78+
"lighting": { "ambient": 0.25, "diffuse": 0.75, "specular": 0.5, "roughness": 0.25, "fresnel": 0.25 },
79+
"lightposition": { "x": 0, "y": 2000, "z": 1000 }
80+
},
81+
{
82+
"x": [0, -1, -2],
83+
"y": [100, 101, 102],
84+
"z": [
85+
[0, 0, 0],
86+
[0, 1, 1],
87+
[0, 2, 4]
88+
],
89+
"type": "surface",
90+
"colorscale": [[0, "grey"], [1, "grey"]],
91+
"showscale": false,
92+
"lighting": { "ambient": 0.25, "diffuse": 0.75, "specular": 0.5, "roughness": 0.25, "fresnel": 0.25 },
93+
"lightposition": { "x": 0, "y": 2000, "z": 1000 }
94+
}
95+
],
96+
"layout": {
97+
"height": 800,
98+
"width": 800,
99+
"title": {
100+
"text": "Mesh3d and surface lighting"
101+
},
102+
"scene": {
103+
"xaxis": {
104+
},
105+
"yaxis": {
106+
},
107+
"zaxis": {
108+
},
109+
"camera": {
110+
"eye": {
111+
"x": 1.5,
112+
"y": -1.5,
113+
"z": 0.5
114+
}
115+
}
116+
}
117+
}
118+
}

0 commit comments

Comments
 (0)