MediaDeviceCriteria
static class NatML.Devices.MediaDeviceCriteria
NatDevice includes a set of pre-defined filters which are commonly used to discover devices.
/// <summary>
/// Filter for hardware audio devices.
/// </summary>
static Predicate<IMediaDevice> AudioDevice { get; }
/// <summary>
/// Filter for hardware camera devices.
/// </summary>
static Predicate<IMediaDevice> CameraDevice { get; }
/// <summary>
/// Filter for internal devices.
/// </summary>
static Predicate<IMediaDevice> Internal { get; }
This will filter for internal media devices.
/// <summary>
/// Filter for external devices.
/// </summary>
static Predicate<IMediaDevice> External { get; }
This will filter for external media devices.
/// <summary>
/// Filter for default devices for their respective media types.
/// </summary>
static Predicate<IMediaDevice> Default { get; }
For a given media device type, a default device is not guaranteed to exist. As a result, do not expect to always discover a default device.
/// <summary>
/// Filter for audio devices that perform echo cancellation.
/// </summary>
static Predicate<IMediaDevice> EchoCancellation { get; }
This will filter for audio devices that perform echo cancellation.
/// <summary>
/// Filter for rear-facing camera devices.
/// </summary>
static Predicate<IMediaDevice> RearCamera { get; }
This will filter for camera devices that are rear-facing.
/// <summary>
/// Filter for front-facing camera devices.
/// </summary>
static Predicate<IMediaDevice> FrontCamera { get; }
This will filter for camera devices that are front-facing.
/// <summary>
/// Filter for camera devices that have torches.
/// </summary>
static Predicate<IMediaDevice> Torch { get; }
This will filter for camera devices that possess torch units.
/// <summary>
/// Filter for devices that meet any of the provided criteria.
/// </summary>
/// <param name="criteria">Criteria to meet.</param>
static Predicate<IMediaDevice> Any (params Predicate<IMediaDevice>[] criteria);
This will filter for media devices that meet any of the provided criteria.
/// <summary>
/// Filter for devices that meet all of the provided criteria.
/// </summary>
/// <param name="criteria">Criteria to meet.</param>
static Predicate<IMediaDevice> All (params Predicate<IMediaDevice>[] criteria);
This will filter for media devices that meet all of the provided criteria.
Last modified 1yr ago