Skip to content

Commit

Permalink
glsl plugin for rollup
Browse files Browse the repository at this point in the history
  • Loading branch information
gouldingken committed Oct 24, 2016
1 parent a399b42 commit 2292d05
Show file tree
Hide file tree
Showing 8 changed files with 76 additions and 27 deletions.
21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,23 @@
# animated-points
A GPU animated point cloud for three.js suitable for tweening large numbers of points

##Installation
`npm install --save animated-points`

##Usage
```Javascript
import AnimatedPoints from "animated-points";

//load the records (typically from a file or API call)
var records = [{type:'A', age:23},{type:'B', age:24}];

//create a new instance of AnimatedPoints passing in the total number of records (this must be declared up front and cannot be changed)
var animatedPoints = new AnimatedPoints(records.length);
animatedPoints.setProperties(_getPositions1(records));

//to animate to the next state, calculate a different set of positions for the data. Using a 2 seond delay as an example.
setTimeout(function() {
animatedPoints.setProperties(_getPositions2(records));
}, 2000);

```
21 changes: 11 additions & 10 deletions dist/animated-points.es.js

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

2 changes: 1 addition & 1 deletion dist/animated-points.es.js.map

Large diffs are not rendered by default.

24 changes: 13 additions & 11 deletions dist/animated-points.js

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

Loading

0 comments on commit 2292d05

Please sign in to comment.