Photogrammetry failed with crash(Assert: in line 417)

I'm developing a 3D scanner works on a iPad(6th gen, 12-inch).

Photogrammetry with ObjectCaptureSession was successful, but other trials are not.

I've tried Photogrammetry with URL inputs, these are pictures from AVCapturePhoto. It is strange... if metadata is not replaced, photogrammetry would be finished but it seems to be no depthData or gravity info were used. (depth and gravity is separated files). but if metadata is injected, this trial are fails.

and this time i tried to Photogrammetry with PhotogrammetrySamples sequence and it also failed.

the settings are:

  • camera: back Lidar camera,
  • image format: kCVPicelFormatType_32BGRA(failed with crash) or hevc(just failed) image
  • depth format: kCVPixelFormatType_DisparityFloat32 or kCVPixelFormatType_DepthFloat32
  • photoSetting: isDepthDataDeliveryEnabled = true, isDepthDataFiltered = false, embeded = true

I wonder iPad supports Photogrammetry with PhotogrammetrySamples

I've already tested some sample codes provided by apple:

What should I do to make Photogrammetry successful?

  • Not the easiest error to interpret...

  • It's because your array of PhotogrammetrySamples is not ordered correctly - make sure they are sorted by their PhotogrammetrySample.id.

Add a Comment