Three-dimensional inspection