Microsoft DirectX 8.0 |
The IBasicVideo2 interface derives from IBasicVideo and provides an additional method for applications to retrieve the preferred aspect ratio of the video stream. The interface is implemented on the Video Renderer filter but exposed to applications on the Filter Graph Manager. See IBasicVideo for more detailed information.
Methods in Vtable Order
IUnknown methods Description QueryInterface Retrieves pointers to supported interfaces. AddRef Increments the reference count. Release Decrements the reference count. IDispatch methods Description GetTypeInfoCount Determines whether there is type information available for this dispinterface. GetTypeInfo Retrieves the type information for this dispinterface if GetTypeInfoCount returned successfully. GetIDsOfNames Converts text names of properties and methods (including arguments) to their corresponding DISPIDs. Invoke Calls a method or accesses a property in this dispinterface if given a DISPID and any other necessary parameters. IBasicVideo methods Description get_AvgTimePerFrame Retrieves the average time between successive frames in 100-nanosecond units. get_BitRate Retrieves an approximate bit rate for the video stream. get_BitErrorRate Retrieves an approximate bit error rate for the video stream. get_VideoWidth Retrieves the current video width. get_VideoHeight Retrieves the current video height. put_SourceLeft Sets the x-axis coordinate for the source video rectangle. get_SourceLeft Retrieves the x-axis coordinate for the source video rectangle. put_SourceWidth Sets the width of the source video rectangle. get_SourceWidth Retrieves the width of the source video rectangle. put_SourceTop Sets the y-axis coordinate for the source video rectangle. get_SourceTop Retrieves the y-axis coordinate for the source video rectangle. put_SourceHeight Sets the height of the source video rectangle. get_SourceHeight Retrieves the height of the source video rectangle. put_DestinationLeft Sets the x-axis coordinate for the destination video rectangle. get_DestinationLeft Retrieves the x-axis coordinate for the destination video rectangle. put_DestinationWidth Sets the width of the destination video rectangle. get_DestinationWidth Retrieves the width of the destination video rectangle. put_DestinationTop Sets the y-axis coordinate for the destination video rectangle. get_DestinationTop Retrieves the y-axis coordinate for the destination video rectangle. put_DestinationHeight Sets the height of the destination video rectangle. get_DestinationHeight Retrieves the height of the destination video rectangle. SetSourcePosition Sets the source video rectangle. GetSourcePosition Retrieves the source video rectangle. SetDefaultSourcePosition Informs the renderer to use the default source rectangle. SetDestinationPosition Sets the destination rectangle for the window. GetDestinationPosition Retrieves the destination video rectangle for the window. SetDefaultDestinationPosition Sets the default destination position for the window. GetVideoSize Retrieves the native video dimensions. GetVideoPaletteEntries Retrieves the color palette entries required by the video. GetCurrentImage Returns a copy of the current image that is waiting at the renderer. IsUsingDefaultSource Determines if the renderer is using the default source rectangle. IsUsingDefaultDestination Determines if the renderer is using the default destination rectangle. IBasicVideo2 methods Description GetPreferredAspectRatio Retrieves the movie's preferred aspect ratio.
Retrieves a pair of dimensionless values whose ratio defines the movie's preferred aspect ratio.
Syntax
HRESULT GetPreferredAspectRatio ( long *plAspectX, long *plAspectY );
Parameters
- plAspectX
- [out] Pointer to a value that indicates the movie's x-axis aspect ratio.
- plAspectY
- [out] Pointer to a value that indicates the movie's y-axis aspect ratio.
Return Value
Returns an HRESULT value that depends on the implementation of the interface.
The current DirectShow implementation return values include the following:
S_OK Success. E_INVALIDARG One or both of the parameters are invalid. E_NOINTERFACE The renderer does not implement IBasicVideo2.
Remarks
See the VIDEOINFOHEADER2 structure documentation for more information on movie aspect ratios.