Fix anti-aliasing and unittests.