now recording depth rather than z