Adding some intersection code.