Example #1
0
        public static uint midiOutOpen(ref IntPtr lphMidiOut,
                                       uint uDeviceID,
                                       Delegate dwCallback,
                                       uint dwInstance,
                                       uint dwFlags)
        {
            uint ret = MMSYSERR_ERROR;

            if (status_winmm != DllStatus.NotFound)
            {
                try {
                    ret = __midiOutOpen(ref lphMidiOut, uDeviceID, dwCallback, dwInstance, dwFlags);
                } catch (DllNotFoundException ex) {
                    status_winmm = DllStatus.NotFound;
                }
            }
            else if (status_winmm_so != DllStatus.NotFound)
            {
                try {
                    ret = __so_midiOutOpen(ref lphMidiOut, uDeviceID, dwCallback, dwInstance, dwFlags);
                } catch (DllNotFoundException ex) {
                    status_winmm_so = DllStatus.NotFound;
                }
            }
            return(ret);
        }
Example #2
0
        public static uint joyGetPosEx(uint uJoyID, ref JOYINFOEX pji)
        {
            uint ret = MMSYSERR_ERROR;

            if (status_winmm != DllStatus.NotFound)
            {
                try {
                    ret = __joyGetPosEx(uJoyID, ref pji);
                } catch (DllNotFoundException ex) {
                    status_winmm = DllStatus.NotFound;
                }
            }
            return(ret);
        }
Example #3
0
        public static uint joyGetDevCapsW(uint uJoyID, ref JOYCAPSW pjc, uint cbjc)
        {
            uint ret = MMSYSERR_ERROR;

            if (status_winmm != DllStatus.NotFound)
            {
                try {
                    ret = __joyGetDevCapsW(uJoyID, ref pjc, cbjc);
                } catch (DllNotFoundException ex) {
                    status_winmm = DllStatus.NotFound;
                }
            }
            return(ret);
        }
Example #4
0
        public static uint joyGetNumDevs()
        {
            uint ret = 0;

            if (status_winmm != DllStatus.NotFound)
            {
                try {
                    ret = __joyGetNumDevs();
                } catch (DllNotFoundException ex) {
                    status_winmm = DllStatus.NotFound;
                }
            }
            return(ret);
        }
Example #5
0
        public static uint midiOutGetNumDevs()
        {
            uint ret = MMSYSERR_ERROR;

            if (status_winmm != DllStatus.NotFound)
            {
                try {
                    ret = __midiOutGetNumDevs();
                } catch (DllNotFoundException ex) {
                    status_winmm = DllStatus.NotFound;
                }
            }
            else if (status_winmm_so != DllStatus.NotFound)
            {
                try {
                    ret = __so_midiOutGetNumDevs();
                } catch (DllNotFoundException ex) {
                    status_winmm_so = DllStatus.NotFound;
                }
            }
            return(ret);
        }
Example #6
0
        public static uint midiOutUnprepareHeader(IntPtr hMidiOut, ref MIDIHDR lpMidiOutHdr, uint uSize)
        {
            uint ret = MMSYSERR_ERROR;

            if (status_winmm != DllStatus.NotFound)
            {
                try {
                    ret = __midiOutUnprepareHeader(hMidiOut, ref lpMidiOutHdr, uSize);
                } catch (DllNotFoundException ex) {
                    status_winmm = DllStatus.NotFound;
                }
            }
            else if (status_winmm_so != DllStatus.NotFound)
            {
                try {
                    ret = __so_midiOutUnprepareHeader(hMidiOut, ref lpMidiOutHdr, uSize);
                } catch (DllNotFoundException ex) {
                    status_winmm_so = DllStatus.NotFound;
                }
            }
            return(ret);
        }
