Skip to content

Commit 2fc27f1

Browse files
committed
Set a different default light position for surface vs mesh
1 parent 651bbc7 commit 2fc27f1

14 files changed

+6
-2
lines changed

src/traces/mesh3d/attributes.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,11 @@ module.exports = {
124124
reversescale: colorscaleAttrs.reversescale,
125125
showscale: colorscaleAttrs.showscale,
126126

127-
lightposition: extendFlat({}, surfaceAtts.lightposition),
127+
lightposition: {
128+
'x': extendFlat({}, surfaceAtts.lightposition.x, {dflt: 1e5}),
129+
'y': extendFlat({}, surfaceAtts.lightposition.y, {dflt: 1e5}),
130+
'z': extendFlat({}, surfaceAtts.lightposition.z, {dflt: 0})
131+
},
128132
lighting: extendFlat({
129133
vertexnormalsepsilon: {
130134
valType: 'number',

src/traces/surface/attributes.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ module.exports = {
153153
role: 'style',
154154
min: -1e5,
155155
max: 1e5,
156-
dflt: 1e5,
156+
dflt: 10,
157157
description: 'Numeric vector, representing the X coordinate for each vertex.'
158158
},
159159
y: {
90 Bytes
Loading
2 Bytes
Loading
-5 Bytes
Loading
-42 Bytes
Loading
181 Bytes
Loading
-121 Bytes
Loading
387 Bytes
Loading
22 Bytes
Loading

0 commit comments

Comments
 (0)