Cuboid placement and STSensorController deprecation

Hello,

We have an issue with the cuboid when starting a scan. Issue does appear on latest v011.1 SDK, with either ST01 or ST02A.

The cause of the issue is Occipitals recommendations on replacing deprecated STSensorController in method enterScanningState of file ViewController.mm. At the below forum link, @n6xej recommends the following.

What we do is save a reference to the latest STDepthFrame in method captureSession:didOutputSample:type of file ViewController+CaptureSession.mm. Then at enterScanningState, we use @n6xej’s recommendation. Unfortunately, the cuboid does not remain at the position prior to starting the scan. How do we maintain the cuboid’s position without using deprecated STSensorController?

Link:

@n6xej’s recommendation:
“GLKMatrix4 iOSColorFromDepthExtrinsics = [depthFrame iOSColorFromDepthExtrinsics];

Is equivalent to:

GLKMatrix4 colorCameraPoseInDepthCoordinateSpace;

[depthFrame colorCameraPoseInDepthCoordinateFrame:colorCameraPoseInDepthCoordinateSpace.m];”