PerceptionColorFrameSourceWatcher PerceptionColorFrameSourceWatcher PerceptionColorFrameSourceWatcher PerceptionColorFrameSourceWatcher Class

Definition

Monitors changes to the list of color frame sources, and provides notifications when the list changes.

public : sealed class PerceptionColorFrameSourceWatcher : IPerceptionColorFrameSourceWatcherpublic sealed class PerceptionColorFrameSourceWatcher : IPerceptionColorFrameSourceWatcherPublic NotInheritable Class PerceptionColorFrameSourceWatcher Implements IPerceptionColorFrameSourceWatcher// You can use this class in JavaScript.
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Properties

Status Status Status Status

Gets the operational status of the color frame source watcher.

public : DeviceWatcherStatus Status { get; }public DeviceWatcherStatus Status { get; }Public ReadOnly Property Status As DeviceWatcherStatus// You can use this property in JavaScript.
Value
DeviceWatcherStatus DeviceWatcherStatus DeviceWatcherStatus DeviceWatcherStatus

A DeviceWatcherStatus enumeration value indicating the status of the color frame source watcher.

Methods

Start() Start() Start() Start()

When this method is called, the color frame source watcher enumerates any existing color frame sources it has not already enumerated by firing a SourceAdded event for each one. An EnumerationCompleted event is fired when this enumeration is complete. The color frame source then starts watching for new color frame sources.

public : void Start()public void Start()Public Function Start() As void// You can use this method in JavaScript.

Stop() Stop() Stop() Stop()

When this method is called, the color frame source watcher stops looking for changes to the color frame source list. This operation is not immediate; the Stopped event will be triggered when the Stop operation is complete.

public : void Stop()public void Stop()Public Function Stop() As void// You can use this method in JavaScript.

Events

EnumerationCompleted EnumerationCompleted EnumerationCompleted EnumerationCompleted

Subscribes to the EnumerationCompleted event. This event is fired after the initial enumeration of known color frame sources is complete.

public : event TypedEventHandler EnumerationCompleted<PerceptionColorFrameSourceWatcher,  object>public event TypedEventHandler EnumerationCompleted<PerceptionColorFrameSourceWatcher,  object>Public Event EnumerationCompleted<PerceptionColorFrameSourceWatcher,  object>// You can use this event in JavaScript.

SourceAdded SourceAdded SourceAdded SourceAdded

Subscribes to the SourceAdded event.

public : event TypedEventHandler SourceAdded<PerceptionColorFrameSourceWatcher,  PerceptionColorFrameSourceAddedEventArgs>public event TypedEventHandler SourceAdded<PerceptionColorFrameSourceWatcher,  PerceptionColorFrameSourceAddedEventArgs>Public Event SourceAdded<PerceptionColorFrameSourceWatcher,  PerceptionColorFrameSourceAddedEventArgs>// You can use this event in JavaScript.

Remarks

When the Start method is called, this event is fired for every color frame source already known to the system, then the EnumerationCompleted event is fired. New color frame sources that are subsequently added will trigger additional SourceAdded events.

SourceRemoved SourceRemoved SourceRemoved SourceRemoved

Subscribes to the SourceRemoved event. This event is fired once for every color frame source that is removed.

public : event TypedEventHandler SourceRemoved<PerceptionColorFrameSourceWatcher,  PerceptionColorFrameSourceRemovedEventArgs>public event TypedEventHandler SourceRemoved<PerceptionColorFrameSourceWatcher,  PerceptionColorFrameSourceRemovedEventArgs>Public Event SourceRemoved<PerceptionColorFrameSourceWatcher,  PerceptionColorFrameSourceRemovedEventArgs>// You can use this event in JavaScript.

Stopped Stopped Stopped Stopped

Subscribes to the Stopped event. This event is fired when the IPerceptionColorFrameSourceWatcher has stopped listening for changes to the list of color frame sources.

public : event TypedEventHandler Stopped<PerceptionColorFrameSourceWatcher,  object>public event TypedEventHandler Stopped<PerceptionColorFrameSourceWatcher,  object>Public Event Stopped<PerceptionColorFrameSourceWatcher,  object>// You can use this event in JavaScript.