Edit

Share via


CameraHelper Class

Definition

Helper class for capturing frames from available camera sources. Make sure you have the capability webcam enabled for your app to access the device's camera.

public class CameraHelper : IDisposable
type CameraHelper = class
    interface IDisposable
Public Class CameraHelper
Implements IDisposable
Inheritance
CameraHelper
Implements

Constructors

CameraHelper()

Properties

FrameFormatsAvailable

Gets a list of Windows.Media.Capture.Frames.MediaFrameFormat available on the source.

FrameSourceGroup

Gets or sets the source group for camera video preview.

PreviewFrameSource

Gets the currently selected Windows.Media.Capture.Frames.MediaFrameSource for video preview.

Methods

CleanUpAsync()

Clean up the Camera Helper resources

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

GetFrameSourceGroupsAsync()

Gets a list of Windows.Media.Capture.Frames.MediaFrameSourceGroup available for video preview or video record.

InitializeAndStartCaptureAsync()

Initializes Camera Media Capture settings and initializes Frame Reader to capture frames in real time. If no MediaFrameSourceGroup is provided, it selects the first available camera source to use for media capture. You could select a specific MediaFrameSourceGroup from the available sources using the CameraHelper FrameSourceGroups property.

Events

FrameArrived

Occurs when a new frame arrives.

Applies to