Flipbook animation based on paper.js