Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4e4deb2

Browse files
authored
Merge pull request plotly#1415 from plotly/gl3d-surface-opacity
Fix gl3d surface opacity scaling
2 parents 9ebefd7 + bf939bc commit 4e4deb2

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

src/traces/surface/convert.js

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ proto.update = function(data) {
262262
dynamicColor: [[1, 1, 1, 1], [1, 1, 1, 1], [1, 1, 1, 1]],
263263
dynamicWidth: [1, 1, 1],
264264
dynamicTint: [1, 1, 1],
265-
opacity: 1
265+
opacity: data.opacity
266266
};
267267

268268
params.intensityBounds = [data.cmin, data.cmax];
@@ -290,12 +290,6 @@ proto.update = function(data) {
290290
params.intensity = coords.pop();
291291
}
292292

293-
if('opacity' in data) {
294-
if(data.opacity < 1) {
295-
params.opacity = 0.25 * data.opacity;
296-
}
297-
}
298-
299293
var highlightEnable = [true, true, true];
300294
var axis = ['x', 'y', 'z'];
301295

14.9 KB
Loading

0 commit comments

Comments
 (0)