Inherits IDisposable.
Classes | |
struct | VideoCaptureResult |
Public Types | |
enum | CaptureResultType { Success = 0 , UnknownError = 1 } |
enum | AudioState { MicAudio = 0 , ApplicationAudio = 1 , ApplicationAndMicAudio = 2 , None = 3 } |
Public Member Functions | |
NRVideoCapture () | |
FrameCaptureContext | GetContext () |
void | Dispose () |
void | StartRecordingAsync (string filename, OnStartedRecordingVideoCallback onStartedRecordingVideoCallback) |
void | StartRecordingAsync (string filename, OnStartedRecordingVideoCallback onStartedRecordingVideoCallback, float volumeFactorMic, float volumeFactorApp) |
void | StartVideoModeAsync (CameraParameters setupParams, OnVideoModeStartedCallback onVideoModeStartedCallback, bool autoAdaptBlendMode=false) |
void | StopRecordingAsync (OnStoppedRecordingVideoCallback onStoppedRecordingVideoCallback) |
void | StopVideoModeAsync (OnVideoModeStoppedCallback onVideoModeStoppedCallback) |
delegate void | OnStartedRecordingVideoCallback (VideoCaptureResult result) |
delegate void | OnVideoCaptureResourceCreatedCallback (NRVideoCapture captureObject) |
delegate void | OnVideoModeStartedCallback (VideoCaptureResult result) |
delegate void | OnVideoModeStoppedCallback (VideoCaptureResult result) |
delegate void | OnStoppedRecordingVideoCallback (VideoCaptureResult result) |
Static Public Member Functions | |
static void | CreateAsync (bool showHolograms, OnVideoCaptureResourceCreatedCallback onCreatedCallback) |
static IEnumerable< int > | GetSupportedFrameRatesForResolution (Resolution resolution) |
Properties | |
static IEnumerable< Resolution > | SupportedResolutions [get] |
bool | IsRecording [get] |
Texture? | PreviewTexture [get] |
Detailed Description
Records a video from the MR images directly to disk. MR images comes from rgb camera or rgb camera image and virtual image blending. The final video recording will be stored on the file system in the MP4 format.
Member Enumeration Documentation
◆ AudioState
◆ CaptureResultType
Member Function Documentation
◆ CreateAsync()
|
static |
Creates an asynchronous.
- Parameters
-
showHolograms True to show, false to hide the holograms. onCreatedCallback The on created callback.
◆ GetContext()
FrameCaptureContext NRKernal.Record.NRVideoCapture.GetContext | ( | ) |
Gets the context.
- Returns
- The context.
◆ GetSupportedFrameRatesForResolution()
|
static |
Returns the supported frame rates at which a video can be recorded given a resolution.
- Parameters
-
resolution A recording resolution.
- Returns
- The frame rates at which the video can be recorded.
◆ OnStartedRecordingVideoCallback()
delegate void NRKernal.Record.NRVideoCapture.OnStartedRecordingVideoCallback | ( | VideoCaptureResult | result | ) |
Called when the web camera begins recording the video.
- Parameters
-
result Indicates whether or not video recording started successfully.
◆ OnStoppedRecordingVideoCallback()
delegate void NRKernal.Record.NRVideoCapture.OnStoppedRecordingVideoCallback | ( | VideoCaptureResult | result | ) |
Called when the video recording has been saved to the file system.
- Parameters
-
result Indicates whether or not video recording was saved successfully to the file system.
◆ OnVideoCaptureResourceCreatedCallback()
delegate void NRKernal.Record.NRVideoCapture.OnVideoCaptureResourceCreatedCallback | ( | NRVideoCapture | captureObject | ) |
Called when a VideoCapture resource has been created.
- Parameters
-
captureObject The VideoCapture instance.
◆ OnVideoModeStartedCallback()
delegate void NRKernal.Record.NRVideoCapture.OnVideoModeStartedCallback | ( | VideoCaptureResult | result | ) |
Called when video mode has been started.
- Parameters
-
result Indicates whether or not video mode was successfully activated.
◆ OnVideoModeStoppedCallback()
delegate void NRKernal.Record.NRVideoCapture.OnVideoModeStoppedCallback | ( | VideoCaptureResult | result | ) |
Called when video mode has been stopped.
- Parameters
-
result Indicates whether or not video mode was successfully deactivated.
◆ StartRecordingAsync() [1/2]
void NRKernal.Record.NRVideoCapture.StartRecordingAsync | ( | string | filename, |
OnStartedRecordingVideoCallback | onStartedRecordingVideoCallback | ||
) |
Starts recording asynchronous.
- Parameters
-
filename Filename of the file. onStartedRecordingVideoCallback The on started recording video callback.
◆ StartRecordingAsync() [2/2]
void NRKernal.Record.NRVideoCapture.StartRecordingAsync | ( | string | filename, |
OnStartedRecordingVideoCallback | onStartedRecordingVideoCallback, | ||
float | volumeFactorMic, | ||
float | volumeFactorApp | ||
) |
Starts recording asynchronous.
- Parameters
-
filename Filename of the file. onStartedRecordingVideoCallback The on started recording video callback. volumeFactorMic The volume factor of mic. volumeFactorApp The volume factor of application.
◆ StartVideoModeAsync()
void NRKernal.Record.NRVideoCapture.StartVideoModeAsync | ( | CameraParameters | setupParams, |
OnVideoModeStartedCallback | onVideoModeStartedCallback, | ||
bool | autoAdaptBlendMode = false |
||
) |
Starts video mode asynchronous.
- Parameters
-
setupParams Options for controlling the setup. onVideoModeStartedCallback The on video mode started callback. autoAdaptBlendMode Auto adaption for BlendMode based on supported feature on current device.
◆ StopRecordingAsync()
void NRKernal.Record.NRVideoCapture.StopRecordingAsync | ( | OnStoppedRecordingVideoCallback | onStoppedRecordingVideoCallback | ) |
Stops recording asynchronous.
- Parameters
-
onStoppedRecordingVideoCallback The on stopped recording video callback.
◆ StopVideoModeAsync()
void NRKernal.Record.NRVideoCapture.StopVideoModeAsync | ( | OnVideoModeStoppedCallback | onVideoModeStoppedCallback | ) |
Stops video mode asynchronous.
- Parameters
-
onVideoModeStoppedCallback The on video mode stopped callback.
Property Documentation
◆ IsRecording
|
get |
Indicates whether or not the VideoCapture instance is currently recording video.
True if this object is recording, false if not.
◆ PreviewTexture
|
get |
Gets the preview texture.
The preview texture.
◆ SupportedResolutions
|
staticget |
A list of all the supported device resolutions for recording videos.
The supported resolutions.