paper.js/examples/Node.js/Tadpoles.js
Jürg Lehni e232ebc443 Examples: Move away from using a symlink to be able to require('paper') from within examples.
- Node 5 / NPM 3 struggles with it
- It never worked on Windows
2016-01-31 12:43:38 +01:00

16 lines
532 B
JavaScript

// Please note: When loading paper as a normal module installed in node_modules,
// you would use this instead:
// var paper = require('paper');
var paper = require('../../dist/paper-full.js');
var scope = require('./Tadpoles.pjs')(new paper.Size(1024, 768));
scope.view.exportFrames({
amount: 400,
directory: __dirname,
onComplete: function() {
console.log('Done exporting.');
},
onProgress: function(event) {
console.log(event.percentage + '% complete, frame took: ' + event.delta);
}
});