Example #7
0
        public static uint midiOutShortMsg(IntPtr hMidiOut, uint dwMsg)
        {
            uint ret = MMSYSERR_ERROR;

            if (status_winmm != DllStatus.NotFound)
            {
                try {
                    ret = __midiOutShortMsg(hMidiOut, dwMsg);
                } catch (DllNotFoundException ex) {
                    status_winmm = DllStatus.NotFound;
                }
            }
            else if (status_winmm_so != DllStatus.NotFound)
            {
                try {
                    ret = __so_midiOutShortMsg(hMidiOut, dwMsg);
                } catch (DllNotFoundException ex) {
                    status_winmm_so = DllStatus.NotFound;
                }
            }
            return(ret);
        }
Example #8
0
        public static uint midiOutGetDevCapsA(uint uDeviceID, ref MIDIOUTCAPSA pMidiOutCaps, uint cbMidiOutCaps)
        {
            uint ret = MMSYSERR_ERROR;

            if (status_winmm != DllStatus.NotFound)
            {
                try {
                    ret = __midiOutGetDevCapsA(uDeviceID, ref pMidiOutCaps, cbMidiOutCaps);
                } catch (DllNotFoundException ex) {
                    status_winmm = DllStatus.NotFound;
                }
            }
            else if (status_winmm_so != DllStatus.NotFound)
            {
                try {
                    ret = __so_midiOutGetDevCapsA(uDeviceID, ref pMidiOutCaps, cbMidiOutCaps);
                } catch (DllNotFoundException ex) {
                    status_winmm_so = DllStatus.NotFound;
                }
            }
            return(ret);
        }
Example #9
0
        public static uint midiInReset(uint hMidiIn)
        {
            uint ret = MMSYSERR_ERROR;

            if (status_winmm != DllStatus.NotFound)
            {
                try {
                    ret = __midiInReset(hMidiIn);
                } catch (DllNotFoundException ex) {
                    status_winmm = DllStatus.NotFound;
                }
            }
            else if (status_winmm_so != DllStatus.NotFound)
            {
                try {
                    ret = __so_midiInReset(hMidiIn);
                } catch (DllNotFoundException ex) {
                    status_winmm_so = DllStatus.NotFound;
                }
            }
            return(ret);
        }
Example #10
0
 public static uint joyGetNumDevs() {
     uint ret = 0;
     if ( status_winmm != DllStatus.NotFound ) {
         try {
             ret = __joyGetNumDevs();
         } catch ( DllNotFoundException ex ) {
             status_winmm = DllStatus.NotFound;
         }
     }
     return ret;
 }
Example #11
0
 public static uint midiOutUnprepareHeader( IntPtr hMidiOut, ref MIDIHDR lpMidiOutHdr, uint uSize ) {
     uint ret = MMSYSERR_ERROR;
     if ( status_winmm != DllStatus.NotFound ) {
         try {
             ret = __midiOutUnprepareHeader( hMidiOut, ref lpMidiOutHdr, uSize );
         } catch ( DllNotFoundException ex ) {
             status_winmm = DllStatus.NotFound;
         }
     } else if ( status_winmm_so != DllStatus.NotFound ) {
         try {
             ret = __so_midiOutUnprepareHeader( hMidiOut, ref lpMidiOutHdr, uSize );
         } catch ( DllNotFoundException ex ) {
             status_winmm_so = DllStatus.NotFound;
         }
     }
     return ret;
 }
Example #12
0
 public static uint midiOutShortMsg( IntPtr hMidiOut, uint dwMsg ) {
     uint ret = MMSYSERR_ERROR;
     if ( status_winmm != DllStatus.NotFound ) {
         try {
             ret = __midiOutShortMsg( hMidiOut, dwMsg );
         } catch ( DllNotFoundException ex ) {
             status_winmm = DllStatus.NotFound;
         }
     } else if ( status_winmm_so != DllStatus.NotFound ) {
         try {
             ret = __so_midiOutShortMsg( hMidiOut, dwMsg );
         } catch ( DllNotFoundException ex ) {
             status_winmm_so = DllStatus.NotFound;
         }
     }
     return ret;
 }
