WMEncoder Object

Windows Media Encoder SDK banner art

The WMEncoder object runs the encoding process. If you are implementing the predefined user interface (UI), you must create a WMEncoder object through a WMEncoderApp object. If you are not implementing a UI or are implementing a custom UI, you must independently create a WMEncoder object.

Use this object to respond to run-time errors, configuration changes, and state changes.

Note   Do not perform blocking actions when the encoding process is firing events, since you will not be able to receive the events in a timely manner. For example, do not create a modal dialog box when events are being fired.

The WMEncoder object exposes the following properties, methods, and events.

Property Description
ArchiveState Retrieves a value indicating whether the archiving process is running.
Attributes Retrieves a collection of user-defined name-value pairs.
AutoIndex Specifies and retrieves a value indicating whether the archive file will be indexed after the archiving process is completed.
AutoStop Specifies and retrieves a value that indicates whether the encoding process will be automatically stopped after source content from the media file has been completely encoded.
Broadcast Retrieves the port number and protocol for broadcasting encoded content.
ContentAnalyzer Retrieves an IWMEncContentAnalyzer object that can be used to analyze the video content in a source group.
DeviceControlPluginInfoManager Retrieves a collection of objects that contain device control plug-in information.
DisplayInfo Retrieves a description of the encoded content. Typically this includes author, copyright, rating and title information.
EnableAutoArchive Specifies and retrieves a value indicating whether the archiving process will start automatically when the encoding process starts.
EnableTimecode Specifies and retrieves a Boolean value indicating whether the output will contain a time code.
EncoderDRMContentAuthor Retrieves an IWMDRMContentAuthor object that can be used to protect content using digital rights management (DRM).
ErrorState Retrieves run-time errors for the encoding process.
File Retrieves an IWMEncFile object that can be used to specify the name of an archive file.
IndexerState The index is added during the encoding process and is no longer a separate process. This property is provided for backward-compatibility.
Name Retrieves the unique name of a WMEncoder object for remote administration.
PreserveSourceTimecode Specifies and retrieves a value indicating whether the content's original time code will be used in the output.
ProfileCollection Retrieves the collection of profiles.
RecordingLevel Specifies and retrieves the volume level of a specific audio source stream.
RecordingMute Specifies and retrieves a Boolean value indicating whether a specific audio stream is muted.
RemoteAdmin Retrieves a value indicating whether the encoding application can be remotely controlled.
RunState Retrieves a value indicating whether the encoding process is running.
SourceGroupCollection Retrieves the collection of source groups.
SourcePluginInfoManager Retrieves a collection of objects that contain source plug-in information.
StartingTimecode Specifies and retrieves the value at which to start the time code when the original time code is not used.
Statistics Retrieves an IWMEncStatistics object that can be used to provide status information about the encoding session.
SynchronizeOperation Specifies and retrieves a Boolean indicating whether the start of the encoding process is synchronized with device setup.
TimecodeFrameRate Specifies and retrieves the time code of the frame rate for the encoding session when generating a new time code for the output.
TransformPluginInfoManager Retrieves a collection of objects that contain transform plug-in information.
VideoComplexity Specifies and retrieves the video complexity setting.
WatermarkCollection Retrieves the collection of watermarks.
Method Description
Archive Starts, pauses, or stops the archiving process.
Flush Ignores the samples that have been stored in memory and on disk.
GenerateBroadcastInfo Configures the encoding session to facilitate the creation of a multicast publishing point.
GetAudioLevel Not implemented in this release.
GetWatermark Retrieves the name of a watermark used in the current encoding session.
Indexer Cancels the indexing process before it is complete.
InsertCleanpoint Inserts a clean point into the video stream.
Load Loads an existing configuration from a file.
Pause Pauses the encoding process.
PrepareToEncode Initializes the encoding process for starting.
Reset Eliminates the current configuration settings.
Save Saves the current configuration to a file.
SendScript Sends script.
SetLocaleID Specifies the national language displayed in the user interface.
SetWatermark Specifies the watermark to use in the current encoding session.
Start Starts the encoding process.
Stop Stops the encoding process.
Event Description
OnAcquireCredentials Retrieves a Boolean value indicating whether to cache the user name and password used for connecting to a publishing point on a Windows Media server.
OnArchiveStateChange Receives an event notice indicating a change in the archiving state.
OnClientConnect Receives an event notice indicating that a client has connected to the encoding application.
OnClientDisconnect Receives an event notice indicating that a client has disconnected from the encoding application.
OnClientDNSNameResolved Returns the Domain Name Service (DNS) name of the client connected to the computer running the encoding application.
OnConfigChange Receives an event notice indicating a change in the encoding configuration.
OnDeviceControlStateChange Indicates the state of the external digital device.
OnError Receives run-time error event notices.
OnIndexerStateChange The index is added during the encoding process and is no longer a separate process. This event is provided for backward-compatibility.
OnSourceStateChange Receives an event notice indicating whether a specific input stream has started or stopped sending data to the encoding process.
OnStateChange Receives an event notice indicating whether the encoding application has been started or stopped.

See Also