Implement bounding box check.