Home > @magiclane/maps-sdk > RecorderConfiguration

RecorderConfiguration class

Configuration used to control recorder behavior and log storage settings.

Use this object to specify which data types to record, where logs are stored, chunking and retention policies, video quality and audio options, and device-specific hardware metadata. Construct a RecorderConfiguration and pass it to Recorder.create() or Recorder.setRecorderConfiguration() to apply the settings.

Sensor Data Source

Signature:

export declare class RecorderConfiguration extends GemAutoreleaseObject 

Extends: GemAutoreleaseObject

Properties

Property

Modifiers

Type

Description

chunkDurationSeconds

number

Chunk duration (seconds) used to split recordings.

A value of 0 disables chunking. When enabled the recorder verifies there is enough disk space to store a full chunk before starting. When a chunk finishes the current recording stops; if continuousRecording is true a new recording starts automatically.

continuousRecording

boolean

Whether recordings continue automatically after a chunk ends.

When true a new recording is started automatically when the current chunk completes.

dataSource

DataSource

The data source used for recording.

The DataSource that supplies sensor and location input used by the recorder.

deleteOlderThanKeepMin

boolean

Whether logs older than keepMinSeconds are deleted regardless of free space.

When true, older logs are removed once the retention threshold is exceeded even if there is available disk space.

enableAudio

boolean

Whether audio tracks are enabled for recordings.

When true an audio track is created during setup. Audio recording can be started and stopped independently using the recorder's Recorder.startAudioRecording() and Recorder.stopAudioRecording() methods.

hardwareSpecifications

Map<HardwareSpecification, string>

Device hardware specifications attached to recordings.

Returns a map keyed by HardwareSpecification containing string values describing device metadata collected at recording time (for example model, cpu cores, memory).

Needs to be populated by the API user.

keepMinSeconds

number

Minimum total seconds of recordings to retain on disk.

When this threshold is exceeded and space is low, older recordings may be removed. To force deletion regardless of space set deleteOlderThanKeepMin to true.

logsDir

string

Directory used to store recorder logs.

Returns an absolute path to the directory where log files are written.

maxDiskSpaceUsed

number

Maximum disk space (bytes) that recordings may occupy.

When the total size of recordings reaches this limit the recorder stops to avoid exceeding the configured space. A value of 0 disables disk checks.

minDurationSeconds

number

Minimum recording duration (seconds) required to save a recording.

Recordings shorter than this value are discarded. Defaults to 30 seconds.

recordedTypes

DataType[]

Types of data that are configured to be recorded.

Returns the list of DataType values that the recorder will capture. If any requested type is not produced by the configured dataSource, the recorder will refuse to start.

transportMode

RecordingTransportMode

Transport mode associated with recorded logs.

Returns a RecordingTransportMode value captured when the log was recorded. Defaults to RecordingTransportMode.unknown when not set.

videoQuality

Resolution

Video quality (resolution) used when camera recording is active.

If set to Resolution.unknown and camera recording is requested, video will not be recorded.

Methods

Method

Modifiers

Description

create(options)

static

Creates a configured RecorderConfiguration.

Use this factory to prepare recorder settings before creating a Recorder instance. The constructor only builds the configuration; it does not start or modify any active recorder by itself.