Skip to content

Commit 0efb54e

Browse files
committed
Detect blending dynamically
1 parent 973d6ec commit 0efb54e

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

src/traces/pointcloud/attributes.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ module.exports = {
7575
},
7676
blend: {
7777
valType: 'boolean',
78-
dflt: false,
78+
dflt: undefined,
7979
role: 'style',
8080
description: [
8181
'Determines if colors are blended together for a translucency effect',

src/traces/pointcloud/convert.js

+6-1
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,12 @@ proto.updateFast = function(options) {
174174

175175
markerColor[3] *= opacity;
176176
this.pointcloudOptions.color = markerColor;
177-
this.pointcloudOptions.blend = options.marker.blend;
177+
178+
var blend = options.marker.blend;
179+
if (blend == null) {
180+
blend = x.length < 100 || y.length < 100;
181+
}
182+
this.pointcloudOptions.blend = blend;
178183

179184
borderColor[3] *= opacity;
180185
this.pointcloudOptions.borderColor = borderColor;

0 commit comments

Comments
 (0)