Reduced redundant calls to geometry functions