Skip to content

Commit

Permalink
Merge pull request #3 from gl-vis/autoscale
Browse files Browse the repository at this point in the history
Autoscale [fix #2]
  • Loading branch information
kig authored May 29, 2018
2 parents f308a12 + 608a531 commit 97c89d7
Show file tree
Hide file tree
Showing 6 changed files with 287 additions and 161 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ var bounds = [];
var streamTube = createStreamTube({
startingPositions: positionsArray,
maxLength: 1000,
widthScale: 10000,
getVelocity: velocityFunction,
colormap: 'portland'
}, bounds)
Expand Down Expand Up @@ -48,7 +47,8 @@ Creates a stream tube plot of a vector field.
+ `getVelocity(point)` *(Required)* A getter function to get the velocity at a given point.
+ `getDivergence(point)` *(Optional)* A getter function to get the divergence at a given point. Used for the width of the streamtube. Defaults to the divergence of the getVelocity function.
+ `maxLength` *(Optional)* The maximum number of segments to add to a streamtube. Default is 1000.
+ `widthScale` *(Optional)* The divergence multiplier to get the width of the streamtube. Default is 10000.
+ `tubeSize` *(Optional)* The scaling factor for the streamtubes. The default is 1, which avoids two max divergence tubes from touching at adjacent starting positions.
+ `absoluteTubeSize` *(Optional)* Absolute scaling factor for the streamtubes. A value of 1 scales divergence of 1 to 1 coordinate system unit. Overrides tubeSize.
+ `colormap` *(Optional)* The colormap to use.

**Returns** A streamtube plot object that can be passed to gl-mesh3d.
Expand Down
Loading

0 comments on commit 97c89d7

Please sign in to comment.