Example #13
0
 public static uint midiOutOpen( ref IntPtr lphMidiOut,
                                 uint uDeviceID,
                                 Delegate dwCallback,
                                 uint dwInstance,
                                 uint dwFlags ) {
     uint ret = MMSYSERR_ERROR;
     if ( status_winmm != DllStatus.NotFound ) {
         try {
             ret = __midiOutOpen( ref lphMidiOut, uDeviceID, dwCallback, dwInstance, dwFlags );
         } catch ( DllNotFoundException ex ) {
             status_winmm = DllStatus.NotFound;
         }
     } else if ( status_winmm_so != DllStatus.NotFound ) {
         try {
             ret = __so_midiOutOpen( ref lphMidiOut, uDeviceID, dwCallback, dwInstance, dwFlags );
         } catch ( DllNotFoundException ex ) {
             status_winmm_so = DllStatus.NotFound;
         }
     }
     return ret;
 }
Example #14
0
 public static uint midiOutGetDevCapsA( uint uDeviceID, ref MIDIOUTCAPSA pMidiOutCaps, uint cbMidiOutCaps ) {
     uint ret = MMSYSERR_ERROR;
     if ( status_winmm != DllStatus.NotFound ) {
         try {
             ret = __midiOutGetDevCapsA( uDeviceID, ref pMidiOutCaps, cbMidiOutCaps );
         } catch ( DllNotFoundException ex ) {
             status_winmm = DllStatus.NotFound;
         }
     } else if ( status_winmm_so != DllStatus.NotFound ) {
         try {
             ret = __so_midiOutGetDevCapsA( uDeviceID, ref pMidiOutCaps, cbMidiOutCaps );
         } catch ( DllNotFoundException ex ) {
             status_winmm_so = DllStatus.NotFound;
         }
     }
     return ret;
 }
Example #15
0
 public static uint midiOutGetNumDevs() {
     uint ret = MMSYSERR_ERROR;
     if ( status_winmm != DllStatus.NotFound ) {
         try {
             ret = __midiOutGetNumDevs();
         } catch ( DllNotFoundException ex ) {
             status_winmm = DllStatus.NotFound;
         }
     } else if ( status_winmm_so != DllStatus.NotFound ) {
         try {
             ret = __so_midiOutGetNumDevs();
         } catch ( DllNotFoundException ex ) {
             status_winmm_so = DllStatus.NotFound;
         }
     }
     return ret;
 }
Example #16
0
 public static uint joyGetDevCapsW( uint uJoyID, ref JOYCAPSW pjc, uint cbjc ) {
     uint ret = MMSYSERR_ERROR;
     if ( status_winmm != DllStatus.NotFound ) {
         try {
             ret = __joyGetDevCapsW( uJoyID, ref pjc, cbjc );
         } catch ( DllNotFoundException ex ) {
             status_winmm = DllStatus.NotFound;
         }
     }
     return ret;
 }
Example #17
0
 public static uint joyGetPosEx( uint uJoyID, ref JOYINFOEX pji ) {
     uint ret = MMSYSERR_ERROR;
     if ( status_winmm != DllStatus.NotFound ) {
         try {
             ret = __joyGetPosEx( uJoyID, ref pji );
         } catch ( DllNotFoundException ex ) {
             status_winmm = DllStatus.NotFound;
         }
     }
     return ret;
 }
Example #18
0
 public static uint midiInReset( uint hMidiIn ) {
     uint ret = MMSYSERR_ERROR;
     if ( status_winmm != DllStatus.NotFound ) {
         try {
             ret = __midiInReset( hMidiIn );
         } catch ( DllNotFoundException ex ) {
             status_winmm = DllStatus.NotFound;
         }
     } else if ( status_winmm_so != DllStatus.NotFound ) {
         try {
             ret = __so_midiInReset( hMidiIn );
         } catch ( DllNotFoundException ex ) {
             status_winmm_so = DllStatus.NotFound;
         }
     }
     return ret;
 }