Issue #198: Anti-aliasing of hitCanvas breaks getIntersection

Remember the last shape, and use it if the current shape is undefined
while calculating the intersection.