STRUCT
ArdkVpsSession.Configuration
struct Configuration
Configuration structure for the VPS session.
Properties
continuousLocalizationEnabled
public var continuousLocalizationEnabled: Bool
Whether to enable continuous localization.
This will continuously send localization requests to the VPS server even after the first successful localization response has been received. These results will help refine the position of the anchor over time. This will also help mitigate AR tracking drift.
- Attention: This will increase the bandwidth used by the VPS feature.
- Attention: This will also cause anchored objects to move in the scene as their positions are refined.
- Attention: This is disabled in the default configuration.
See cloudLocalizerContinuousRequestsPerSecond to define the frequency of the requests.
temporalFusionEnabled
public var temporalFusionEnabled: Bool
Whether to enable temporal fusion.
This will combine the results of successive localizations over time to provide a more stable result. This will help mitigate AR tracking drift. This requires that continuous localization is enabled.
Enabling temporal fusion will generate more stable results, but it will also take longer to resolve tracking drift compared to only taking the latest localization result.
- Attention: This is disabled in the default configuration.
interpolationEnabled
public var interpolationEnabled: Bool
Whether to enable interpolation.
This will interpolate the position of the anchor over time to provide a smoother result. Anchor updates will be surfaced as sequential smooth updates rather than a single update at the latest localization result.
- Attention: This is disabled in the default configuration.
cloudLocalizerInitialRequestsPerSecond
public var cloudLocalizerInitialRequestsPerSecond: Float
Defines the number of localization requests per second which are sent to the VPS server prior to the first successful localization.
This is 1.0f in the default configuration.
cloudLocalizerContinuousRequestsPerSecond
public var cloudLocalizerContinuousRequestsPerSecond: Float
Defines the number of localization requests per second which are sent to the VPS server after the first successful localization. This is only used if continuous localization is enabled.
This is 0.2f in the default configuration (one request every 5 seconds).
cloudTemporalFusionWindowSize
public var cloudTemporalFusionWindowSize: UInt32
Defines the number of entries that are considered for temporal fusion in cloud localization.
This config option is currently disabled
jpegCompressionQuality
public var jpegCompressionQuality: UInt32
Defines the quality of the JPEG compression used for the camera image sent to the VPS server as part of a localization request. Lower values will result in lower bandwidth usage.
We have benchmarked that 50-90 quality for jpeg compression does not significantly impact the accuracy of the localization results.
This is 70 in the default configuration.
gpsCorrectionForContinuousLocalization
public var gpsCorrectionForContinuousLocalization: Bool
Whether to enable GPS correction for continuous localization.
This will download additional GPS graph data from the VPS server to help correct the GPS location of the device. This is useful for refining device GPS location after localization.
deviceMapLocalizationEnabled
public var deviceMapLocalizationEnabled: Bool
Methods
init(continuousLocalizationEnabled:temporalFusionEnabled:interpolationEnabled:cloudLocalizerInitialRequestsPerSecond:cloudLocalizerContinuousRequestsPerSecond:cloudTemporalFusionWindowSize:jpegCompressionQuality:gpsCorrectionForContinuousLocalization:deviceMapLocalizationEnabled:)
public init(continuousLocalizationEnabled: Bool = false,
temporalFusionEnabled: Bool = false,
interpolationEnabled: Bool = false,
cloudLocalizerInitialRequestsPerSecond: Float = 0,
cloudLocalizerContinuousRequestsPerSecond: Float = 0,
cloudTemporalFusionWindowSize: UInt32 = 0,
jpegCompressionQuality: UInt32 = 0,
gpsCorrectionForContinuousLocalization: Bool = true,
deviceMapLocalizationEnabled: Bool = false)