Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Volume - new gl3d trace #3488

Merged
merged 48 commits into from
Apr 8, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
3a39fd8
adding volume4d new trace
archmoj Jan 28, 2019
e3a59da
opacityscale as 2d array
archmoj Jan 28, 2019
c138d9d
correct volume baselines
archmoj Jan 28, 2019
5dbe037
volume4d > volume
archmoj Jan 29, 2019
f141868
new baselines
archmoj Jan 29, 2019
b1170a9
add multi trace mock and add it to mock list
archmoj Jan 30, 2019
1a49fa2
baseline for multiple volume traces
archmoj Jan 30, 2019
e0b786c
revised the colorscale of datacube mock
archmoj Jan 31, 2019
76dae20
updated baseline with revised colorscale
archmoj Jan 31, 2019
fb502bd
bring isosurface draws to front and added a mock with mri data
archmoj Feb 4, 2019
c74daad
enter mri data
archmoj Feb 4, 2019
ea92715
revised mri mock
archmoj Feb 4, 2019
b07aa6a
fixup test
archmoj Feb 4, 2019
48909e0
using new shader and mock with two volume traces in one cube
archmoj Feb 5, 2019
02f171f
correct baseline using new shader
archmoj Feb 5, 2019
3b7320f
added new baseline
archmoj Feb 5, 2019
1ec0941
mock and baseline changes
archmoj Feb 5, 2019
51035f9
exclude mri to run on CI
archmoj Feb 5, 2019
7a13bde
removed mri baseline
archmoj Feb 6, 2019
7249f8f
new volume mock with aspect ratio and opacityscale
archmoj Feb 6, 2019
601baaa
added a draft baseline for new mock
archmoj Feb 6, 2019
3580015
disable more volume mocks to run CI
archmoj Feb 6, 2019
2052e9b
correct baseline
archmoj Feb 6, 2019
3c0dc06
settings to speedup mesh normal calc
archmoj Feb 7, 2019
04aa645
correct baselines using flatshading nomalization algo and try mri to …
archmoj Feb 7, 2019
dce3209
removed mri mock to run CI
archmoj Feb 7, 2019
fe9968e
dont run gl3d_volume_between-ranges to run on CI
archmoj Feb 7, 2019
9681682
resolved conflicts and revised code based on comments
archmoj Feb 20, 2019
1bb5ade
tweak image test to run for volume only
archmoj Feb 20, 2019
94bfc50
fixed filter condition for image test
archmoj Feb 20, 2019
4542518
rm mri mock
archmoj Mar 6, 2019
c2a703f
Merge branch 'master' into volume-dev
archmoj Mar 6, 2019
3511f6c
dont run volume mocks on ci
archmoj Mar 6, 2019
401e390
Merge remote-tracking branch 'origin/master'
archmoj Mar 28, 2019
913c6e6
reduce opacityscale and move to volume folder - pass 1
archmoj Mar 29, 2019
64652f9
revised min opacity in palettes
archmoj Mar 29, 2019
e82a826
reduced opacityscale code - updated baseline - revised jasmine test
archmoj Mar 29, 2019
320485f
add hovertext support
archmoj Mar 29, 2019
5da5cd7
Merge remote-tracking branch 'origin/master' into volume4d to apply n…
archmoj Mar 29, 2019
d35f69a
Merge remote-tracking branch 'origin/master' into volume4d
archmoj Apr 2, 2019
e6b0efd
run volume image test on CI
archmoj Apr 2, 2019
0aa25f0
reset batch wait to 500
archmoj Apr 3, 2019
77f7317
fixup volume default to coerce volume attributes and dflt - switch pr…
archmoj Apr 3, 2019
af17adc
revised isosurface default function exports
archmoj Apr 3, 2019
130da2f
add volume and isosurface to the gl3d partial bundle list
archmoj Apr 3, 2019
01a9426
revert unwanted scattergl changes in the previous commit
archmoj Apr 3, 2019
e23b2c3
reduced volume mock data
archmoj Apr 5, 2019
4a9987d
bump gl-mesh3d 2.1.0
archmoj Apr 8, 2019
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ Plotly.register([
require('./scatter3d'),
require('./surface'),
require('./isosurface'),
require('./volume4d'),
etpinard marked this conversation as resolved.
Show resolved Hide resolved
require('./mesh3d'),
require('./cone'),
require('./streamtube'),
Expand Down
11 changes: 11 additions & 0 deletions lib/volume4d.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/**
* Copyright 2012-2019, Plotly, Inc.
* All rights reserved.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/

'use strict';

module.exports = require('../src/traces/volume4d');
5 changes: 2 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
"gl-heatmap2d": "^1.0.5",
"gl-line3d": "^1.1.8",
"gl-mat4": "^1.2.0",
"gl-mesh3d": "^2.0.7",
"gl-mesh3d": "git://github.com/gl-vis/gl-mesh3d.git#a361fdeae2fcaeed52efe05906f212e4b7c7bafa",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"gl-plot2d": "^1.4.2",
"gl-plot3d": "^1.6.3",
"gl-pointcloud2d": "^1.0.2",
Expand Down
2 changes: 1 addition & 1 deletion src/plots/gl3d/scene.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ function render(scene) {
vectorTx.push(selection.textLabel);
}
tx = vectorTx.join('<br>');
} else if(trace.type === 'isosurface') {
} else if(trace.type === 'isosurface' || trace.type === 'volume4d') {
vectorTx.push('value: ' + Axes.tickText(scene.mockAxis, scene.mockAxis.d2l(selection.traceCoordinate[3]), 'hover').text);
if(selection.textLabel) {
vectorTx.push(selection.textLabel);
Expand Down
35 changes: 10 additions & 25 deletions src/traces/isosurface/attributes.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@

var colorscaleAttrs = require('../../components/colorscale/attributes');
var colorbarAttrs = require('../../components/colorbar/attributes');
var surfaceAtts = require('../surface/attributes');
var meshAttrs = require('../mesh3d/attributes');
var baseAttrs = require('../../plots/attributes');

Expand Down Expand Up @@ -225,7 +224,7 @@ var attrs = module.exports = overrideAll(extendFlat({
'If trace `hoverinfo` contains a *text* flag and *hovertext* is not set,',
'these elements will be seen in the hover labels.'
].join(' ')
},
}
},

colorscaleAttrs('', {
Expand All @@ -236,34 +235,20 @@ colorscaleAttrs('', {

colorbar: colorbarAttrs,

// Flat shaded mode
flatshading: {
valType: 'boolean',
role: 'style',
opacityscale: {
valType: 'enumerated',
values: ['min', 'max', 'extremes', 'center'],
etpinard marked this conversation as resolved.
Show resolved Hide resolved
dflt: false,
role: 'style',
description: [
'Determines whether or not normal smoothing is applied to the isosurfaces,',
'creating isosurfaces with an angular, low-poly look via flat reflections.'
'Enables non-uniform opacity scales between minimum and maximum ranges of `value`.'
].join(' ')
},

contour: {
show: extendFlat({}, surfaceAtts.contours.x.show, {
description: [
'Sets whether or not dynamic contours are shown on hover.',
'Contours are more useful when hovering on caps and slices.'
].join(' ')
}),
color: surfaceAtts.contours.x.color,
width: surfaceAtts.contours.x.width
},

lightposition: {
x: extendFlat({}, surfaceAtts.lightposition.x, {dflt: 1e5}),
y: extendFlat({}, surfaceAtts.lightposition.y, {dflt: 1e5}),
z: extendFlat({}, surfaceAtts.lightposition.z, {dflt: 0})
},
opacity: meshAttrs.opacity,
lightposition: meshAttrs.lightposition,
lighting: meshAttrs.lighting,
flatshading: meshAttrs.flatshading,
contour: meshAttrs.contour,

hoverinfo: extendFlat({}, baseAttrs.hoverinfo)
}), 'calc', 'nested');
Expand Down
Loading