mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2024-12-29 09:22:22 -05:00
8fb7c41537
Relates to #634, closes #582
14 lines
388 B
JavaScript
14 lines
388 B
JavaScript
importScripts('../../dist/paper-full.js');
|
|
paper.install(this);
|
|
paper.setup([640, 480]);
|
|
|
|
onmessage = function(event) {
|
|
var data = event.data;
|
|
if (data) {
|
|
var path1 = project.importJSON(data[0]);
|
|
var path2 = project.importJSON(data[1]);
|
|
console.log(path1, path2);
|
|
var result = path1.unite(path2);
|
|
postMessage(result.exportJSON());
|
|
}
|
|
};
|