Vision Pro projection matrix

Hello.

I am trying to calculate rays from the NDC coordinates of the screen and the inverse of the projection and view matrices provided by the VisionOS API. It works perfectly in the simulator, but on device the projected rays do not match the (correct) projection of the raster scene rendered with the same projection and view matrices. Are there some differences between the device and simulator projection matrices that might cause this issue?

Vision Pro projection matrix
 
 
Q