CapturedFrame Class

Definition

Represents a captured video frame.

public ref class CapturedFrame sealed : IClosable
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.GCPressure]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class CapturedFrame final : IClosable
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.GCPressure]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class CapturedFrame : System.IDisposable
Public NotInheritable Class CapturedFrame
Implements IDisposable
Inheritance
Object Platform::Object IInspectable CapturedFrame
Attributes
Implements

Windows requirements

Device family
Windows 10 (introduced in 10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v1.0)

Remarks

There are several different techniques for capturing photos using the MediaCapture class, including AdvancedPhotoCapture, LowLagPhotoCapture, LowLagPhotoSequenceCapture, and VariablePhotoSequenceCapture. Though the sets of APIs used for each of these techniques vary, ultimately they all return the captured photo to you in the form of a CapturedFrame object.

Version history

Windows version SDK version Value added
1803 17134 BitmapProperties
1803 17134 ControlValues

Properties

BitmapProperties

Gets an object containing bitmap properties for the CapturedFrame. These properties convey image metadata such as EXIF data.

CanRead

Gets a value that indicates if the captured frame can be read from.

CanWrite

Gets a value that indicates if the captured frame can be written to.

ContentType

Gets the content type of the captured frame.

ControlValues

Gets an object containing capture control metadata for the CapturedFrame. Capture controls adjust capture settings such as ISO and exposure.

Height

Gets the height of the captured frame

Position

Gets the position of the captured frame.

Size

Gets the size of the captured frame in bytes.

SoftwareBitmap

Gets a SoftwareBitmap object representing the captured frame.

Width

Gets the width of the captured frame.

Methods

CloneStream()

Creates a copy of the stream.

Close()

Closes the captured framed object.

Dispose()

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

FlushAsync()

Asynchronously commits and flushes all of the data of the CapturedFrame.

GetInputStreamAt(UInt64)

Gets the input stream at the specified position.

GetOutputStreamAt(UInt64)

Gets the output stream at the specified position.

ReadAsync(IBuffer, UInt32, InputStreamOptions)

Returns an asynchronous byte reader object.

Seek(UInt64)

Seeks the stream to the specified position.

WriteAsync(IBuffer)

Asynchronously writes the specified data to the stream.

Applies to

See also