An Objective-C port of Epolys.js