MediaFrameSource Class
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Represents a source of media frames, such as a color or infrared camera.
public ref class MediaFrameSource sealed
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 196608)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class MediaFrameSource final
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 196608)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class MediaFrameSource
Public NotInheritable Class MediaFrameSource
- Inheritance
- Attributes
Device family |
Windows 10 Anniversary Edition (introduced in 10.0.14393.0)
|
API contract |
Windows.Foundation.UniversalApiContract (introduced in v3.0)
|
To get an instance of MediaFrameSource, you must first initialize the MediaCapture object with a MediaFrameSourceGroup that includes your desired media frame source. You do this by setting the SourceGroup of the MediaCaptureInitializationSettings object you pass into MediaCapture.InitializeAsync. Next, use the MediaFrameSourceInfo.Id property associated with the desired frame source as the key in the MediaCapture object's FrameSources dictionary to get an instance of the MediaFrameSource object.
For how-to guidance on using MediaFrameSource to capture frames, see Process media frames with MediaFrameReader.
Controller |
Gets the MediaFrameSourceController for the MediaFrameSource. |
Current |
Gets a value indicating the current frame format of the MediaFrameSource. |
Info |
Gets the MediaFrameSourceInfo object that provides information about the MediaFrameSource. |
Supported |
Gets a read-only list of MediaFrameFormat objects representing the frame formats supported by the MediaFrameSource. |
Set |
Asynchronously sets the frame format of the MediaFrameSource. |
Try |
Attempts to retrieve the media frame source's camera intrinsics, which describe a camera's distortion model, for the specified MediaFrameFormat. |
Format |
Occurs when the current frame format of the MediaFrameSource changes. |
Product | Versions |
---|---|
WinRT | Build 14383, Build 15063, Build 16299, Build 17134, Build 17763, Build 18362, Build 19041, Build 20348, Build 22000, Build 22621, Build 26100 |