//***************************************************************************** // // Microsoft Windows Media // Copyright (C) Microsoft Corporation. All rights reserved. // // FileName: streamdescription.idl // // Abstract: // //***************************************************************************** cpp_quote("//*****************************************************************************") cpp_quote("//") cpp_quote("// Microsoft Windows Media") cpp_quote("// Copyright (C) Microsoft Corporation. All rights reserved.") cpp_quote("//") cpp_quote("// Automatically generated by Midl from streamdescription.idl" ) cpp_quote("//") cpp_quote("// DO NOT EDIT THIS FILE.") cpp_quote("//") cpp_quote("//*****************************************************************************") cpp_quote("#if _MSC_VER > 1000") cpp_quote("#pragma once") cpp_quote("#endif // _MSC_VER > 1000") import "objidl.idl"; import "WMSBuffer.idl"; import "WMSContext.idl"; cpp_quote( "EXTERN_GUID( IID_IWMSStreamHeader, 0x3309C903,0x10A4,0x11d2,0x9E,0xEE,0x00,0x60,0x97,0xD2,0xD7,0xCF );" ) cpp_quote( "EXTERN_GUID( IID_IWMSStreamHeaderList, 0x42176202,0x2B30,0x11d2,0x9E,0xF7,0x00,0x60,0x97,0xD2,0xD7,0xCF );" ) cpp_quote( "EXTERN_GUID( IID_IWMSContentDescriptionList, 0x105d6f73, 0x6df0, 0x11d2, 0x9f, 0x14, 0x0, 0x60, 0x97, 0xd2, 0xd7, 0xcf );" ) cpp_quote( "EXTERN_GUID( IID_IWMSStreamSwitchDescriptionList, 0x75c3017c, 0x6b3a, 0x4e25, 0xbe, 0x9f, 0xa9, 0x92, 0x7f, 0x4d, 0xd0, 0x58 );") // {52769631-38AA-11d2-9EFA-006097D2D7CF} cpp_quote( "EXTERN_GUID( IID_IWMSUnknownStreamFormat, 0x52769631, 0x38aa, 0x11d2, 0x9e, 0xfa, 0x0, 0x60, 0x97, 0xd2, 0xd7, 0xcf );") // {52769632-38AA-11d2-9EFA-006097D2D7CF} cpp_quote( "EXTERN_GUID( IID_IWMSUnknownStreamType, 0x52769632, 0x38aa, 0x11d2, 0x9e, 0xfa, 0x0, 0x60, 0x97, 0xd2, 0xd7, 0xcf );") // {52769631-38AA-11d2-9EFA-006097D2D7CF} cpp_quote( "EXTERN_GUID( IID_IWMSUnknownContainerFormat, 0x52769631, 0x38aa, 0x11d2, 0x9e, 0xfa, 0x0, 0x60, 0x97, 0xd2, 0xd7, 0xcf );") interface IWMSContentDescriptionList; ////////////////////////////////////////////////////////////////////////////// // // HEADERS // ////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// // // This describes the data format of one stream, including the codec. ////////////////////////////////////////////////////////////////////////////// [ object, pointer_default(unique), uuid(3309C903-10A4-11d2-9EEE-006097D2D7CF), version(9.0), helpstring("Contains methods that describe the header for a specific stream.") ] interface IWMSStreamHeader : IUnknown { // This identifies the stream format. // The GUID for ASF is: { 0x75b22630,0x668e,0x11cf,0xa6,0xd9,0x00,0xaa,0x00,0x62,0xce,0x6c } [helpstring("Retrieves the stream format.")] HRESULT GetFormat( [out] GUID *pFormat ); [helpstring("Specifies the stream format.")] HRESULT SetFormat( [in] GUID Format ); // This tells you whether a stream is audio/video/etc. The GUID's // for audio and video are: //Audio: { 0xD6E229E2,0x35DA,0x11D1,0x90,0x34,0x00,0xA0,0xC9,0x03,0x49,0xBE } //Video: { 0xD6E229E3,0x35DA,0x11D1,0x90,0x34,0x00,0xA0,0xC9,0x03,0x49,0xBE } //Image: {0xD6E229E4,0x35DA,0x11D1,0x90,0x34,0x00,0xA0,0xC9,0x03,0x49,0xBE } //Text: {0xD6E229E6,0x35DA,0x11D1,0x90,0x34,0x00,0xA0,0xC9,0x03,0x49,0xBE } //Script Commands: { 0xD6E229E8,0x35DA,0x11D1,0x90,0x34,0x00,0xA0,0xC9,0x03,0x49,0xBE } // Other GUID's may be defined in a later release. [helpstring("Retrieves the stream type.")] HRESULT GetStreamType( [out] GUID *pStreamType ); [helpstring("Specifies the stream type.")] HRESULT SetStreamType( [in] GUID StreamType ); [helpstring("Retrieves the value for an IWMSStreamHeader integer attribute.")] HRESULT GetIntegerAttribute( [in] DWORD dwAttributeId, [out] DWORD *pdwAttribute ); [helpstring("Specifies the value for an IWMSStreamHeader integer attribute.")] HRESULT SetIntegerAttribute( [in] DWORD dwAttributeId, [in] DWORD dwAttribute ); [helpstring("Retrieves the value for an IWMSStreamHeader string attribute.")] HRESULT GetStringAttribute( [in] DWORD dwAttributeId, [out] BSTR *pszAttribute ); [helpstring("Specifies the value for an IWMSStreamHeader string attribute.")] HRESULT SetStringAttribute( [in] DWORD dwAttributeId, [in] BSTR szAttribute ); [helpstring("Retrieves the value for an extended attribute defined by a plug-in.")] HRESULT GetExtendedAttribute( [in] DWORD dwValueName, [out] VARIANT *pVariantValue ); [helpstring("Specifies the name and value for an extended attribute defined by a plug-in.")] HRESULT SetExtendedAttribute( [in] DWORD dwValueName, [in] VARIANT VariantValue ); [helpstring("Retrieves the name and value for an extended attribute defined by a plug-in.")] HRESULT GetNthExtendedAttribute( [in] DWORD dwIndex, [out] DWORD *pdwValueName, [out] VARIANT *pVariantValue ); [helpstring("Retrieves the number of extended attributes.")] HRESULT GetNumExtendedAttributes( [out] DWORD *pdwValueName ); [helpstring("Creates a copy of the IWMSStreamHeader object.")] HRESULT CloneStreamHeader( [out] IWMSStreamHeader **ppHeader ); }; // IWMSStreamHeader attributes cpp_quote("#define WMS_STREAM_ID 0") cpp_quote("#define WMS_STREAM_MIN_BITRATE 1") cpp_quote("#define WMS_STREAM_MAX_BITRATE 2") cpp_quote("#define WMS_STREAM_AVG_BITRATE 3") cpp_quote("#define WMS_STREAM_MAX_PACKET_SIZE 4") cpp_quote("#define WMS_STREAM_AVG_PACKET_SIZE 5") cpp_quote("#define WMS_STREAM_PREROLL 6") cpp_quote("#define WMS_STREAM_FLAGS 7") cpp_quote("#define WMS_STREAM_NAME 8") cpp_quote("#define WMS_STREAM_SHARING_GROUP 9") cpp_quote("#define WMS_STREAM_SHARING_BANDWIDTH 10") // Increase this value when you add a IWMSStreamHeader attribute above. cpp_quote("#define WMS_NUM_STREAMHEADER_ATTRIBUTES 11") // Flags stored in WMS_STREAM_FLAGS cpp_quote("#define WMS_STREAM_HAS_NON_KEY_FRAMES 0x0001") cpp_quote("#define WMS_STREAM_RELIABLE_FLAG 0x0002") cpp_quote("#define WMS_STREAM_CONCEALED_FLAG 0x0004") // Some values used for streaming decisions independent of protocol cpp_quote("#define WMS_ASF_THRESHOLD_DURATION 500") ////////////////////////////////////////////////////////////////////////////// [ object, pointer_default(unique), uuid(42176202-2B30-11d2-9EF7-006097D2D7CF), version(9.0), helpstring("Contains a collection of IWMSStreamHeader objects and methods that describe each stream in a multimedia stream.") ] interface IWMSStreamHeaderList : IUnknown { [helpstring("Retrieves the number of IWMSStreamHeader objects in the collection")] HRESULT GetHeaderCount( [out] DWORD *pdwNumHeaders ); [helpstring("Retrieves an IWMSStreamHeader object.")] HRESULT GetHeader( [in] DWORD dwHeaderNum, [out] IWMSStreamHeader **ppHeader ); [helpstring("Adds a new IWMSStreamHeader object to the collection.")] HRESULT AppendHeader( [in] IWMSStreamHeader *pHeader ); [helpstring("Removes all IWMSStreamHeader objects in the collection.")] HRESULT RemoveAllHeaders(); // This identifies the stream format. // The GUID for ASF is: { 0x75b22630,0x668e,0x11cf,0xa6,0xd9,0x00,0xaa,0x00,0x62,0xce,0x6c } [helpstring("Retrieves the stream format for the multimedia stream.")] HRESULT GetContainerFormat( [out] GUID *pFormat ); [helpstring("Specifies the stream format for the multimedia stream.")] HRESULT SetContainerFormat( [in] GUID Format ); [helpstring("Retrieves the unique identifier for the multimedia stream.")] HRESULT GetDataVersion( [out] GUID *pFormat ); [helpstring("Specifies the unique identifier for the multimedia stream.")] HRESULT SetDataVersion( [in] GUID Format ); [helpstring("Retrieves the actual header for the multimedia stream.")] HRESULT GetNativeContainerHeader( [out] INSSBuffer **ppBuffer, [out] DWORD *pdwOffset, [out] DWORD *pdwLength ); [helpstring("Specifies the actual header for the multimedia stream.")] HRESULT SetNativeContainerHeader( [in] INSSBuffer *pBuffer, [in] DWORD dwOffset, [in] DWORD dwLength ); [helpstring("Retrieves the IWMSContentDescriptionList associated with this IWMSStreamHeaderList object.")] HRESULT GetContentDescription( [out] IWMSContentDescriptionList **ppDescription ); [helpstring("Specifies the IWMSContentDescriptionList associated with this IWMSStreamHeaderList object.")] HRESULT SetContentDescription( [in] IWMSContentDescriptionList *pDescription ); [helpstring("Retrieves the value for an IWMSStreamHeaderList integer attribute.")] HRESULT GetIntegerAttribute( [in] DWORD dwAttributeId, [out] DWORD *pdwAttribute ); [helpstring("Specifies the value for an IWMSStreamHeaderList integer attribute.")] HRESULT SetIntegerAttribute( [in] DWORD dwAttributeId, [in] DWORD dwAttribute ); [helpstring("Retrieves the value for an IWMSStreamHeaderList string attribute.")] HRESULT GetStringAttribute( [in] DWORD dwAttributeId, [out] BSTR *pszAttribute ); [helpstring("Specifies the value for an IWMSStreamHeaderList string attribute.")] HRESULT SetStringAttribute( [in] DWORD dwAttributeId, [in] BSTR szAttribute ); [helpstring("Retrieves the value for an extended attribute defined by a plug-in for this IWMSStreamHeaderList object.")] HRESULT GetExtendedAttribute( [in] DWORD dwValueName, [out] VARIANT *pVariantValue ); [helpstring("Specifies the name and value for an extended attribute defined by a plug-in for this IWMSStreamHeaderList object.")] HRESULT SetExtendedAttribute( [in] DWORD dwValueName, [in] VARIANT VariantValue ); [helpstring("Retrieves the name and value for an extended attribute defined by a plug-in for this IWMSStreamHeaderList object.")] HRESULT GetNthExtendedAttribute( [in] DWORD dwIndex, [out] DWORD *pdwValueName, [out] VARIANT *pVariantValue ); [helpstring("Retrieves the number of extended attributes.")] HRESULT GetNumExtendedAttributes( [out] DWORD *pdwValueName ); [helpstring("Creates a copy of the IWMSStreamHeaderList object.")] HRESULT CloneStreamHeaderList( [in] IWMSBufferAllocator *pBufferAllocator, [out] IWMSStreamHeaderList **ppHeader ); [helpstring("Specifies the playlist generation ID that identifies the playlist entry that a command from a client is associated with.")] HRESULT RecordPlaylistGenerationId( [in] IWMSCommandContext *pCommand ); [helpstring("Retrieves the playlist generation ID that identifies the playlist entry that a command from a client is associated with.")] HRESULT CheckPlaylistGenerationId( [in] IWMSCommandContext *pCommand ); }; // Attributes used by IWMSStreamHeaderList::GetIntegerAttribute and // IWMSStreamHeaderList::SetIntegerAttribute cpp_quote("#define WMS_TOTAL_MIN_BITRATE 0") cpp_quote("#define WMS_TOTAL_MAX_BITRATE 1") cpp_quote("#define WMS_TOTAL_AVG_BITRATE 2") cpp_quote("#define WMS_CONTAINER_FLAGS 3") cpp_quote("#define WMS_CONTAINER_DURATION_LO 4") cpp_quote("#define WMS_CONTAINER_DURATION_HI 5") cpp_quote("#define WMS_CONTAINER_MAX_PACKET_SIZE 6") cpp_quote("#define WMS_CONTAINER_PLAYLIST_ENTRY_NAME 7") cpp_quote("#define WMS_TOTAL_PACKETS_LO 8") cpp_quote("#define WMS_TOTAL_PACKETS_HI 9") cpp_quote("#define WMS_STREAM_PLAYLIST_GENERATION_ID 10") cpp_quote("#define WMS_CONTAINER_FILESIZE_LO 11") cpp_quote("#define WMS_CONTAINER_FILESIZE_HI 12") cpp_quote("#define WMS_STREAM_DISTRIBUTION_PLAYLIST_GENERATION_ID 13") cpp_quote("#define WMS_CONTAINER_LOG_PHYSICAL_URL 14") cpp_quote("#define WMS_CONTAINER_IS_VBR 15") cpp_quote("#define WMS_STREAM_BROADCAST_GENERATION_ID 16") cpp_quote("#define WMS_STREAM_DISTRIBUTION_BROADCAST_GENERATION_ID 17") // Increase this value when you add an attribute to StreamheaderList. cpp_quote("#define WMS_NUM_STREAMHEADERLIST_ATTRIBUTES 18") // Flags stored in WMS_CONTAINER_FLAGS attribute. cpp_quote("#define WMS_CONTAINER_BROADCAST 0x0001") cpp_quote("#define WMS_CONTAINER_CANSEEK 0x0002") cpp_quote("#define WMS_CONTAINER_CANSTRIDE 0x0004") cpp_quote("#define WMS_CONTAINER_LIVE 0x0008") cpp_quote("#define WMS_CONTAINER_RECORDABLE 0x0010") cpp_quote("#define WMS_CONTAINER_PART_OF_PLAYLIST 0x0020") cpp_quote("#define WMS_CONTAINER_ONDEMAND_PLAYLIST_EMULATING_BCAST 0x0040") cpp_quote("#define WMS_CONTAINER_PART_OF_WRAPPER_PLAYLIST 0x0080") cpp_quote("#define WMS_CONTAINER_ALLOW_PLAYLIST_SKIP_FORWARD 0x0100") cpp_quote("#define WMS_CONTAINER_ALLOW_PLAYLIST_SKIP_BACKWARD 0x0200") cpp_quote("#define WMS_CONTAINER_SEEKABLE_EMULATING_BROADCAST 0x0400") cpp_quote("#define WMS_CONTAINER_LAST_ENTRY_IN_PLAYLIST 0x0800") ////////////////////////////////////////////////////////////////////////////// // // CONTENT DESCRIPTIONS // ////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////// [ object, pointer_default(unique), uuid(105D6F73-6DF0-11d2-9F14-006097D2D7CF), version(9.0), helpstring("Contains a collection of content description contexts for different languages.") ] interface IWMSContentDescriptionList : IUnknown { [helpstring("Retrieves the number of content descriptions contexts in the collection.")] HRESULT GetDescriptionCount( [out] DWORD *pdwNumDescriptions ); [helpstring("Retrieves a specific content description context from the collection by index.")] HRESULT GetIndexedDescription( [in] DWORD dwDescriptionNum, [out] LPWSTR *pstrLanguage, [out] IWMSContext **ppDescription ); [helpstring("Retrieves the content description context for a specific language.")] HRESULT GetDescriptionInLanguage( [in] LPCWSTR pstrLanguage, [out] IWMSContext **ppDescription ); [helpstring("Adds a content description context for a specific language to the collection.")] HRESULT AppendDescription( [in] LPCWSTR pstrLanguage, [in] IWMSContext *pDescription ); [helpstring("Removes all of the context description contexts in the collection.")] HRESULT RemoveAllDescriptions(); [helpstring("Retrieves the playlist generation ID.")] HRESULT GetPlaylistGenid( DWORD *pdwPlaylistGenerationId ); [helpstring("Specifies the playlist generation ID.")] HRESULT SetPlaylistGenid( DWORD dwPlaylistGenerationId ); [helpstring("Retrieves the broadcast ID.")] HRESULT GetBroadcastid( DWORD *pdwPlaylistGenerationId ); [helpstring("Specifies the broadcast ID.")] HRESULT SetBroadcastid( DWORD dwPlaylistGenerationId ); [helpstring("Adds or sets a VARIANT value property for a specific context property in all context description contexts.")] HRESULT SetValueOnAllDescriptions( [in] LPCWSTR pstrName, [in] long lNameHint, [in] VARIANT Value, [in] long lOptions ); [helpstring("Removes the specified property from all context description contexts.")] HRESULT RemoveValueFromAllDescriptions( [in] LPCWSTR pstrName, [in] long lNameHint, [in] long lOptions ); }; ////////////////////////////////////////////////////////////////////////////// // // STREAM SWITCH DATA STRUCTURE // ////////////////////////////////////////////////////////////////////////////// typedef [public] enum { WMS_DATA_STREAM_MIN = 0x00000000, WMS_DATA_STREAM_MAX = 0x0000FFFE, WMS_NO_STREAM = 0x0000FFFF, WMS_RETRANSMISSION_STREAM_MIN = 0x00010000, WMS_RETRANSMISSION_STREAM_MAX = 0x0001FFFE, WMS_FEC_STREAM_MIN = 0x00020000, WMS_FEC_STREAM_MAX = 0x0002FFFE } WMS_STREAM_CONSTANTS; cpp_quote( "#define IS_DATA_STREAM(x) ( ( x ) >= WMS_DATA_STREAM_MIN && ( x ) <= WMS_DATA_STREAM_MAX )" ) cpp_quote( "#define IS_RETRANSMISSION_STREAM(x) ( ( x ) >= WMS_RETRANSMISSION_STREAM_MIN && ( x ) <= WMS_RETRANSMISSION_STREAM_MAX )" ) cpp_quote( "#define IS_FEC_STREAM(x) ( ( x ) >= WMS_FEC_STREAM_MIN && ( x ) <= WMS_FEC_STREAM_MAX )" ) ////////////////////////////////////////// typedef [public] enum { WMS_NO_MODIFIER = 0, WMS_THINNING_MODIFIER = 1, WMS_REMOVE_ALL_FRAMES_MODIFIER = 2 } WMS_STREAM_MODIFIERS; ////////////////////////////////////////// // WMS_THINNING_MODIFIER typedef [public] enum { WMS_NO_THINNING = 0, WMS_INTERMEDIATE_FRAME_THINNING = 1, WMS_REMOVE_ALL_FRAMES = 2 } WMS_THINNING_MODIFIER_TYPES; ////////////////////////////////////////// typedef struct CWMSStreamSwitch { WORD wPlaylistSequenceNumber; DWORD dwOldStreamNumber; DWORD dwNewStreamNumber; WMS_STREAM_MODIFIERS ModifierType; DWORD dwModifier; DWORD dwPredictiveStreamSelections; } CWMSStreamSwitch; ////////////////////////////////////////////////////////////////////////////// // // IWMSStreamSwitchDescriptionList // ////////////////////////////////////////////////////////////////////////////// [ object, pointer_default(unique), uuid(75C3017C-6B3A-4e25-BE9F-A9927F4DD058), version(9.0), helpstring("Contains methods that control which streams are sent down a data path.") ] interface IWMSStreamSwitchDescriptionList : IUnknown { [helpstring("Retrieves the number of streams described in the stream switch description list.")] HRESULT GetDescriptionCount( [out] DWORD *pdwNumDescriptions ); [helpstring("Retrieves the stream switch description data structure that describes the specified stream.")] HRESULT GetIndexedDescription( [in] DWORD dwDescriptionNum, [out] CWMSStreamSwitch *pStreamSwitchDesc ); [helpstring("Specifies the stream switch description data structure that describes the specified stream.")] HRESULT ChangeIndexedDescription( [in] DWORD dwDescriptionNum, [out] CWMSStreamSwitch *pStreamSwitchDesc ); [helpstring("Removes a stream switch data structure from the collection.")] HRESULT RemoveIndexedDescription( [in] DWORD dwDescriptionNum ); [helpstring("Appends a stream switch description data structure to the collection.")] HRESULT AppendDescription( [in] CWMSStreamSwitch * const pStreamSwitchDesc ); [helpstring("Removes all stream switch description data structures from the collection.")] HRESULT RemoveAllDescriptions( void ); }; ////////////////////////////////////////////////////////////////////////////// // // STREAM SEEK OPTIONS // ////////////////////////////////////////////////////////////////////////////// typedef [public] enum WMS_SEEK_TYPE { WMS_SEEK_TO_TIME = 1, WMS_SEEK_TO_PACKET = 2, WMS_SEEK_TO_PLAYLIST_ENTRY = 3, WMS_SEEK_TO_BYTE_OFFSET = 4, } WMS_SEEK_TYPE;