|
enum | VuRecordingCreationError : int32_t {
VU_RECORDING_CREATION_ERROR_NONE = 0x0,
VU_RECORDING_CREATION_ERROR_DATA_FLAGS_NOT_SUPPORTED,
VU_RECORDING_CREATION_ERROR_AUTOSTART_FAILED = 0x2
} |
| Recording creation error. More...
|
|
enum | VuRecordingStartError : int32_t {
VU_RECORDING_START_ERROR_NONE = 0x0,
VU_RECORDING_START_ERROR_INTERNAL,
VU_RECORDING_START_ERROR_ANOTHER_RECORDING_RUNNING = 0x2,
VU_RECORDING_START_ERROR_ENGINE_NOT_RUNNING = 0x3,
VU_RECORDING_START_ERROR_INVALID_STATUS,
VU_RECORDING_START_ERROR_FILE_CREATION = 0x5,
VU_RECORDING_START_ERROR_UNKNOWN_ORIENTATION = 0x6,
VU_RECORDING_START_ERROR_DATA_SOURCE,
VU_RECORDING_START_ERROR_INSUFFICIENT_FREE_SPACE
} |
| Recording start error. More...
|
|
enum | VuRecordingStatus : int32_t {
VU_RECORDING_STATUS_INITIALIZED = 0x1,
VU_RECORDING_STATUS_RUNNING = 0x2,
VU_RECORDING_STATUS_STOPPED = 0x3
} |
| Session recording status. More...
|
|
enum | VuRecordingStatusInfo : int32_t {
VU_RECORDING_STATUS_INFO_NORMAL = 0x0,
VU_RECORDING_STATUS_INFO_SUCCESS = 0x1,
VU_RECORDING_STATUS_INFO_ERROR_INTERNAL,
VU_RECORDING_STATUS_INFO_ERROR_ORIENTATION_CHANGED = 0x3,
VU_RECORDING_STATUS_INFO_ERROR_DATA_SOURCE = 0x4,
VU_RECORDING_STATUS_INFO_ERROR_INSUFFICIENT_FREE_SPACE
} |
| Session recording status info. More...
|
|
enum | VuRecordingDataFlagBits : int32_t {
VU_RECORDING_DATA_VIDEO_BIT = 0x01,
VU_RECORDING_DATA_CAMERA_METADATA_BIT = 0x02,
VU_RECORDING_DATA_SENSORS_BIT = 0x04,
VU_RECORDING_DATA_DEVICE_POSE_BIT = 0x08,
VU_RECORDING_DATA_AUDIO_BIT = 0x10
} |
| Flags that specify which data should be recorded. More...
|
|
enum | VuRecordingFrameRate : int32_t {
VU_RECORDING_FRAME_RATE_AUTO = 0x1,
VU_RECORDING_FRAME_RATE_FULL = 0x2,
VU_RECORDING_FRAME_RATE_HALF = 0x3
} |
| The frame rate at which camera images are recorded. More...
|
|
enum | VuRecordingImageScale : int32_t {
VU_RECORDING_IMAGE_SCALE_AUTO = 0x1,
VU_RECORDING_IMAGE_SCALE_FULL = 0x2,
VU_RECORDING_IMAGE_SCALE_HALF = 0x3
} |
| The scale factor to be applied to camera images before recording. More...
|
|
enum | VuRecordingFormat : int32_t { VU_RECORDING_FORMAT_DEFAULT = 0x1
} |
| Session recording format. More...
|
|
|
VuRecordingConfig | vuRecordingConfigDefault () |
| Default configuration for a recording session. More...
|
|
VuResult | vuEngineGetSessionRecorderController (const VuEngine *engine, VuController **controller) |
| Retrieve Session Recorder Controller to get access to session recording-specific functionality in Engine.
|
|
VuResult | vuSessionRecorderControllerGetDefaultRecordingDataFlags (const VuController *controller, VuRecordingDataFlags *dataFlags) |
| Get the default recording data flags that are appropriate for the current device. More...
|
|
VuResult | vuSessionRecorderControllerGetSupportedRecordingDataFlags (const VuController *controller, VuRecordingDataFlags *dataFlags) |
| Get all recording data flags that are supported by the current device. More...
|
|
VuResult | vuSessionRecorderControllerGetDefaultRecordingFrameRate (const VuController *controller, VuRecordingFrameRate *frameRate) |
| Get the default camera recording frame rate. More...
|
|
VuResult | vuSessionRecorderControllerGetDefaultRecordingImageScale (const VuController *controller, VuRecordingImageScale *scale) |
| Get the default recording image scale. More...
|
|
VuResult | vuSessionRecorderControllerCreateRecording (VuController *controller, const VuRecordingConfig *config, VuRecording **recording, VuRecordingCreationError *error) |
| Create a new recording with the specified configuration. More...
|
|
VuResult | vuSessionRecorderControllerGetRecordings (const VuController *controller, VuRecordingList *recordingList) |
| Get a list of all recordings from the controller. More...
|
|
VuResult | vuSessionRecorderControllerDestroyRecordings (VuController *controller, VuBool deleteData) |
| Destroy all recordings. More...
|
|
VuResult | vuSessionRecorderControllerCleanRecordedData (VuController *controller) |
| Remove all previously recorded sequences from the device storage. More...
|
|
VuResult | vuRecordingStart (VuRecording *recording, VuRecordingStartError *error) |
| Start the recording. More...
|
|
VuResult | vuRecordingStop (VuRecording *recording) |
| Stop the current recording. More...
|
|
VuResult | vuRecordingGetPath (const VuRecording *recording, const char **path) |
| Get the path where the data for this recording is stored. More...
|
|
VuResult | vuRecordingGetStatus (const VuRecording *recording, VuRecordingStatus *status) |
| Get the status of a recording. More...
|
|
VuResult | vuRecordingGetStatusInfo (const VuRecording *recording, VuRecordingStatusInfo *statusInfo) |
| Get additional status info about a recording. More...
|
|
VuResult | vuRecordingDestroy (VuRecording *recording, VuBool deleteData) |
| Destroy a recording instance. More...
|
|
VuResult | vuRecordingListCreate (VuRecordingList **list) |
| Create a recording list.
|
|
VuResult | vuRecordingListGetSize (const VuRecordingList *list, int32_t *listSize) |
| Get the number of elements in a recording list.
|
|
VuResult | vuRecordingListGetElement (const VuRecordingList *list, int32_t element, VuRecording **recording) |
| Get an element in a recording list.
|
|
VuResult | vuRecordingListDestroy (VuRecordingList *list) |
| Destroy a recording list.
|
|
This controller facilitates recording data from data sources such as on-device camera and sensors while running Vuforia.
- Permissions
In order to support audio recording capabilities in the Session Recorder Controller, your App must fulfill audio-related, platform-specific permission / configuration requirements. Your App is responsible for executing the following platform-specific actions prior to invoking Session Recorder Controller API functions relying on information whether audio recording is enabled in the app:
- Android:
- Add the "android.permission.RECORD_AUDIO" permission to the AndroidManifest.xml and also request it at run-time in your App's code.
- iOS:
- Microphone usage description: Add the key "NSMicrophoneUsageDescription" to the Info.plist with an explanation why your App requires microphone access, otherwise the App will be rejected by the App Store submission process.
- Microphone access: Request access to the microphone by calling the "AVCaptureDevice requestAccessForMediaType" API with the media type "AVMediaTypeAudio".
- UWP:
- Add the following snippet to the <Capabilities> tag in your App's Package.appxmanifest to enable audio recording capabilities:
<Capabilities>
<DeviceCapability Name="microphone" />
</Capabilities>
- Lumin:
- Add the key "AudioCaptureMic" to the manifest.xml to enable audio recording capabilities.
If the aforementioned platform-specific permission / configuration requirements are not fulfilled by the App, then
- the vuSessionRecorderControllerGetSupportedRecordingDataFlags call won't report audio support (i.e. VU_RECORDING_DATA_AUDIO_BIT will be missing)
- the vuSessionRecorderControllerCreateRecording call will fail with VU_RECORDING_START_ERROR_DATA_SOURCE if VuRecordingConfig.dataFlags is configured to record audio
◆ VuRecordingCreationError
Recording creation error.
Enumerator |
---|
VU_RECORDING_CREATION_ERROR_NONE | No error.
|
VU_RECORDING_CREATION_ERROR_DATA_FLAGS_NOT_SUPPORTED | One or more requested data flags are not supported on the current device.
|
VU_RECORDING_CREATION_ERROR_AUTOSTART_FAILED | Auto-start of the recording failed.
|
◆ VuRecordingStartError
Recording start error.
Enumerator |
---|
VU_RECORDING_START_ERROR_NONE | No error.
|
VU_RECORDING_START_ERROR_INTERNAL | Starting failed due to an internal error. Please check the device logs for additional information.
|
VU_RECORDING_START_ERROR_ANOTHER_RECORDING_RUNNING | Failed to start a recording because another recording is already in progress. Stop the other recording before starting a new one.
|
VU_RECORDING_START_ERROR_ENGINE_NOT_RUNNING | Recording cannot be started as the engine is not running.
|
VU_RECORDING_START_ERROR_INVALID_STATUS | Cannot start a recording that is not in the initialized state. The user should create a new recording.
|
VU_RECORDING_START_ERROR_FILE_CREATION | Cannot start the recording because the output file could not be created.
|
VU_RECORDING_START_ERROR_UNKNOWN_ORIENTATION | Device is in an unknown orientation.
|
VU_RECORDING_START_ERROR_DATA_SOURCE | Failed to start recording from some of the selected data sources. This could happen if e.g. another application has exclusive access to a source, or required platform-specific permission / configuration requirements haven't been fulfilled by the App
|
VU_RECORDING_START_ERROR_INSUFFICIENT_FREE_SPACE | Cannot start a recording as there isn't sufficient free space on the device to store it.
|
◆ VuRecordingStatus
Session recording status.
Enumerator |
---|
VU_RECORDING_STATUS_INITIALIZED | The recording has been created and can be started.
|
VU_RECORDING_STATUS_RUNNING | The recording is in progress.
|
VU_RECORDING_STATUS_STOPPED | The recording has stopped. It cannot be started again. Check the status info for error details.
|
◆ VuRecordingStatusInfo
Session recording status info.
Enumerator |
---|
VU_RECORDING_STATUS_INFO_NORMAL | Normal operation. No error has occurred.
|
VU_RECORDING_STATUS_INFO_SUCCESS | The recording completed successfully.
|
VU_RECORDING_STATUS_INFO_ERROR_INTERNAL | Recording was aborted due to an internal error. Please check the device logs for additional information.
|
VU_RECORDING_STATUS_INFO_ERROR_ORIENTATION_CHANGED | The device orientation changed during recording.
|
VU_RECORDING_STATUS_INFO_ERROR_DATA_SOURCE | Recording from some of the selected data sources failed.
|
VU_RECORDING_STATUS_INFO_ERROR_INSUFFICIENT_FREE_SPACE | The recording stopped as there isn't sufficient free space on the device to store it.
|
◆ VuRecordingDataFlagBits
Flags that specify which data should be recorded.
- Note
- Use vuSessionRecorderControllerGetDefaultDataFlags() to get the default data flags that are appropriate for the current device. The flags returned by that function will lead to a recording that can be used for playing back AR sessions.
Enumerator |
---|
VU_RECORDING_DATA_VIDEO_BIT | Camera images.
|
VU_RECORDING_DATA_CAMERA_METADATA_BIT | Camera metadata required for AR session playback.
|
VU_RECORDING_DATA_SENSORS_BIT | Data from device sensors (accelerometer, gyroscope and magnetometer) depending on which are available on the current device
|
VU_RECORDING_DATA_DEVICE_POSE_BIT | Device poses generated by the platform-provided Vuforia Fusion provider.
|
VU_RECORDING_DATA_AUDIO_BIT | Audio recording from the default audio input device.
|
◆ VuRecordingFrameRate
The frame rate at which camera images are recorded.
Enumerator |
---|
VU_RECORDING_FRAME_RATE_AUTO | Let Vuforia automatically choose the option that will provide the best performance during recording. This is the default
|
VU_RECORDING_FRAME_RATE_FULL | Record camera images at the full frame rate of the camera.
|
VU_RECORDING_FRAME_RATE_HALF | Record camera images at half the frame rate of the camera.
|
◆ VuRecordingImageScale
The scale factor to be applied to camera images before recording.
Enumerator |
---|
VU_RECORDING_IMAGE_SCALE_AUTO | Let Vuforia automatically choose the option that will provide the best performance during recording. This is the default
|
VU_RECORDING_IMAGE_SCALE_FULL | Record camera images at full resolution.
|
VU_RECORDING_IMAGE_SCALE_HALF | Downsample camera images to half size along both dimensions.
|
◆ VuRecordingFormat
Session recording format.
- Note
- Only one format is currently supported. Others might be added in the future.
Enumerator |
---|
VU_RECORDING_FORMAT_DEFAULT | Default format. MP4 file with H.264 compressed video.
|
◆ vuRecordingConfigDefault()
Default configuration for a recording session.
- Note
- Use this function to initialize the VuRecordingConfig data structure with default values.
◆ vuSessionRecorderControllerGetDefaultRecordingDataFlags()
Get the default recording data flags that are appropriate for the current device.
- Note
- The flags returned by this function will configure a recording with all data required for playing it back as an AR session.
-
The flags returned by this function depend on the current VuFusionProviderType.
- Parameters
-
controller | Session Recorder Controller |
dataFlags | Output variable storing the default data flags bitmask |
- Returns
- VU_SUCCESS on successful retrieval of the data flags, VU_FAILED on failure
◆ vuSessionRecorderControllerGetSupportedRecordingDataFlags()
Get all recording data flags that are supported by the current device.
- Parameters
-
controller | Session Recorder Controller |
dataFlags | Output variable storing the data flags bitmask |
- Returns
- VU_SUCCESS on successful retrieval of the data flags, VU_FAILED on failure
◆ vuSessionRecorderControllerGetDefaultRecordingFrameRate()
Get the default camera recording frame rate.
- Note
- This function will return the recommended default recording frame rate setting.
-
This method can only be called while the engine is running.
The output value will always be an explicit one (i.e. never VU_RECORDING_FRAME_RATE_AUTO) so the caller can determine the specific value being used for recording.
◆ vuSessionRecorderControllerGetDefaultRecordingImageScale()
Get the default recording image scale.
- Note
- This function will return the recommended default recording image scale setting.
-
This method can only be called while the engine is running.
The output value will always be an explicit one (i.e. never VU_RECORDING_IMAGE_SCALE_AUTO) so the caller can determine the specific value being used for recording.
◆ vuSessionRecorderControllerCreateRecording()
Create a new recording with the specified configuration.
- Note
- If "start" is set to VU_TRUE in the recording configuration and another recording is already running, this call will fail. Any previously started recording needs to be stopped first.
- Parameters
-
controller | Session Recorder Controller |
config | The configuration for the new recording |
recording | Output variable storing the newly created recording |
error | Optional output variable providing additional error information. Can be NULL. |
- Returns
- VU_SUCCESS on successfully creation of the recording, VU_FAILED on failure
◆ vuSessionRecorderControllerGetRecordings()
Get a list of all recordings from the controller.
- Parameters
-
controller | Session Recorder Controller |
recordingList | List that will be filled with the recordings |
- Returns
- VU_SUCCESS on success, or VU_FAILED otherwise
◆ vuSessionRecorderControllerDestroyRecordings()
Destroy all recordings.
This call will also stop any ongoing recording.
- Parameters
-
controller | Session Recorder Controller |
deleteData | Set to VU_TRUE to delete all data generated by the recording instances before their destruction |
- Returns
- VU_SUCCESS on success, or VU_FAILED otherwise
◆ vuSessionRecorderControllerCleanRecordedData()
Remove all previously recorded sequences from the device storage.
- Note
- This call can only be used when no recording instances exist. Stop any running recording and destroy all recording instances before calling this.
- Parameters
-
controller | Session Recorder Controller |
- Returns
- VU_SUCCESS if all recorded data was removed successfully, or VU_FAILED otherwise
◆ vuRecordingStart()
Start the recording.
- Note
- If another recording is already running, this call will fail. Any previously started recording needs to be stopped first.
-
Session Recorder does not support changes in device orientation during recording. If the device orientation changes while a recording is running, it will be automatically stopped.
-
Calling this on a recording that is already running or has already been stopped will return VU_FAILED with error VU_RECORDING_START_ERROR_INVALID_STATUS.
- Parameters
-
recording | The current recording |
error | Optional output variable providing additional error information. Can be NULL. |
- Returns
- VU_SUCCESS on successfully start of the recording, VU_FAILED on failure
◆ vuRecordingStop()
Stop the current recording.
- Note
- The recording will be stopped automatically when vuEngineStop() is called or when it is destroyed.
-
Calling this on a recording that is not running will return VU_FAILED
- Parameters
-
recording | The current recording |
- Returns
- VU_SUCCESS on successfully stopping the recording, VU_FAILED on failure
◆ vuRecordingGetPath()
Get the path where the data for this recording is stored.
- Note
- The recording path is only available after the recording has been started successfully.
-
The string returned from this function is only valid for the lifetime of the recording instance. Please create a copy of the string data if you want to keep it beyond the lifetime of the recording.
- Parameters
-
recording | The current recording |
path | The absolute path to where the recording is stored. The parameter will stay unmodified on failure. |
- Returns
- VU_SUCCESS on successful retrieval of the path, VU_FAILED if no recording path is available.
◆ vuRecordingGetStatus()
Get the status of a recording.
- Parameters
-
recording | The current recording |
status | Current recording status |
- Returns
- VU_SUCCESS on successfully getting status, VU_FAILED on failure
◆ vuRecordingGetStatusInfo()
Get additional status info about a recording.
- Parameters
-
recording | The current recording |
statusInfo | Current recording status info |
- Returns
- VU_SUCCESS on successfully getting status info, VU_FAILED on failure
◆ vuRecordingDestroy()
Destroy a recording instance.
- Note
- The recording will be stopped if it is running.
- Parameters
-
recording | Recording instance |
deleteData | If set to VU_TRUE, the recorded data in device storage will be deleted as well |
- Returns
- VU_SUCCESS on success, VU_FAILED on failure