SmartSpectraSdk

Entry point for interacting with the SmartSpectra Android SDK.

Obtain an instance by calling initialize once and then getInstance. All configuration for measurements and callbacks is performed through this class. Only a single instance should exist within an application.

Types

Link copied to clipboard
object Companion

Properties

Functions

Link copied to clipboard

Clears metrics and error state from the previous session.

Link copied to clipboard
fun setApiKey(apiKey: String)

Sets the API key used for API key based authentication.

Link copied to clipboard
fun setCameraPosition(cameraPosition: Int)

Sets which device camera to use when capturing.

Link copied to clipboard

Updates the current edge metrics that observers listen to.

Link copied to clipboard

Registers an observer that is invoked whenever new edge metrics are produced.

Link copied to clipboard
fun setEnableEdgeMetrics(enableEdgeMetrics: Boolean)

Enables or disables collection of edge metrics on device.

Link copied to clipboard
fun setMeasurementDuration(measurementDuration: Double)

Sets the measurement duration in seconds for spot mode.

Link copied to clipboard

Updates the current metrics buffer that observers listen to.

Link copied to clipboard

Registers an observer that is invoked whenever new metrics are produced.

Link copied to clipboard
fun setRecordingDelay(recordingDelay: Int)

Sets the countdown delay in seconds before recording starts.

Link copied to clipboard
fun setShowFps(showFps: Boolean)

Enables or disables display of frames-per-second information.

Link copied to clipboard
fun setSmartSpectraMode(smartSpectraMode: SmartSpectraMode)

Defines whether measurements run in SmartSpectraMode.SPOT or SmartSpectraMode.CONTINUOUS.

Link copied to clipboard
fun showControlsInScreeningView(customizationEnabled: Boolean)

Controls whether camera and mode selection UI is shown in the screening view.