The IDvdInfo interface enables an application to query for attributes of available digital versatile disc (DVD) titles and the DVD player status. It also allows for control of a DVD player beyond Annex J in the DVD specification.
When to Implement
Do not implement this interface.
When to Use
Use this interface in your application to retrieve details about a DVD video or about the current state of the DVD player filter graph.
Methods in Vtable Order
IUnknown methods | Description |
QueryInterface | Retrieves pointers to supported interfaces. |
AddRef | Increments the reference count. |
Release | Decrements the reference count. |
IDvdInfo methods | Description |
GetCurrentDomain | Retrieves the current DVD domain of the DVD player. |
GetCurrentLocation | Retrieves the current playback location. |
GetTotalTitleTime | Retrieves the total playback time for the current title. |
GetCurrentButton | Retrieves the number of available buttons and the currently selected button number. |
GetCurrentAngle | Retrieves the number of available angles and the currently selected angle number. |
GetCurrentAudio | Retrieves the number of available audio streams and the number of the currently selected audio stream. |
GetCurrentSubpicture | Retrieves the number of available subpicture streams, the currently selected subpicture stream number, and whether the subpicture display is disabled. |
GetCurrentUOPS | Retrieves which IDvdControl methods are valid. |
GetAllSPRMs | Retrieves the current contents of all system parameter registers (SPRMs). |
GetAllGPRMs | Retrieves the current contents of all general parameter registers (GPRMs). |
GetAudioLanguage | Retrieves the language of the specified audio stream within the current title. |
GetSubpictureLanguage | Retrieves the language of the specified subpicture stream within the current title. |
GetTitleAttributes | Retrieves attributes of all video, audio, and subpicture streams for the specified title, including menus. |
GetVMGAttributes | Retrieves attributes of all video, audio, and subpicture streams for video manager (VMG) menus. |
GetCurrentVideoAttributes | Retrieves the video attributes for the current title or menu. |
GetCurrentAudioAttributes | Retrieves the audio attributes for the stream in the current title or menu. |
GetCurrentSubpictureAttributes | Retrieves the video attributes for the stream in the current title or menu. |
GetCurrentVolumeInfo | Retrieves the current DVD volume information. |
GetDVDTextInfo | Retrieves the TXTDT_MG structure, which can contain text descriptions for title name, volume name, producer name, vocalist name, and so on, in various languages. |
GetPlayerParentalLevel | Retrieves the current parental level and country code settings for the DVD player. |
GetNumberOfChapters | Retrieves the number of chapters that are defined for a given title. |
GetTitleParentalLevels | Retrieves the parental levels that are defined for a particular title. |
GetRoot | Retrieves the root directory that is set in the player. |
Retrieves the current contents of all general parameter registers (GPRMs).
HRESULT GetAllGPRMs(
GPRMARRAY *pRegisterArray );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
Use of GPRMs is title specific.
Retrieves the current contents of all system parameter registers (SPRMs).
HRESULT GetAllSPRMs(
SPRMARRAY *pRegisterArray );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
See the DVD video specification for use of individual registers.
Retrieves the language of the specified audio stream within the current title.
HRESULT GetAudioLanguage(
ULONG nStream,
LCID *pLanguage );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
This method does not return languages for menus. This method sets the value pointed to by pLanguage to zero if the stream does not include language. Call the Win32 GetLocaleInfo API as follows to create a human-readable string name from pLanguage:
GetLocaleInfo(*pLanguage, LOCALE_SENGLANGUAGE, pszString, cbSize);
Retrieves the number of available angles and the currently selected angle number.
HRESULT GetCurrentAngle(
ULONG *pnAnglesAvailable,
ULONG *pnCurrentAngle );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
Angles are interleaved video streams that presumably contain the same scene shot with different camera angles.
This method returns an error unless the domain is DVD_DOMAIN_Title.
Retrieves the number of available audio streams and the number of the currently selected audio stream.
HRESULT GetCurrentAudio(
ULONG *pnStreamsAvailable,
ULONG *pnCurrentStream );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
This method returns an error unless the domain is DVD_DOMAIN_Title.
Retrieves the audio attributes for the stream in the current title or menu.
HRESULT GetCurrentAudioAttributes(
DVD_AudioATR *pATR );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
See the DVD video specification for information about DVD_AudioATR.
Retrieves the number of available buttons and the currently selected button number.
HRESULT GetCurrentButton(
ULONG *pnButtonsAvailable,
ULONG *pnCurrentButton );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
If buttons are not present this method returns zero for both pnButtonsAvailable and pnCurrentButton.
Retrieves the current DVD domain of the DVD player.
HRESULT GetCurrentDomain(
DVD_DOMAIN *pDomain );
Returns an HRESULT value that depends on the implementation of the interface. Typical return values might include one of the following:
Value | Meaning |
E_FAIL | Failure. |
E_INVALIDARG | Input argument is invalid. |
E_NOTIMPL | Method is not supported. |
E_OUTOFMEMORY | Out of memory (insufficient buffer space). |
E_POINTER | NULL pointer argument. |
E_UNEXPECTED | DVD is not initialized or domain is not DVD_DOMAIN_Title. |
E_UOP_PROHIBITED | Requested action cannot occur at this point in the movie due to the authoring of the current DVD-Video disc. |
S_OK | Success. |
VFW_E_DVD_INVALIDDOMAIN | Requested action is not supported on this domain (DVD_DOMAIN). |
Retrieves the current playback location.
HRESULT GetCurrentLocation(
DVD_PLAYBACK_LOCATION *pLocation );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
The default implementation of this method returns E_UNEXPECTED if the current domain is not DVD_DOMAIN_Title.
This method retrieves information sufficient to restart playback of a video from the current playback location in titles that don't explicitly disable seeking to the current location.
This method returns an error unless the domain is DVD_DOMAIN_Title.
Retrieves the number of available subpicture streams, the currently selected subpicture stream number, and whether the subpicture display is disabled.
HRESULT GetCurrentSubpicture(
ULONG *pnStreamsAvailable,
ULONG *pnCurrentStream,
BOOL *pIsDisabled );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
Subpicture streams authored as forcedly activated streams will be displayed even if the application has disabled subpicture display with the IDvdControl::SubpictureStreamChange method.
This method returns an error unless the domain is DVD_DOMAIN_Title.
Retrieves the video attributes for the stream in the current title or menu.
HRESULT GetCurrentSubpictureAttributes(
DVD_SubpictureATR *pATR );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
See the DVD video specification for information about DVD_SubpictureATR.
Retrieves which IDvdControl methods are currently valid.
HRESULT GetCurrentUOPS(
VALID_UOP_SOMTHING_OR_OTHER *pUOP );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
This method is useful because DVD titles can enable or disable individual user operations at almost any point during playback.
Retrieves the video attributes for the current title or menu.
HRESULT GetCurrentVideoAttributes(
DVD_VideoATR *pATR );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
See the DVD video specification for information about DVD_VideoATR.
Retrieves the current DVD volume information.
HRESULT GetCurrentVolumeInfo(
ULONG *pNumOfVol,
ULONG *pThisVolNum,
DVD_DISC_SIDE *pSide,
ULONG *pNumOfTitles );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
Retrieves the TXTDT_MG structure, which can contain text descriptions for title name, volume name, producer name, vocalist name, and so on, in various languages.
HRESULT GetDVDTextInfo(
BYTE *pTextManager,
ULONG cbBufSize,
ULONG *pcbActualSize );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
If the supplied buffer size in cbBufSize is too small for the data, (for example if cbBufSize equals zero), then this method returns E_OUTOFMEMORY and sets the value pointed to by pcbActualSize to the required size.
Refer to Section 4.1.6 and Annex A of the DVD video specification for more information.
Retrieves the number of chapters that are defined for a given title.
HRESULT GetNumberOfChapters(
ULONG ulTitle,
ULONG *pNumberOfChapters
);
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
Retrieves the current parental level and country code settings for the DVD player.
HRESULT GetPlayerParentalLevel(
ULONG *pParentalLevel,
ULONG *pCountryCode
);
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
See Table 3.3.4-1 of the DVD video specification for the defined parental levels.
See ISO3166 : Alpha-2 Code for the country codes.
Valid Parental Levels are 1 through 8 if parental management is enabled, 0xffffffff if parental management is disabled.
Retrieves the root directory that is set in the player.
HRESULT GetRoot(
LPTSTR pRoot,
ULONG cbBufSize,
ULONG *pcbActualSize
);
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
If a valid root was found, this method returns the root string. Otherwise, it returns zero for pcbActualSize, indicating that a valid root directory has not been found or initialized.
Retrieves the language of the specified subpicture stream within the current title.
HRESULT GetSubpictureLanguage(
ULONG nStream,
LCID *pLanguage );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
This method does not return languages for menus. This method sets the value pointed to by pLanguage to zero if the stream does not include language. Call the Win32 GetLocaleInfo API as follows to create a human-readable string name from pLanguage.
GetLocaleInfo(*pLanguage, LOCALE_SENGLANGUAGE, pszString, cbSize);
This method returns an error unless the domain is DVD_DOMAIN_Title.
Retrieves attributes of all video, audio, and subpicture streams for the specified title, including menus.
HRESULT GetTitleAttributes(
ULONG nTitle,
DVD_ATR *pATR );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
Retrieves the parental levels that are defined for a particular title.
HRESULT GetTitleParentalLevels(
ULONG ulTitle,
ULONG *pParentalLevels
);
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
Retrieves the total playback time for the current title.
HRESULT GetTotalTitleTime(
ULONG *pTotalTime );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
This method works only for simple linear movies.
Retrieves attributes of all video, audio, and subpicture streams for video manager (VMG) menus.
HRESULT GetVMGAttributes(
DVD_ATR *pATR );
Returns an HRESULT value that depends on the implementation of the interface. See IDvdInfo::GetCurrentDomain for a list of typical return values for the methods exposed by this interface.
The video manager contains a separate group of streams, such as the DVD_MENU_Title menus and are not associated with any particular title number.
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.