Click here to Skip to main content
11,640,599 members (63,025 online)
Click here to Skip to main content
Add your own
alternative version

BSEtunes

, 24 Apr 2010 CPOL 35.8K 3.3K 56
BSEtunes is a MySQL based, full manageable, networkable single or multiuser jukebox application
BSE.Platten.zip
BSE.Platten
BSE.Platten.vssscc
mssccprj.scc
vssver2.scc
BSE.CoverFlow.WPFLib
BSE.CoverFlow.WPFLib.csproj.user
BSE.CoverFlow.WPFLib.csproj.vspscc
mssccprj.scc
vssver2.scc
Images
close.png
exit.png
next.png
next_disabled.png
Note.jpg
pause.png
PlayButton.png
previous.png
previous_disabled.png
stop.png
vssver2.scc
Properties
Settings.settings
vssver2.scc
Resources
vssver2.scc
BSE.Platten.Admin
BSE.Platten.Admin.csproj.vspscc
mssccprj.scc
vssver2.scc
Properties
Settings.settings
vssver2.scc
Resources
Album16.gif
BSEadmin.ico
cdimport.png
cdrip.png
cd_hoeren.png
clearsearch.png
DataContainer_MoveFirsHS.png
DataContainer_MoveLastHS.png
DataContainer_MoveNextHS.png
DataContainer_MovePreviousHS.png
DataContainer_NewRecordHS.png
diskinfo.png
DRIVEDSC.png
DRIVENET.png
Edit_UndoHS.png
exportimage.png
findfile.png
FindHS.png
freedb.png
Genre16.png
Image.png
InsertPictureHS.png
Interpret16.png
OptionsHS.png
PieChart3DHS.png
PieChartHS.png
ProtectFormHS.png
RefreshDocViewHS.png
saveHS.png
search.png
song.png
system.png
tagger.png
tools_16.png
vssver2.scc
BSE.Platten.Admin.WinApp
BSE.Platten.Admin.WinApp.csproj.user
BSE.Platten.Admin.WinApp.csproj.vspscc
mssccprj.scc
vssver2.scc
Properties
Settings.settings
vssver2.scc
Resources
BSEadmin.ico
vssver2.scc
BSE.Platten.Audio
bse.ico
BSE.Platten.Audio.csproj.vspscc
mssccprj.scc
vssver2.scc
Options
vssver2.scc
Player
vssver2.scc
Properties
vssver2.scc
Resources
FillDownHS.png
FillLeftHS.png
Folder256.png
FolderFind.png
FolderOpen256.png
GoLtrHS.png
MoveNext.png
MovePrevious.png
OptionsHS.png
PauseHS.png
PlayHS.png
Slider.gif
Start.png
StopHS.png
vssver2.scc
WinControls
vssver2.scc
WMFSDK
vssver2.scc
BSE.Platten.BO
BSE.Platten.BO.csproj.vspscc
mssccprj.scc
vssver2.scc
Properties
vssver2.scc
BSE.Platten.Common
BSE.Platten.Common.csproj.vspscc
mssccprj.scc
vssver2.scc
Properties
vssver2.scc
Resources
BSEsplash.png
DRIVEDSC.png
DRIVENET.png
Network.png
splash.png
vssver2.scc
BSE.Platten.Covers
BSE.Platten.Covers.csproj.vspscc
mssccprj.scc
vssver2.scc
Properties
Settings.settings
vssver2.scc
BSE.Platten.FreeDb
BSE.Platten.FreeDb.csproj.vspscc
mssccprj.scc
vssver2.scc
Properties
vssver2.scc
Resources
OpenCD.png
vssver2.scc
BSE.Platten.Ripper
BSE.Platten.Ripper.csproj.vspscc
mssccprj.scc
vssver2.scc
Properties
vssver2.scc
Resources
OpenCD.png
OptionsHS.png
vssver2.scc
BSE.Platten.Statistik
BSE.Platten.Statistik.csproj.vspscc
mssccprj.scc
vssver2.scc
Properties
vssver2.scc
BSE.Platten.Tunes
BSE.Platten.Tunes.csproj.user
BSE.Platten.Tunes.csproj.vspscc
mssccprj.scc
vssver2.scc
Filters
vssver2.scc
Properties
Settings.settings
vssver2.scc
Resources
About.png
Album16.gif
AudioCD.png
AudioFile.png
AutoList.png
broadcast.png
BSE.png
BSEAbout.png
BSEsplash.png
BSEtunes.ico
BSE_16.png
cd_hoeren.png
coverflow.png
DataContainer_MoveNextHS.png
delete.gif
diskinfo.png
Filter2HS.png
FindHS.png
Folder256.png
FolderOpen256.png
Genre16.gif
Interpret16.gif
keinBild.gif
NewPlaylist16.gif
OptionsHS.png
PauseHS.png
RefreshDocViewHS.png
Removabledrive.png
saveHS.png
search.png
shuffle.png
Shuffle_icon.png
song.png
splash1.png
StopHS.png
TaskHS.png
TrackInfo.gif
vssver2.scc
wiedergabe16.gif
BSEadminSetup
BSEadminSetup.vdproj
BSEadminSetup.vdproj.vspscc
mssccprj.scc
vssver2.scc
Debug
Release
BSEtunesSetup
BSEtunesSetup.vdproj
BSEtunesSetup.vdproj.vspscc
mssccprj.scc
vssver2.scc
Debug
Release
dll
BSE.CDDrives.DLL
BSE.Charts.DLL
BSE.Configuration.DLL
BSE.RemovableDrives.DLL
BSE.Shell.DLL
BSE.Windows.Forms.DLL
Lame
lame_enc.dll
vssver2.scc
lame-3.97
BSE.Platten_en.zip
BSE.CoverFlow.WPFLib.csproj.user
close.png
exit.png
next.png
next_disabled.png
Note.jpg
pause.png
PlayButton.png
previous.png
previous_disabled.png
stop.png
vssver2.scc
Settings.settings
vssver2.scc
vssver2.scc
BSE.Platten.Admin.csproj.user
Settings.settings
vssver2.scc
Album16.gif
BSEadmin.ico
cdimport.png
cdrip.png
cd_hoeren.png
clearsearch.png
DataContainer_MoveFirsHS.png
DataContainer_MoveLastHS.png
DataContainer_MoveNextHS.png
DataContainer_MovePreviousHS.png
DataContainer_NewRecordHS.png
diskinfo.png
DRIVEDSC.png
DRIVENET.png
Edit_UndoHS.png
exportimage.png
findfile.png
FindHS.png
freedb.png
Genre16.png
Image.png
InsertPictureHS.png
Interpret16.png
OptionsHS.png
PieChart3DHS.png
PieChartHS.png
ProtectFormHS.png
RefreshDocViewHS.png
saveHS.png
search.png
song.png
system.png
tagger.png
tools_16.png
vssver2.scc
BSE.Platten.Admin.WinApp.csproj.user
Settings.settings
vssver2.scc
BSEadmin.ico
vssver2.scc
bse.ico
BSE.Platten.Audio.csproj.user
vssver2.scc
vssver2.scc
vssver2.scc
FillDownHS.png
FillLeftHS.png
Folder256.png
FolderFind.png
FolderOpen256.png
GoLtrHS.png
MoveNext.png
MovePrevious.png
OptionsHS.png
PauseHS.png
PlayHS.png
Slider.gif
Start.png
StopHS.png
vssver2.scc
vssver2.scc
vssver2.scc
BSE.Platten.BO.csproj.user
vssver2.scc
BSE.Platten.Common.csproj.user
vssver2.scc
BSEsplash.png
DRIVEDSC.png
DRIVENET.png
Network.png
splash.png
vssver2.scc
BSE.Platten.Covers.csproj.user
Settings.settings
vssver2.scc
BSE.Platten.FreeDb.csproj.user
vssver2.scc
OpenCD.png
vssver2.scc
AudioWriter
vssver2.scc
BSE.Platten.Ripper.csproj.user
Lame
vssver2.scc
vssver2.scc
OpenCD.png
OptionsHS.png
vssver2.scc
BSE.Platten.Statistik.csproj.user
vssver2.scc
BSE.Platten.Tunes.csproj.user
vssver2.scc
Settings.settings
vssver2.scc
About.png
Album16.gif
AudioCD.png
AudioFile.png
AutoList.png
broadcast.png
BSE.png
BSEAbout.png
BSEsplash.png
BSEtunes.ico
BSE_16.png
cd_hoeren.png
coverflow.png
DataContainer_MoveNextHS.png
delete.gif
diskinfo.png
Filter2HS.png
FindHS.png
Folder256.png
FolderOpen256.png
Genre16.gif
Interpret16.gif
keinBild.gif
NewPlaylist16.gif
OptionsHS.png
PauseHS.png
RefreshDocViewHS.png
Removabledrive.png
saveHS.png
search.png
shuffle.png
Shuffle_icon.png
song.png
splash1.png
StopHS.png
TaskHS.png
TrackInfo.gif
vssver2.scc
wiedergabe16.gif
BSEadminSetup.vdproj
BSEtunesSetup.vdproj
BSE.CDDrives.DLL
BSE.Charts.DLL
BSE.Configuration.DLL
BSE.RemovableDrives.DLL
BSE.Shell.DLL
BSE.ThreadedShell.DLL
BSE.Windows.Forms.DLL
lame_enc.dll
MySQL.chm.zip
MySQL.chm
MySqlCreateDataBase5x.sql.zip
//Widows Media Format Interfaces
//
//  THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
//  KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
//  IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR
//  PURPOSE. IT CAN BE DISTRIBUTED FREE OF CHARGE AS LONG AS THIS HEADER 
//  REMAINS UNCHANGED.
//
//  Email:  yetiicb@hotmail.com
//
//  Copyright (C) 2002-2004 Idael Cardoso. 
//

using System;
using System.Text;
using System.Runtime.InteropServices;

namespace BSE.Platten.Audio.WMFSDK
{
  [StructLayout(LayoutKind.Sequential, CharSet=CharSet.Unicode)]
  public struct WM_READER_CLIENTINFO
  {
    public uint cbSize;
    [MarshalAs(UnmanagedType.LPWStr)]
    public string wszLang;
    [MarshalAs(UnmanagedType.LPWStr)]
    public string wszBrowserUserAgent;  
    [MarshalAs(UnmanagedType.LPWStr)]
    public string wszBrowserWebPage;    
    ulong  qwReserved;            
    public IntPtr pReserved;            
    [MarshalAs(UnmanagedType.LPWStr)]
    public string wszHostExe;           
    public ulong  qwHostVersion;         
    [MarshalAs(UnmanagedType.LPWStr)]
    public string wszPlayerUserAgent;   
  };

  [StructLayout(LayoutKind.Sequential)]
  public struct WM_READER_STATISTICS
  {
    public uint cbSize;
    public uint dwBandwidth;
    public uint cPacketsReceived;
    public uint cPacketsRecovered;
    public uint cPacketsLost;
    public uint wQuality;
  };

  [ComImport]
  [Guid("9F762FA7-A22E-428d-93C9-AC82F3AAFE5A")]
  [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  public interface IWMReaderAllocatorEx
  {
    void AllocateForStreamEx( [In] ushort wStreamNum,
                              [In] uint cbBuffer,
                              [Out] out INSSBuffer ppBuffer,
                              [In] uint dwFlags,
                              [In] ulong cnsSampleTime,
                              [In] ulong cnsSampleDuration,
                              [In] IntPtr pvContext);

    void AllocateForOutputEx( [In] uint dwOutputNum,
                                 [In] uint cbBuffer,
                                 [Out] out INSSBuffer ppBuffer,
                                 [In] uint dwFlags,
                                 [In] ulong cnsSampleTime,
                                 [In] ulong cnsSampleDuration,
                                 [In] IntPtr pvContext );
  }

  [ComImport]
  [Guid("9397F121-7705-4dc9-B049-98B698188414")]
  [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  public interface IWMSyncReader 
  {
    void Open( [In, MarshalAs(UnmanagedType.LPWStr)] string pwszFilename );
    void Close();
    void SetRange([In] ulong cnsStartTime, [In] long cnsDuration );
    void SetRangeByFrame([In] ushort wStreamNum, [In] ulong qwFrameNumber, [In]long cFramesToRead );
    void GetNextSample([In] ushort wStreamNum,
                       [Out] out INSSBuffer ppSample,
                       [Out] out ulong pcnsSampleTime,
                       [Out] out ulong pcnsDuration,
                       [Out] out uint pdwFlags,
                       [Out] out uint pdwOutputNum,
                       [Out] out ushort pwStreamNum );
    void SetStreamsSelected( [In] ushort cStreamCount,
                             [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] ushort[] pwStreamNumbers,
                             [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] WMT_STREAM_SELECTION[] pSelections  );
    void GetStreamSelected( [In]ushort wStreamNum,
                            [Out] out WMT_STREAM_SELECTION  pSelection );
    void SetReadStreamSamples( [In] ushort wStreamNum,
                               [In, MarshalAs(UnmanagedType.Bool)] bool fCompressed );
    void GetReadStreamSamples( [In] ushort wStreamNum,
                               [Out, MarshalAs(UnmanagedType.Bool)] out bool pfCompressed );
    void GetOutputSetting( [In] uint dwOutputNum,
                           [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
                           [Out] out WMT_ATTR_DATATYPE pType,
                           /*[out, size_is( *pcbLength )]*/ IntPtr pValue,
                           [In, Out] ref uint pcbLength );
    void SetOutputSetting( [In] uint dwOutputNum,
                           [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
                           [In] WMT_ATTR_DATATYPE  Type,
                           [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=4)] byte[] pValue,
                           [In] uint cbLength );
    void GetOutputCount( [Out] out uint pcOutputs );
    void GetOutputProps( [In] uint dwOutputNum, [Out, MarshalAs(UnmanagedType.Interface)] out IWMOutputMediaProps ppOutput );
    void SetOutputProps( [In] uint dwOutputNum, [In, MarshalAs(UnmanagedType.Interface)] IWMOutputMediaProps pOutput );
    void GetOutputFormatCount( [In] uint dwOutputNum, [Out] out uint pcFormats );
    void GetOutputFormat( [In] uint dwOutputNum,
                          [In] uint dwFormatNum,
                          [Out, MarshalAs(UnmanagedType.Interface)] out IWMOutputMediaProps ppProps );
    void GetOutputNumberForStream( [In] ushort wStreamNum, [Out] out uint pdwOutputNum );
    void GetStreamNumberForOutput( [In] uint dwOutputNum, [Out] out ushort pwStreamNum );
    void GetMaxOutputSampleSize( [In] uint dwOutput, [Out] out uint pcbMax );
    void GetMaxStreamSampleSize( [In] ushort wStream, [Out] out uint pcbMax );
    void OpenStream( [In, MarshalAs(UnmanagedType.Interface)] System.Runtime.InteropServices.ComTypes.IStream pStream );
  }

  [ComImport]
  [Guid("faed3d21-1b6b-4af7-8cb6-3e189bbc187b")]
  [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  public interface IWMSyncReader2 : IWMSyncReader
  {
    //IWMSyncReader
    new void Open( [In, MarshalAs(UnmanagedType.LPWStr)] string pwszFilename );
    new void Close();
    new void SetRange([In] ulong cnsStartTime, [In] long cnsDuration );
    new void SetRangeByFrame([In] ushort wStreamNum, [In] ulong qwFrameNumber, [In]long cFramesToRead );
    new void GetNextSample([In] ushort wStreamNum,
      [Out] out INSSBuffer ppSample,
      [Out] out ulong pcnsSampleTime,
      [Out] out ulong pcnsDuration,
      [Out] out uint pdwFlags,
      [Out] out uint pdwOutputNum,
      [Out] out ushort pwStreamNum );
    new void SetStreamsSelected( [In] ushort cStreamCount,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] ushort[] pwStreamNumbers,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] WMT_STREAM_SELECTION[] pSelections  );
    new void GetStreamSelected( [In]ushort wStreamNum,
      [Out] out WMT_STREAM_SELECTION  pSelection );
    new void SetReadStreamSamples( [In] ushort wStreamNum,
      [In, MarshalAs(UnmanagedType.Bool)] bool fCompressed );
    new void GetReadStreamSamples( [In] ushort wStreamNum,
      [Out, MarshalAs(UnmanagedType.Bool)] out bool pfCompressed );
    new void GetOutputSetting( [In] uint dwOutputNum,
      [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
      [Out] out WMT_ATTR_DATATYPE pType,
      /*[out, size_is( *pcbLength )]*/ IntPtr pValue,
      [In, Out] ref uint pcbLength );
    new void SetOutputSetting( [In] uint dwOutputNum,
      [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
      [In] WMT_ATTR_DATATYPE  Type,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=4)] byte[] pValue,
      [In] uint cbLength );
    new void GetOutputCount( [Out] out uint pcOutputs );
    new void GetOutputProps( [In] uint dwOutputNum, [Out, MarshalAs(UnmanagedType.Interface)] out IWMOutputMediaProps ppOutput );
    new void SetOutputProps( [In] uint dwOutputNum, [In, MarshalAs(UnmanagedType.Interface)] IWMOutputMediaProps pOutput );
    new void GetOutputFormatCount( [In] uint dwOutputNum, [Out] out uint pcFormats );
    new void GetOutputFormat( [In] uint dwOutputNum,
      [In] uint dwFormatNum,
      [Out, MarshalAs(UnmanagedType.Interface)] out IWMOutputMediaProps ppProps );
    new void GetOutputNumberForStream( [In] ushort wStreamNum, [Out] out uint pdwOutputNum );
    new void GetStreamNumberForOutput( [In] uint dwOutputNum, [Out] out ushort pwStreamNum );
    new void GetMaxOutputSampleSize( [In] uint dwOutput, [Out] out uint pcbMax );
    new void GetMaxStreamSampleSize( [In] ushort wStream, [Out] out uint pcbMax );
    new void OpenStream( [In, MarshalAs(UnmanagedType.Interface)] System.Runtime.InteropServices.ComTypes.IStream pStream );
    //IWMSyncReader2
    void SetRangeByTimecode( [In] ushort wStreamNum,
                             [In] ref WMT_TIMECODE_EXTENSION_DATA pStart,
                             [In] ref WMT_TIMECODE_EXTENSION_DATA pEnd );

    void SetRangeByFrameEx( [In] ushort wStreamNum,
                            [In] ulong qwFrameNumber,
                            [In] long cFramesToRead,
                            [Out] out ulong pcnsStartTime );
    void SetAllocateForOutput( [In] uint dwOutputNum, [In, MarshalAs(UnmanagedType.Interface)] IWMReaderAllocatorEx pAllocator );
    void GetAllocateForOutput( [In] uint dwOutputNum, [Out, MarshalAs(UnmanagedType.Interface)] out IWMReaderAllocatorEx ppAllocator );
    void SetAllocateForStream( [In] ushort wStreamNum, [In, MarshalAs(UnmanagedType.Interface)] IWMReaderAllocatorEx pAllocator );
    void GetAllocateForStream( [In] ushort dwSreamNum, [Out, MarshalAs(UnmanagedType.Interface)] out IWMReaderAllocatorEx ppAllocator );
  }
  
  [ComImport]
  [Guid("96406BD8-2B2B-11d3-B36B-00C04F6108FF")]
  [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  public interface IWMReaderCallback : IWMStatusCallback
  {
    //IWMStatusCallback
    new void OnStatus( [In] WMT_STATUS Status,
      [In] IntPtr hr,
      [In] WMT_ATTR_DATATYPE dwType,
      [In] IntPtr pValue,
      [In] IntPtr pvContext );
    //IWMReaderCallback
    void OnSample( [In] uint dwOutputNum,
                   [In] ulong cnsSampleTime,
                   [In] ulong cnsSampleDuration,
                   [In] uint dwFlags,
                   [In, MarshalAs(UnmanagedType.Interface)] INSSBuffer pSample,
                   [In] IntPtr pvContext );
  }

  [ComImport]
  [Guid("96406BD6-2B2B-11d3-B36B-00C04F6108FF")]
  [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  public interface IWMReader
  {
    void Open( [In, MarshalAs(UnmanagedType.LPWStr)] string pwszURL,
               [In, MarshalAs(UnmanagedType.Interface)] IWMReaderCallback pCallback,
               [In] IntPtr pvContext );
    void Close();
    void GetOutputCount( [Out] out uint pcOutputs );
    void GetOutputProps( [In] uint dwOutputNum,
                         [Out, MarshalAs(UnmanagedType.Interface)] out IWMOutputMediaProps ppOutput );
    void SetOutputProps( [In] uint dwOutputNum,
                         [In, MarshalAs(UnmanagedType.Interface)] IWMOutputMediaProps pOutput );
    void GetOutputFormatCount( [In] uint dwOutputNumber, [Out] out uint pcFormats );
    void GetOutputFormat( [In] uint dwOutputNumber,
                          [In] uint dwFormatNumber,
                          [Out, MarshalAs(UnmanagedType.Interface)] out IWMOutputMediaProps ppProps );
    void Start( [In] ulong cnsStart,
                [In] ulong cnsDuration,
                [In] float fRate,
                [In] IntPtr pvContext );
    void Stop();
    void Pause();
    void Resume();
  }

  [ComImport]
  [Guid("96406BEA-2B2B-11d3-B36B-00C04F6108FF")]
  [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  public interface IWMReaderAdvanced 
  {
    void SetUserProvidedClock( [In, MarshalAs(UnmanagedType.Bool)] bool fUserClock );
    void GetUserProvidedClock( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfUserClock );
    void DeliverTime( [In] ulong cnsTime );
    void SetManualStreamSelection( [In, MarshalAs(UnmanagedType.Bool)] bool fSelection );
    void GetManualStreamSelection( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfSelection );
    void SetStreamsSelected( [In] ushort cStreamCount,
                             [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] ushort[] pwStreamNumbers,
                             [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] WMT_STREAM_SELECTION[] pSelections );
    void GetStreamSelected( [In] ushort wStreamNum, [Out] out WMT_STREAM_SELECTION pSelection );
    void SetReceiveSelectionCallbacks( [In, MarshalAs(UnmanagedType.Bool)] bool fGetCallbacks );
    void GetReceiveSelectionCallbacks( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfGetCallbacks );
    void SetReceiveStreamSamples( [In] ushort wStreamNum, [In, MarshalAs(UnmanagedType.Bool)] bool fReceiveStreamSamples );
    void GetReceiveStreamSamples( [In] ushort wStreamNum,[Out, MarshalAs(UnmanagedType.Bool)] out bool pfReceiveStreamSamples );
    void SetAllocateForOutput( [In] uint dwOutputNum, [In, MarshalAs(UnmanagedType.Bool)] bool fAllocate );
    void GetAllocateForOutput( [In] uint dwOutputNum, [Out, MarshalAs(UnmanagedType.Bool)] out bool pfAllocate );
    void SetAllocateForStream( [In] ushort wStreamNum, [In, MarshalAs(UnmanagedType.Bool)] bool fAllocate );
    void GetAllocateForStream( [In] ushort dwSreamNum, [Out, MarshalAs(UnmanagedType.Bool)] out bool pfAllocate );
    void GetStatistics( [In, Out] ref WM_READER_STATISTICS pStatistics );
    void SetClientInfo( [In] ref WM_READER_CLIENTINFO pClientInfo );
    void GetMaxOutputSampleSize( [In] uint dwOutput, [Out] out uint pcbMax );
    void GetMaxStreamSampleSize( [In] ushort wStream, [Out] out uint pcbMax );
    void NotifyLateDelivery( ulong cnsLateness );
  }

  [ComImport]
  [Guid("ae14a945-b90c-4d0d-9127-80d665f7d73e")]
  [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  public interface IWMReaderAdvanced2 : IWMReaderAdvanced
  {
    //IWMReaderAdvanced
    new void SetUserProvidedClock( [In, MarshalAs(UnmanagedType.Bool)] bool fUserClock );
    new void GetUserProvidedClock( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfUserClock );
    new void DeliverTime( [In] ulong cnsTime );
    new void SetManualStreamSelection( [In, MarshalAs(UnmanagedType.Bool)] bool fSelection );
    new void GetManualStreamSelection( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfSelection );
    new void SetStreamsSelected( [In] ushort cStreamCount,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] ushort[] pwStreamNumbers,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] WMT_STREAM_SELECTION[] pSelections );
    new void GetStreamSelected( [In] ushort wStreamNum, [Out] out WMT_STREAM_SELECTION pSelection );
    new void SetReceiveSelectionCallbacks( [In, MarshalAs(UnmanagedType.Bool)] bool fGetCallbacks );
    new void GetReceiveSelectionCallbacks( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfGetCallbacks );
    new void SetReceiveStreamSamples( [In] ushort wStreamNum, [In, MarshalAs(UnmanagedType.Bool)] bool fReceiveStreamSamples );
    new void GetReceiveStreamSamples( [In] ushort wStreamNum,[Out, MarshalAs(UnmanagedType.Bool)] out bool pfReceiveStreamSamples );
    new void SetAllocateForOutput( [In] uint dwOutputNum, [In, MarshalAs(UnmanagedType.Bool)] bool fAllocate );
    new void GetAllocateForOutput( [In] uint dwOutputNum, [Out, MarshalAs(UnmanagedType.Bool)] out bool pfAllocate );
    new void SetAllocateForStream( [In] ushort wStreamNum, [In, MarshalAs(UnmanagedType.Bool)] bool fAllocate );
    new void GetAllocateForStream( [In] ushort dwSreamNum, [Out, MarshalAs(UnmanagedType.Bool)] out bool pfAllocate );
    new void GetStatistics( [In, Out] ref WM_READER_STATISTICS pStatistics );
    new void SetClientInfo( [In] ref WM_READER_CLIENTINFO pClientInfo );
    new void GetMaxOutputSampleSize( [In] uint dwOutput, [Out] out uint pcbMax );
    new void GetMaxStreamSampleSize( [In] ushort wStream, [Out] out uint pcbMax );
    new void NotifyLateDelivery( ulong cnsLateness );
    //IWMReaderAdvanced2
    void SetPlayMode( [In] WMT_PLAY_MODE Mode );
    void GetPlayMode( [Out] out WMT_PLAY_MODE pMode );
    void GetBufferProgress( [Out] out uint pdwPercent, [Out] out ulong pcnsBuffering );
    void GetDownloadProgress( [Out] out uint pdwPercent,
                              [Out] out ulong pqwBytesDownloaded,
                              [Out] out ulong pcnsDownload );
    void GetSaveAsProgress( [Out] out uint pdwPercent );
    void SaveFileAs( [In, MarshalAs(UnmanagedType.LPWStr)] string pwszFilename );
    void GetProtocolName( [Out, MarshalAs(UnmanagedType.LPWStr)] StringBuilder pwszProtocol,
                          [In, Out] ref uint pcchProtocol );
    void StartAtMarker( [In] ushort wMarkerIndex,
                        [In] ulong cnsDuration,
                        [In] float fRate,
                        [In] IntPtr pvContext );
    void GetOutputSetting( [In] uint dwOutputNum,
                           [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
                           [Out] out WMT_ATTR_DATATYPE pType,
                           [Out, MarshalAs(UnmanagedType.LPArray)] byte[] pValue,
                           [In, Out] ref ushort pcbLength );

    void SetOutputSetting( [In] uint dwOutputNum,
                           [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
                           [In] WMT_ATTR_DATATYPE Type,
                           [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=4)] byte[] pValue,
                           [In] ushort cbLength );
    void Preroll( [In] ulong cnsStart,
                  [In] ulong cnsDuration,
                  [In] float fRate );
    void SetLogClientID( [In, MarshalAs(UnmanagedType.Bool)] bool fLogClientID );
    void GetLogClientID( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfLogClientID );
    void StopBuffering( );
    void OpenStream([In, MarshalAs(UnmanagedType.Interface)] System.Runtime.InteropServices.ComTypes.IStream pStream,
                     [In, MarshalAs(UnmanagedType.Interface)] IWMReaderCallback pCallback,
                     [In] IntPtr pvContext );
  }

  [ComImport]
  [Guid("5DC0674B-F04B-4a4e-9F2A-B1AFDE2C8100")]
  [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  public interface IWMReaderAdvanced3 : IWMReaderAdvanced2
  {
    //IWMReaderAdvanced
    new void SetUserProvidedClock( [In, MarshalAs(UnmanagedType.Bool)] bool fUserClock );
    new void GetUserProvidedClock( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfUserClock );
    new void DeliverTime( [In] ulong cnsTime );
    new void SetManualStreamSelection( [In, MarshalAs(UnmanagedType.Bool)] bool fSelection );
    new void GetManualStreamSelection( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfSelection );
    new void SetStreamsSelected( [In] ushort cStreamCount,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] ushort[] pwStreamNumbers,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] WMT_STREAM_SELECTION[] pSelections );
    new void GetStreamSelected( [In] ushort wStreamNum, [Out] out WMT_STREAM_SELECTION pSelection );
    new void SetReceiveSelectionCallbacks( [In, MarshalAs(UnmanagedType.Bool)] bool fGetCallbacks );
    new void GetReceiveSelectionCallbacks( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfGetCallbacks );
    new void SetReceiveStreamSamples( [In] ushort wStreamNum, [In, MarshalAs(UnmanagedType.Bool)] bool fReceiveStreamSamples );
    new void GetReceiveStreamSamples( [In] ushort wStreamNum,[Out, MarshalAs(UnmanagedType.Bool)] out bool pfReceiveStreamSamples );
    new void SetAllocateForOutput( [In] uint dwOutputNum, [In, MarshalAs(UnmanagedType.Bool)] bool fAllocate );
    new void GetAllocateForOutput( [In] uint dwOutputNum, [Out, MarshalAs(UnmanagedType.Bool)] out bool pfAllocate );
    new void SetAllocateForStream( [In] ushort wStreamNum, [In, MarshalAs(UnmanagedType.Bool)] bool fAllocate );
    new void GetAllocateForStream( [In] ushort dwSreamNum, [Out, MarshalAs(UnmanagedType.Bool)] out bool pfAllocate );
    new void GetStatistics( [In, Out] ref WM_READER_STATISTICS pStatistics );
    new void SetClientInfo( [In] ref WM_READER_CLIENTINFO pClientInfo );
    new void GetMaxOutputSampleSize( [In] uint dwOutput, [Out] out uint pcbMax );
    new void GetMaxStreamSampleSize( [In] ushort wStream, [Out] out uint pcbMax );
    new void NotifyLateDelivery( ulong cnsLateness );
    //IWMReaderAdvanced2
    new void SetPlayMode( [In] WMT_PLAY_MODE Mode );
    new void GetPlayMode( [Out] out WMT_PLAY_MODE pMode );
    new void GetBufferProgress( [Out] out uint pdwPercent, [Out] out ulong pcnsBuffering );
    new void GetDownloadProgress( [Out] out uint pdwPercent,
      [Out] out ulong pqwBytesDownloaded,
      [Out] out ulong pcnsDownload );
    new void GetSaveAsProgress( [Out] out uint pdwPercent );
    new void SaveFileAs( [In, MarshalAs(UnmanagedType.LPWStr)] string pwszFilename );
    new void GetProtocolName( [Out, MarshalAs(UnmanagedType.LPWStr)] StringBuilder pwszProtocol,
      [In, Out] ref uint pcchProtocol );
    new void StartAtMarker( [In] ushort wMarkerIndex,
      [In] ulong cnsDuration,
      [In] float fRate,
      [In] IntPtr pvContext );
    new void GetOutputSetting( [In] uint dwOutputNum,
      [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
      [Out] out WMT_ATTR_DATATYPE pType,
      [Out, MarshalAs(UnmanagedType.LPArray)] byte[] pValue,
      [In, Out] ref ushort pcbLength );
    new void SetOutputSetting( [In] uint dwOutputNum,
      [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
      [In] WMT_ATTR_DATATYPE Type,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=4)] byte[] pValue,
      [In] ushort cbLength );
    new void Preroll( [In] ulong cnsStart,
      [In] ulong cnsDuration,
      [In] float fRate );
    new void SetLogClientID( [In, MarshalAs(UnmanagedType.Bool)] bool fLogClientID );
    new void GetLogClientID( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfLogClientID );
    new void StopBuffering( );
      new void OpenStream([In, MarshalAs(UnmanagedType.Interface)] System.Runtime.InteropServices.ComTypes.IStream pStream,
      [In, MarshalAs(UnmanagedType.Interface)] IWMReaderCallback pCallback,
      [In] IntPtr pvContext );
    //IWMReaderAdvanced3
    void StopNetStreaming( );
    void StartAtPosition(  [In] ushort wStreamNum,
                           [In] IntPtr pvOffsetStart,
                           [In] IntPtr pvDuration,
                           [In] WMT_OFFSET_FORMAT dwOffsetFormat,
                           [In] float fRate,
                           [In] IntPtr pvContext );
  }

  [ComImport]
  [Guid("945A76A2-12AE-4d48-BD3C-CD1D90399B85")]
  [InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
  public interface IWMReaderAdvanced4 : IWMReaderAdvanced3
  {
    //IWMReaderAdvanced
    new void SetUserProvidedClock( [In, MarshalAs(UnmanagedType.Bool)] bool fUserClock );
    new void GetUserProvidedClock( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfUserClock );
    new void DeliverTime( [In] ulong cnsTime );
    new void SetManualStreamSelection( [In, MarshalAs(UnmanagedType.Bool)] bool fSelection );
    new void GetManualStreamSelection( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfSelection );
    new void SetStreamsSelected( [In] ushort cStreamCount,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] ushort[] pwStreamNumbers,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=0)] WMT_STREAM_SELECTION[] pSelections );
    new void GetStreamSelected( [In] ushort wStreamNum, [Out] out WMT_STREAM_SELECTION pSelection );
    new void SetReceiveSelectionCallbacks( [In, MarshalAs(UnmanagedType.Bool)] bool fGetCallbacks );
    new void GetReceiveSelectionCallbacks( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfGetCallbacks );
    new void SetReceiveStreamSamples( [In] ushort wStreamNum, [In, MarshalAs(UnmanagedType.Bool)] bool fReceiveStreamSamples );
    new void GetReceiveStreamSamples( [In] ushort wStreamNum,[Out, MarshalAs(UnmanagedType.Bool)] out bool pfReceiveStreamSamples );
    new void SetAllocateForOutput( [In] uint dwOutputNum, [In, MarshalAs(UnmanagedType.Bool)] bool fAllocate );
    new void GetAllocateForOutput( [In] uint dwOutputNum, [Out, MarshalAs(UnmanagedType.Bool)] out bool pfAllocate );
    new void SetAllocateForStream( [In] ushort wStreamNum, [In, MarshalAs(UnmanagedType.Bool)] bool fAllocate );
    new void GetAllocateForStream( [In] ushort dwSreamNum, [Out, MarshalAs(UnmanagedType.Bool)] out bool pfAllocate );
    new void GetStatistics( [In, Out] ref WM_READER_STATISTICS pStatistics );
    new void SetClientInfo( [In] ref WM_READER_CLIENTINFO pClientInfo );
    new void GetMaxOutputSampleSize( [In] uint dwOutput, [Out] out uint pcbMax );
    new void GetMaxStreamSampleSize( [In] ushort wStream, [Out] out uint pcbMax );
    new void NotifyLateDelivery( ulong cnsLateness );
    //IWMReaderAdvanced2
    new void SetPlayMode( [In] WMT_PLAY_MODE Mode );
    new void GetPlayMode( [Out] out WMT_PLAY_MODE pMode );
    new void GetBufferProgress( [Out] out uint pdwPercent, [Out] out ulong pcnsBuffering );
    new void GetDownloadProgress( [Out] out uint pdwPercent,
      [Out] out ulong pqwBytesDownloaded,
      [Out] out ulong pcnsDownload );
    new void GetSaveAsProgress( [Out] out uint pdwPercent );
    new void SaveFileAs( [In, MarshalAs(UnmanagedType.LPWStr)] string pwszFilename );
    new void GetProtocolName( [Out, MarshalAs(UnmanagedType.LPWStr)] StringBuilder pwszProtocol,
      [In, Out] ref uint pcchProtocol );
    new void StartAtMarker( [In] ushort wMarkerIndex,
      [In] ulong cnsDuration,
      [In] float fRate,
      [In] IntPtr pvContext );
    new void GetOutputSetting( [In] uint dwOutputNum,
      [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
      [Out] out WMT_ATTR_DATATYPE pType,
      [Out, MarshalAs(UnmanagedType.LPArray)] byte[] pValue,
      [In, Out] ref ushort pcbLength );
    new void SetOutputSetting( [In] uint dwOutputNum,
      [In, MarshalAs(UnmanagedType.LPWStr)] string pszName,
      [In] WMT_ATTR_DATATYPE Type,
      [In, MarshalAs(UnmanagedType.LPArray, SizeParamIndex=4)] byte[] pValue,
      [In] ushort cbLength );
    new void Preroll( [In] ulong cnsStart,
      [In] ulong cnsDuration,
      [In] float fRate );
    new void SetLogClientID( [In, MarshalAs(UnmanagedType.Bool)] bool fLogClientID );
    new void GetLogClientID( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfLogClientID );
    new void StopBuffering( );
      new void OpenStream([In, MarshalAs(UnmanagedType.Interface)] System.Runtime.InteropServices.ComTypes.IStream pStream,
      [In, MarshalAs(UnmanagedType.Interface)] IWMReaderCallback pCallback,
      [In] IntPtr pvContext );
    //IWMReaderAdvanced3
    new void StopNetStreaming( );
    new void StartAtPosition(  [In] ushort wStreamNum,
      [In] IntPtr pvOffsetStart,
      [In] IntPtr pvDuration,
      [In] WMT_OFFSET_FORMAT dwOffsetFormat,
      [In] float fRate,
      [In] IntPtr pvContext );
    //IWMReaderAdvanced4
    void GetLanguageCount( [In] uint dwOutputNum,
                           [Out] out ushort pwLanguageCount );
    void GetLanguage( [In] uint dwOutputNum,
                      [In] ushort wLanguage,
                      [Out, MarshalAs(UnmanagedType.LPWStr)] StringBuilder pwszLanguageString,
                      [In, Out] ref ushort pcchLanguageStringLength );
    void GetMaxSpeedFactor( [Out] out double pdblFactor );
    void IsUsingFastCache( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfUsingFastCache );
    void AddLogParam( [In, MarshalAs(UnmanagedType.LPWStr)] string wszNameSpace,
                      [In, MarshalAs(UnmanagedType.LPWStr)] string wszName,
                      [In, MarshalAs(UnmanagedType.LPWStr)] string wszValue );
    void SendLogParams( );
    void CanSaveFileAs( [Out, MarshalAs(UnmanagedType.Bool)] out bool pfCanSave );
    void CancelSaveFileAs( );
    void GetURL( [Out, MarshalAs(UnmanagedType.LPWStr)] StringBuilder pwszURL,
                 [In, Out] ref uint pcchURL );
  }

}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

Share

About the Author

Uwe Eichkorn
Switzerland Switzerland
No Biography provided

You may also be interested in...

| Advertise | Privacy | Terms of Use | Mobile
Web04 | 2.8.150731.1 | Last Updated 24 Apr 2010
Article Copyright 2009 by Uwe Eichkorn
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid