Skip to content

CLASS

SessionManager

public class SessionManager

The Session Manager is the main entry point for all tracking operations. When initialized, it construct the correct capture session depending on the current device. If the device supports ARKit2 tracking, it will start an ARSession. If not, it will start an Obital Tracker Session. Make sure to only have one instance running at a time. Multiple sessions may cause the sensor to fail receiving data.

Properties

delegate

public weak var delegate: SessionManagerDelegate?

Sets the delegate to listen for updates on the face detection.

Methods

init(useARKit:)

public init(useARKit: Bool = true)

Initializes the tracker object, making sure a supported tracker is selected.

  • Parameter useARKit: Optional boolean defining if ARKit should be used if it's available. Defaults to true. default value is true.

Parameters

Name Description
useARKit Optional boolean defining if ARKit should be used if it’s available. Defaults to true. default value is true.

start()

public func start()

Starts the session recording and frame processing.

stop()

public func stop()

Stops or pauses the frame processing. The camera will still record.

toggleRecording()

public func toggleRecording()

Start or stop the video recording process.