Advertisement
Naohiro19

ttsmf0.dll wrapper by CppSharp(C#)

Mar 22nd, 2018
272
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 12.45 KB | None | 0 0
  1. // ----------------------------------------------------------------------------
  2. // <auto-generated>
  3. // This is autogenerated code by CppSharp.
  4. // Do not edit this file or all your changes will be lost after re-generation.
  5. // </auto-generated>
  6. // ----------------------------------------------------------------------------
  7. using System;
  8. using System.Runtime.InteropServices;
  9. using System.Security;
  10.  
  11. namespace ttsmf0
  12. {
  13.     public unsafe partial class Ttsmf0
  14.     {
  15.         public partial struct __Internal
  16.         {
  17.             [SuppressUnmanagedCodeSecurity]
  18.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  19.                 EntryPoint="_CreateSmf@4")]
  20.             internal static extern global::System.IntPtr CreateSmf(short Timebase);
  21.  
  22.             [SuppressUnmanagedCodeSecurity]
  23.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  24.                 EntryPoint="_DeleteSmf@4")]
  25.             internal static extern int DeleteSmf(global::System.IntPtr hSmf);
  26.  
  27.             [SuppressUnmanagedCodeSecurity]
  28.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  29.                 EntryPoint="_CopySmf@4")]
  30.             internal static extern global::System.IntPtr CopySmf(global::System.IntPtr hSmf);
  31.  
  32.             [SuppressUnmanagedCodeSecurity]
  33.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  34.                 EntryPoint="_SaveSmf@16")]
  35.             internal static extern int SaveSmf(global::System.IntPtr hSmf, sbyte* lpszFileName, uint fdwCreate, uint fdwAttrsAndFlags);
  36.  
  37.             [SuppressUnmanagedCodeSecurity]
  38.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  39.                 EntryPoint="_GetSmfDataSize@8")]
  40.             internal static extern int GetSmfDataSize(global::System.IntPtr hSmf, uint* pDestSize);
  41.  
  42.             [SuppressUnmanagedCodeSecurity]
  43.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  44.                 EntryPoint="_GetSmfData@12")]
  45.             internal static extern int GetSmfData(global::System.IntPtr hSmf, byte* pDest, uint DestSize);
  46.  
  47.             [SuppressUnmanagedCodeSecurity]
  48.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  49.                 EntryPoint="_CopyToClipboard@4")]
  50.             internal static extern int CopyToClipboard(global::System.IntPtr hSmf);
  51.  
  52.             [SuppressUnmanagedCodeSecurity]
  53.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  54.                 EntryPoint="_InsertMidiEvent@16")]
  55.             internal static extern int InsertMidiEvent(global::System.IntPtr hSmf, uint Tick, byte* pData, int DataSize);
  56.  
  57.             [SuppressUnmanagedCodeSecurity]
  58.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  59.                 EntryPoint="_InsertSysexEvent@16")]
  60.             internal static extern int InsertSysexEvent(global::System.IntPtr hSmf, uint Tick, byte* pData, int DataSize);
  61.  
  62.             [SuppressUnmanagedCodeSecurity]
  63.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  64.                 EntryPoint="_InsertMetaEvent@20")]
  65.             internal static extern int InsertMetaEvent(global::System.IntPtr hSmf, uint Tick, byte MetaType, byte* pData, int DataSize);
  66.  
  67.             [SuppressUnmanagedCodeSecurity]
  68.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  69.                 EntryPoint="_cal_insert_Note@24")]
  70.             internal static extern int CalInsertNote(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Key, int Velocity, uint Duration);
  71.  
  72.             [SuppressUnmanagedCodeSecurity]
  73.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  74.                 EntryPoint="_cal_insert_KeyAft@20")]
  75.             internal static extern int CalInsertKeyAft(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Key, int Amount);
  76.  
  77.             [SuppressUnmanagedCodeSecurity]
  78.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  79.                 EntryPoint="_cal_insert_Control@20")]
  80.             internal static extern int CalInsertControl(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int ControlNumber, int Value);
  81.  
  82.             [SuppressUnmanagedCodeSecurity]
  83.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  84.                 EntryPoint="_cal_insert_ChanAft@16")]
  85.             internal static extern int CalInsertChanAft(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Amount);
  86.  
  87.             [SuppressUnmanagedCodeSecurity]
  88.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  89.                 EntryPoint="_cal_insert_Patch@20")]
  90.             internal static extern int CalInsertPatch(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int PatchNumber, int BankNumber);
  91.  
  92.             [SuppressUnmanagedCodeSecurity]
  93.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  94.                 EntryPoint="_cal_insert_Wheel@16")]
  95.             internal static extern int CalInsertWheel(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Value);
  96.  
  97.             [SuppressUnmanagedCodeSecurity]
  98.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  99.                 EntryPoint="_calex_insert_RPN@20")]
  100.             internal static extern int CalexInsertRPN(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Number, int Value);
  101.  
  102.             [SuppressUnmanagedCodeSecurity]
  103.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  104.                 EntryPoint="_calex_insert_NRPN@20")]
  105.             internal static extern int CalexInsertNRPN(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Number, int Value);
  106.  
  107.             [SuppressUnmanagedCodeSecurity]
  108.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  109.                 EntryPoint="_calex_insert_Sysx@12")]
  110.             internal static extern int CalexInsertSysx(global::System.IntPtr hSmf, uint Tick, sbyte* lpszSysx);
  111.  
  112.             [SuppressUnmanagedCodeSecurity]
  113.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  114.                 EntryPoint="_calex_insert_Text@12")]
  115.             internal static extern int CalexInsertText(global::System.IntPtr hSmf, uint Tick, sbyte* lpszText);
  116.  
  117.             [SuppressUnmanagedCodeSecurity]
  118.             [DllImport("ttsmf0", CallingConvention = global::System.Runtime.InteropServices.CallingConvention.StdCall,
  119.                 EntryPoint="_calex_insert_Lyric@12")]
  120.             internal static extern int CalexInsertLyric(global::System.IntPtr hSmf, uint Tick, sbyte* lpszLyric);
  121.         }
  122.  
  123.         public static global::System.IntPtr CreateSmf(short Timebase)
  124.         {
  125.             var __ret = __Internal.CreateSmf(Timebase);
  126.             return __ret;
  127.         }
  128.  
  129.         public static int DeleteSmf(global::System.IntPtr hSmf)
  130.         {
  131.             var __ret = __Internal.DeleteSmf(hSmf);
  132.             return __ret;
  133.         }
  134.  
  135.         public static global::System.IntPtr CopySmf(global::System.IntPtr hSmf)
  136.         {
  137.             var __ret = __Internal.CopySmf(hSmf);
  138.             return __ret;
  139.         }
  140.  
  141.         public static int SaveSmf(global::System.IntPtr hSmf, sbyte* lpszFileName, uint fdwCreate, uint fdwAttrsAndFlags)
  142.         {
  143.             var __ret = __Internal.SaveSmf(hSmf, lpszFileName, fdwCreate, fdwAttrsAndFlags);
  144.             return __ret;
  145.         }
  146.  
  147.         public static int GetSmfDataSize(global::System.IntPtr hSmf, ref uint pDestSize)
  148.         {
  149.             fixed (uint* __refParamPtr1 = &pDestSize)
  150.             {
  151.                 var __arg1 = __refParamPtr1;
  152.                 var __ret = __Internal.GetSmfDataSize(hSmf, __arg1);
  153.                 return __ret;
  154.             }
  155.         }
  156.  
  157.         public static int GetSmfData(global::System.IntPtr hSmf, byte* pDest, uint DestSize)
  158.         {
  159.             var __ret = __Internal.GetSmfData(hSmf, pDest, DestSize);
  160.             return __ret;
  161.         }
  162.  
  163.         public static int CopyToClipboard(global::System.IntPtr hSmf)
  164.         {
  165.             var __ret = __Internal.CopyToClipboard(hSmf);
  166.             return __ret;
  167.         }
  168.  
  169.         public static int InsertMidiEvent(global::System.IntPtr hSmf, uint Tick, byte* pData, int DataSize)
  170.         {
  171.             var __ret = __Internal.InsertMidiEvent(hSmf, Tick, pData, DataSize);
  172.             return __ret;
  173.         }
  174.  
  175.         public static int InsertSysexEvent(global::System.IntPtr hSmf, uint Tick, byte* pData, int DataSize)
  176.         {
  177.             var __ret = __Internal.InsertSysexEvent(hSmf, Tick, pData, DataSize);
  178.             return __ret;
  179.         }
  180.  
  181.         public static int InsertMetaEvent(global::System.IntPtr hSmf, uint Tick, byte MetaType, byte* pData, int DataSize)
  182.         {
  183.             var __ret = __Internal.InsertMetaEvent(hSmf, Tick, MetaType, pData, DataSize);
  184.             return __ret;
  185.         }
  186.  
  187.         public static int CalInsertNote(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Key, int Velocity, uint Duration)
  188.         {
  189.             var __ret = __Internal.CalInsertNote(hSmf, Tick, MidiChannel, Key, Velocity, Duration);
  190.             return __ret;
  191.         }
  192.  
  193.         public static int CalInsertKeyAft(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Key, int Amount)
  194.         {
  195.             var __ret = __Internal.CalInsertKeyAft(hSmf, Tick, MidiChannel, Key, Amount);
  196.             return __ret;
  197.         }
  198.  
  199.         public static int CalInsertControl(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int ControlNumber, int Value)
  200.         {
  201.             var __ret = __Internal.CalInsertControl(hSmf, Tick, MidiChannel, ControlNumber, Value);
  202.             return __ret;
  203.         }
  204.  
  205.         public static int CalInsertChanAft(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Amount)
  206.         {
  207.             var __ret = __Internal.CalInsertChanAft(hSmf, Tick, MidiChannel, Amount);
  208.             return __ret;
  209.         }
  210.  
  211.         public static int CalInsertPatch(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int PatchNumber, int BankNumber)
  212.         {
  213.             var __ret = __Internal.CalInsertPatch(hSmf, Tick, MidiChannel, PatchNumber, BankNumber);
  214.             return __ret;
  215.         }
  216.  
  217.         public static int CalInsertWheel(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Value)
  218.         {
  219.             var __ret = __Internal.CalInsertWheel(hSmf, Tick, MidiChannel, Value);
  220.             return __ret;
  221.         }
  222.  
  223.         public static int CalexInsertRPN(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Number, int Value)
  224.         {
  225.             var __ret = __Internal.CalexInsertRPN(hSmf, Tick, MidiChannel, Number, Value);
  226.             return __ret;
  227.         }
  228.  
  229.         public static int CalexInsertNRPN(global::System.IntPtr hSmf, uint Tick, int MidiChannel, int Number, int Value)
  230.         {
  231.             var __ret = __Internal.CalexInsertNRPN(hSmf, Tick, MidiChannel, Number, Value);
  232.             return __ret;
  233.         }
  234.  
  235.         public static int CalexInsertSysx(global::System.IntPtr hSmf, uint Tick, sbyte* lpszSysx)
  236.         {
  237.             var __ret = __Internal.CalexInsertSysx(hSmf, Tick, lpszSysx);
  238.             return __ret;
  239.         }
  240.  
  241.         public static int CalexInsertText(global::System.IntPtr hSmf, uint Tick, sbyte* lpszText)
  242.         {
  243.             var __ret = __Internal.CalexInsertText(hSmf, Tick, lpszText);
  244.             return __ret;
  245.         }
  246.  
  247.         public static int CalexInsertLyric(global::System.IntPtr hSmf, uint Tick, sbyte* lpszLyric)
  248.         {
  249.             var __ret = __Internal.CalexInsertLyric(hSmf, Tick, lpszLyric);
  250.             return __ret;
  251.         }
  252.     }
  253. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement