MPLATFORMLib Namespace > MComposerClass Class : FormatAudioSet Method |
Public Overridable Sub FormatAudioSet( _ ByVal _eFormatType As eMFormatType, _ ByRef _pAudProps As M_AUD_PROPS _ )
public virtual void FormatAudioSet( eMFormatType _eFormatType, ref M_AUD_PROPS _pAudProps )
public procedure FormatAudioSet( _eFormatType: eMFormatType; var _pAudProps: M_AUD_PROPS ); virtual;
public: virtual void FormatAudioSet( eMFormatType _eFormatType, ref M_AUD_PROPS _pAudProps )
Here is example of how to set custom format to the playlist:
Dim nIndex As Integer Dim strFormat As String Dim audProps As M_AUD_PROPS Dim myPlaylist As New MPlaylistClass() myPlaylist.FormatAudioGet(eMFormatType.eMFT_Output, audProps, nIndex, strFormat) audProps.nSamplesPerSec = 48000 myPlaylist.FormatAudioSet(eMFormatType.eMFT_Convert, audProps)
int nIndex; string strFormat; M_AUD_PROPS audProps; MPlaylistClass myPlaylist = new MPlaylistClass(); myPlaylist.FormatAudioGet(eMFormatType.eMFT_Output, out audProps, out nIndex, out strFormat); audProps.nSamplesPerSec = 48000; myPlaylist.FormatAudioSet(eMFormatType.eMFT_Convert, ref audProps);
var m_objPlaylist;; m_pFormat; audProps: M_AUD_PROPS; strFormat: string; nIndex: integer; begin m_objPlaylist:= CreateComObject(CLASS_MPlaylist) as MPlaylist; m_pFormat := m_objPlaylist as IMFormat; m_pFormat.FormatAudioGet(eMFT_Output, audProps, nIndex, strFormat); audPorps.nSamplesPerSec := 48000; m_pFormat.FormatAudioSet(eMFT_Convert, audProps); end;