Anura Core SDK iOS 1.9.0 is a major update that includes the following improvements and features:
- New measurement UI that utilizes the device's screen as a light source for more accurate and reliable measurements
- Replaced the existing visage|SDK FaceTrack with MediaPipe FaceMesh for improved performance and simplified integration
- Improved WebSocket handling in poor network conditions
- DeepAffex token security enhancements
A few steps are required to upgrade your existing app from Anura Core 1.8.x to 1.9.0.
Replace the existing
in your application with the latest versions.
Anura Core SDK 1.9.0 features a new measurement UI that utilizes the device's screen as a light source for more accurate and reliable measurements.
Existing applications will adopt the new measurement UI and behaviour
automatically through the
defaultConfiguration property of
MeasurementUIConfiguration. If your application
needs to maintain the UI and behaviour of previous versions of Anura Core SDK,
you may use the corresponding
Anura Core SDK 1.9.0 includes support for MediaPipe FaceMesh which provides improved performance, a smaller binary size, and simplifies integration with your application.
To start using MediaPipe, you will need to add
FaceMesh.xcframework to your
application's embedded frameworks. You can simply initialize an instance of
MediaPipeFaceTracker and pass it to
initialization. Be sure to add
<AnuraCore/MediaPipeFaceTracker.h> to your
application's bridging header.
You may also remove visage|SDK FaceTrack and its dependencies and assets:
You may also update your Xcode build target's settings to remove any settings related to visage|SDK FaceTrack:
"$(SRCROOT)/Frameworks/visageSDK-iOS/include"from Header Search Paths
IOSfrom Preprocessor Macros
Note: MediaPipe is not tied to your application ID, and does not require a separate license file for each variant of your application.
If you would like to continue using visage|SDK FaceTrack, you may use the Visage classes and binaries provided in previous versions of Anura Core SDK.
MeasurementResults class has been updated to parse the
Notes field from
DeepAffex Cloud that provide additional information about the computation of the
allResults property has been changed to return
[String: SignalResult] instead of
[String: Double], with
SignalResult having 2
value: Double and
Your application should be updated to read the
value property for each
SignalResult, and the
notes property will contain additional information
about the computation of the that result. For more information on notes, please
refer to DeepAffex Cloud API - Subscribe to
AnuraMeasurementViewController includes a new
shouldCancelMeasurement(snr: Double, chunkOrder: Int) -> Bool method in
determine if a measurement should be cancelled early.
In previous versions of the Sample App, the measurement early cancellation logic was in the example code. If your application was using that code, you should replace that code with calling this new method.
Anura Core SDK iOS 1.9.0 includes an improved DeepAffex Cloud API client that can better handle WebSocket connections in poor network conditions.
Your application will these improvements by using the updated
MeasurementResultsSubscriber classes included in
the Sample App.
An important security update to the DeepAffex Cloud API is currently scheduled for November 28, 2023, which will prevent client apps from copying a validated DeepAffex token onto another (non-validated) physical device and will expire tokens after a fixed duration. This will impact your user's experience if you choose to keep using the older Anura Core SDKs. Upgrading to the latest Anura Core SDKs will ensure seamless adaptation to these upcoming API changes.
Your application must use the new
beginStartupFlow(_:) method of
DeepAffexMiniAPIClient to ensure that it has a valid token prior to taking a
measurement. This method encapsulates the code that was in previous versions of
StartViewController, and your application should replace that code with
calling the new
- The new
FaceMesh.xcframeworkcurrently does not support iOS Simulator on Intel-based Macs