Parameterize sanityThreshold
Fix double-post to animationFrame