IWMEncSource.PostviewCollection
The PostviewCollection property retrieves a collection of postview objects for the source stream.
Syntax
IWMEncDataViewCollection = IWMEncSource.PostviewCollection
Parameters
This property takes no parameters.
Property Value
An IWMEncDataViewCollection object, which is a collection of postview objects.
Remarks
This property is read-only. A postview is a WMEncDataView object that renders content in a window after the content has been both compressed and decompressed. Postviews more closely approximate the appearance of the output in Windows Media Player.
To display previews and postviews, you must add the Windows Media Encoder Preview Control reference to the project. For more information, see Programming in Visual Basic.
Example Code
' Create a WMEncoder object.
Dim Encoder As WMEncoder
Set Encoder = New WMEncoder
' Configure the encoding session including the input sources,
' the profile, and the output.
' Retrieve an IWMEncDataViewCollection object from the
' video source object to display a postview.
Dim DVColl_Postview As IWMEncDataViewCollection
Set DVColl_Postview = SrcVid.PostviewCollection
' Create a WMEncDataView object.
Dim PostView As WMEncDataView
Set PostView = New WMEncDataView
' Add the WMEncDataView object to the collection.
Dim lPostviewStream As Long
lPostviewStream = DVColl_Postview.Add(PostView)
' Start encoding.
Encoder.Start
' Display the stream postview in a frame called PostviewFrame.
PostView.SetViewProperties lPostviewStream, PostviewFrame.hWnd
PostView.StartView (lPostviewStream)
Requirements
Reference: Windows Media Encoder
Library: wmenc.exe
See Also