Remove vertices outside boundary.