Fast Distance Queries for Triangles, Lines, and Points using SSE Instructions

E. Shellshear, R. Ytterlid, Journal of Computer Graphics Techniques (JCGT), December 2014, vol. 3, no. 4, 86-110


This paper presents a suite of routines for computing the distance between combinations of triangles, lines and points that we optimized for the x86 SSE SIMD (vector) instruction set. We measured between two and seven times throughput improvement over the naive non-SSE optimized routines.


This work was carried out at the Wingquist Laboratory VINN Excellence Centre, and is part of the Sustainable Production Initiative and the Production Area of Advance at Chalmers University of Technology. It was supported by the Swedish Governmental Agency for Innovation Systems. The authors are deeply grateful for the insightful and helpful comments of the reviewers that significantly improved the presentation and results in this paper.

Authors and Affiliations

  • E. Shellshear, Fraunhofer-Chalmers Centre
  • R. Ytterlid, Fraunhofer-Chalmers Centre

Photo credits: Nic McPhee