Share via


MediaTranscoder Class

Definition

Transcodes audio and video files.

public ref class MediaTranscoder sealed
/// [Windows.Foundation.Metadata.Activatable(65536, Windows.Foundation.UniversalApiContract)]
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
class MediaTranscoder final
/// [Windows.Foundation.Metadata.ContractVersion(Windows.Foundation.UniversalApiContract, 65536)]
/// [Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
/// [Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
/// [Windows.Foundation.Metadata.Activatable(65536, "Windows.Foundation.UniversalApiContract")]
class MediaTranscoder final
[Windows.Foundation.Metadata.Activatable(65536, typeof(Windows.Foundation.UniversalApiContract))]
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
public sealed class MediaTranscoder
[Windows.Foundation.Metadata.ContractVersion(typeof(Windows.Foundation.UniversalApiContract), 65536)]
[Windows.Foundation.Metadata.MarshalingBehavior(Windows.Foundation.Metadata.MarshalingType.Agile)]
[Windows.Foundation.Metadata.Threading(Windows.Foundation.Metadata.ThreadingModel.Both)]
[Windows.Foundation.Metadata.Activatable(65536, "Windows.Foundation.UniversalApiContract")]
public sealed class MediaTranscoder
function MediaTranscoder()
Public NotInheritable Class MediaTranscoder
Inheritance
Object Platform::Object IInspectable MediaTranscoder
Attributes

Windows requirements

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

Remarks

For how-to guidance on transcoding media files, see Transcode media files.

Constructors

MediaTranscoder()

Creates a new instance of the MediaTranscoder class.

Properties

AlwaysReencode

Specifies whether the media transcoder always re-encodes the source.

HardwareAccelerationEnabled

Specifies whether hardware acceleration is enabled.

TrimStartTime

Gets or sets the time interval to trim from the start of the output.

TrimStopTime

Gets or sets the time interval to trim from the end of the output.

VideoProcessingAlgorithm

Gets or sets the video processing algorithm which will be used for transcoding.

Methods

AddAudioEffect(String, Boolean, IPropertySet)

Adds the specified audio effect with configuration properties, and indicates whether the effect is required.

AddAudioEffect(String)

Adds the specified audio effect.

AddVideoEffect(String, Boolean, IPropertySet)

Adds the specified video effect with configuration properties and indicates whether the effect is required.

AddVideoEffect(String)

Adds the specified video effect.

ClearEffects()

Removes all audio and video effects from the transcode session.

PrepareFileTranscodeAsync(IStorageFile, IStorageFile, MediaEncodingProfile)

Asynchronously initializes the trancode operation on the specified file and returns a PrepareTranscodeResult object which can be used to start the transcode operation.

PrepareMediaStreamSourceTranscodeAsync(IMediaSource, IRandomAccessStream, MediaEncodingProfile)

Asynchronously initializes the trancode operation on the specified media source and returns a PrepareTranscodeResult object which can be used to start the transcode operation.

PrepareStreamTranscodeAsync(IRandomAccessStream, IRandomAccessStream, MediaEncodingProfile)

Asynchronously initializes the trancode operation on the specified stream and returns a PrepareTranscodeResult object which can be used to start the transcode operation.

Applies to

See also