Changeset 75 for Include/api_mmsys.sbp
- Timestamp:
- Jan 26, 2007, 4:44:33 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Include/api_mmsys.sbp
r1 r75 705 705 706 706 707 '-------------------------------------------------------- 708 ' Auxiliary audio support 709 710 ' device ID for aux device mapper 711 Const AUX_MAPPER = (-1) 712 713 ' Auxiliary audio device capabilities structure 714 Type AUXCAPSA 715 wMid As Word 716 wPid As Word 717 vDriverVersion As MMVERSION 718 szPname[ELM(MAXPNAMELEN)] As Char 719 wTechnology As Word 720 wReserved1 As Word 721 dwSupport As DWord 722 End Type 723 TypeDef PAUXCAPSA = *AUXCAPSA 724 TypeDef NPAUXCAPSA = *AUXCAPSA 725 TypeDef LPAUXCAPSA = *AUXCAPSA 726 727 TypeDef AUXCAPS = AUXCAPSA 728 TypeDef PAUXCAPS = PAUXCAPSA 729 TypeDef NPAUXCAPS = NPAUXCAPSA 730 TypeDef LPAUXCAPS = LPAUXCAPSA 731 732 Const AUXCAPS_CDAUDIO = 1 733 Const AUXCAPS_AUXIN = 2 734 735 Const AUXCAPS_VOLUME = &H0001 736 Const AUXCAPS_LRVOLUME = &H0002 737 738 ' auxiliary audio function prototypes 739 Declare Function auxGetNumDevs Lib "winmm" () As DWord 740 Declare Function auxGetDevCaps Lib "winmm" Alias "auxGetDevCapsA" (uDeviceID As DWord, pac As *AUXCAPS, cbac As DWord) As MMRESULT 741 Declare Function auxSetVolume Lib "winmm" (uDeviceID As DWord, dwVolume As DWord) As MMRESULT 742 Declare Function auxGetVolume Lib "winmm" (uDeviceID As DWord, pdwVolume As *DWord) As MMRESULT 743 Declare Function auxOutMessage Lib "winmm" (uDeviceID As DWord, uMsg As DWord, dw1 As DWord, dw2 As DWord) As MMRESULT 744 745 746 '-------------------------------------------------------- 747 ' Mixer Support 748 749 TypeDef HMIXEROBJ = VoidPtr 750 TypeDef LPHMIXEROBJ = HMIXEROBJ 751 TypeDef HMIXER = VoidPtr 752 TypeDef LPHMIXER = *HMIXER 753 754 Const MIXER_SHORT_NAME_CHARS = 16 755 Const MIXER_LONG_NAME_CHARS = 64 756 757 Const MIXERR_INVALLINE = (MIXERR_BASE + 0) 758 Const MIXERR_INVALCONTROL = (MIXERR_BASE + 1) 759 Const MIXERR_INVALVALUE = (MIXERR_BASE + 2) 760 Const MIXERR_LASTERROR = (MIXERR_BASE + 2) 761 762 Const MIXER_OBJECTF_HANDLE = &H80000000 763 Const MIXER_OBJECTF_MIXER = &H00000000 764 Const MIXER_OBJECTF_HMIXER = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_MIXER) 765 Const MIXER_OBJECTF_WAVEOUT = &H10000000 766 Const MIXER_OBJECTF_HWAVEOUT = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_WAVEOUT) 767 Const MIXER_OBJECTF_WAVEIN = &H20000000 768 Const MIXER_OBJECTF_HWAVEIN = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_WAVEIN) 769 Const MIXER_OBJECTF_MIDIOUT = &H30000000 770 Const MIXER_OBJECTF_HMIDIOUT = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_MIDIOUT) 771 Const MIXER_OBJECTF_MIDIIN = &H40000000 772 Const MIXER_OBJECTF_HMIDIIN = (MIXER_OBJECTF_HANDLE OR MIXER_OBJECTF_MIDIIN) 773 Const MIXER_OBJECTF_AUX = &H50000000 774 775 Declare Function mixerGetNumDevs Lib "winmm" () As DWord 776 777 Type MIXERCAPSA 778 wMid As Word 779 wPid As Word 780 vDriverVersion As MMVERSION 781 szPname[ELM(MAXPNAMELEN)] As Char 782 fdwSupport As DWord 783 cDestinations As DWord 784 End Type 785 TypeDef PMIXERCAPSA = *MIXERCAPSA 786 TypeDef LPMIXERCAPSA = *MIXERCAPSA 787 788 TypeDef MIXERCAPS = MIXERCAPSA 789 TypeDef PMIXERCAPS = PMIXERCAPSA 790 TypeDef LPMIXERCAPS = LPMIXERCAPSA 791 792 Declare Function mixerGetDevCaps Lib "winmm" Alias "mixerGetDevCapsA" (uMxId As DWord, pmxcaps As *MIXERCAPS, cbmxcaps As DWord) As MMRESULT 793 Declare Function mixerOpen Lib "winmm" (phmx As *HMIXER, uMxId As DWord, dwCallback As DWord, dwInstance As DWord, fdwOpen As DWord) As MMRESULT 794 Declare Function mixerClose Lib "winmm" (hmx As HMIXER) As MMRESULT 795 Declare Function mixerMessage Lib "winmm" (hmx As HMIXER, uMsg As DWord, dwParam1 As DWord, dwParam2 As DWord) As DWord 796 797 Type TARGET 798 dwType As DWord 799 dwDeviceID As DWord 800 wMid As Word 801 wPid As Word 802 vDriverVersion As MMVERSION 803 szPname[ELM(MAXPNAMELEN)] As Char 804 End Type 805 806 Type MIXERLINEA 807 cbStruct As DWord 808 dwDestination As DWord 809 dwSource As DWord 810 dwLineID As DWord 811 fdwLine As DWord 812 dwUser As DWord 813 dwComponentType As DWord 814 cChannels As DWord 815 cConnections As DWord 816 cControls As DWord 817 szShortName[ELM(MIXER_SHORT_NAME_CHARS)] As Char 818 szName[ELM(MIXER_LONG_NAME_CHARS)] As Char 819 Target As TARGET 820 End Type 821 TypeDef PMIXERLINEA = *MIXERLINEA 822 TypeDef LPMIXERLINEA = *MIXERLINEA 823 824 TypeDef MIXERLINE = MIXERLINEA 825 TypeDef PMIXERLINE = PMIXERLINEA 826 TypeDef LPMIXERLINE = LPMIXERLINEA 827 828 ' MIXERLINE.fdwLine 829 Const MIXERLINE_LINEF_ACTIVE = &H00000001 830 Const MIXERLINE_LINEF_DISCONNECTED = &H00008000 831 Const MIXERLINE_LINEF_SOURCE = &H80000000 832 833 ' MIXERLINE.dwComponentType 834 Const MIXERLINE_COMPONENTTYPE_DST_FIRST = &H00000000 835 Const MIXERLINE_COMPONENTTYPE_DST_UNDEFINED = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 0) 836 Const MIXERLINE_COMPONENTTYPE_DST_DIGITAL = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 1) 837 Const MIXERLINE_COMPONENTTYPE_DST_LINE = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 2) 838 Const MIXERLINE_COMPONENTTYPE_DST_MONITOR = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 3) 839 Const MIXERLINE_COMPONENTTYPE_DST_SPEAKERS = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 4) 840 Const MIXERLINE_COMPONENTTYPE_DST_HEADPHONES = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 5) 841 Const MIXERLINE_COMPONENTTYPE_DST_TELEPHONE = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 6) 842 Const MIXERLINE_COMPONENTTYPE_DST_WAVEIN = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 7) 843 Const MIXERLINE_COMPONENTTYPE_DST_VOICEIN = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 8) 844 Const MIXERLINE_COMPONENTTYPE_DST_LAST = (MIXERLINE_COMPONENTTYPE_DST_FIRST + 8) 845 846 Const MIXERLINE_COMPONENTTYPE_SRC_FIRST = &H00001000 847 Const MIXERLINE_COMPONENTTYPE_SRC_UNDEFINED = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 0) 848 Const MIXERLINE_COMPONENTTYPE_SRC_DIGITAL = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 1) 849 Const MIXERLINE_COMPONENTTYPE_SRC_LINE = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 2) 850 Const MIXERLINE_COMPONENTTYPE_SRC_MICROPHONE = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 3) 851 Const MIXERLINE_COMPONENTTYPE_SRC_SYNTHESIZER = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 4) 852 Const MIXERLINE_COMPONENTTYPE_SRC_COMPACTDISC = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 5) 853 Const MIXERLINE_COMPONENTTYPE_SRC_TELEPHONE = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 6) 854 Const MIXERLINE_COMPONENTTYPE_SRC_PCSPEAKER = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 7) 855 Const MIXERLINE_COMPONENTTYPE_SRC_WAVEOUT = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 8) 856 Const MIXERLINE_COMPONENTTYPE_SRC_AUXILIARY = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 9) 857 Const MIXERLINE_COMPONENTTYPE_SRC_ANALOG = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 10) 858 Const MIXERLINE_COMPONENTTYPE_SRC_LAST = (MIXERLINE_COMPONENTTYPE_SRC_FIRST + 10) 859 860 ' MIXERLINE.Target.dwType 861 Const MIXERLINE_TARGETTYPE_UNDEFINED = 0 862 Const MIXERLINE_TARGETTYPE_WAVEOUT = 1 863 Const MIXERLINE_TARGETTYPE_WAVEIN = 2 864 Const MIXERLINE_TARGETTYPE_MIDIOUT = 3 865 Const MIXERLINE_TARGETTYPE_MIDIIN = 4 866 Const MIXERLINE_TARGETTYPE_AUX = 5 867 868 Declare Function mixerGetLineInfo Lib "winmm" Alias "mixerGetLineInfoA" (hmxobj As HMIXEROBJ, pmxl As *MIXERLINE, fdwInfo As DWord) As MMRESULT 869 870 Const MIXER_GETLINEINFOF_DESTINATION = &H00000000 871 Const MIXER_GETLINEINFOF_SOURCE = &H00000001 872 Const MIXER_GETLINEINFOF_LINEID = &H00000002 873 Const MIXER_GETLINEINFOF_COMPONENTTYPE = &H00000003 874 Const MIXER_GETLINEINFOF_TARGETTYPE = &H00000004 875 Const MIXER_GETLINEINFOF_QUERYMASK = &H0000000F 876 877 Declare Function mixerGetID Lib "winmm" (hmxobj As HMIXEROBJ, puMxId As *DWord, fdwId As DWord) As MMRESULT 878 879 Type MIXERCONTROLA 880 cbStruct As DWord 881 dwControlID As DWord 882 dwControlType As DWord 883 fdwControl As DWord 884 cMultipleItems As DWord 885 szShortName[ELM(MIXER_SHORT_NAME_CHARS)] As Char 886 szName[ELM(MIXER_LONG_NAME_CHARS)] As Char 887 Bounds[ELM(6)] As DWord 888 Metrics[ELM(6)] As DWord 889 End Type 890 TypeDef PMIXERCONTROLA = *MIXERCONTROLA 891 TypeDef LPMIXERCONTROLA = *MIXERCONTROLA 892 893 TypeDef MIXERCONTROL = MIXERCONTROLA 894 TypeDef PMIXERCONTROL = PMIXERCONTROLA 895 TypeDef LPMIXERCONTROL = LPMIXERCONTROLA 896 897 ' MIXERCONTROL.fdwControl 898 Const MIXERCONTROL_CONTROLF_UNIFORM = &H00000001 899 Const MIXERCONTROL_CONTROLF_MULTIPLE = &H00000002 900 Const MIXERCONTROL_CONTROLF_DISABLED = &H80000000 901 902 ' MIXERCONTROL_CONTROLTYPE_xxx 903 Const MIXERCONTROL_CT_CLASS_MASK = &HF0000000 904 Const MIXERCONTROL_CT_CLASS_CUSTOM = &H00000000 905 Const MIXERCONTROL_CT_CLASS_METER = &H10000000 906 Const MIXERCONTROL_CT_CLASS_SWITCH = &H20000000 907 Const MIXERCONTROL_CT_CLASS_NUMBER = &H30000000 908 Const MIXERCONTROL_CT_CLASS_SLIDER = &H40000000 909 Const MIXERCONTROL_CT_CLASS_FADER = &H50000000 910 Const MIXERCONTROL_CT_CLASS_TIME = &H60000000 911 Const MIXERCONTROL_CT_CLASS_LIST = &H70000000 912 Const MIXERCONTROL_CT_SUBCLASS_MASK = &H0F000000 913 Const MIXERCONTROL_CT_SC_SWITCH_BOOLEAN = &H00000000 914 Const MIXERCONTROL_CT_SC_SWITCH_BUTTON = &H01000000 915 Const MIXERCONTROL_CT_SC_METER_POLLED = &H00000000 916 Const MIXERCONTROL_CT_SC_TIME_MICROSECS = &H00000000 917 Const MIXERCONTROL_CT_SC_TIME_MILLISECS = &H01000000 918 Const MIXERCONTROL_CT_SC_LIST_SINGLE = &H00000000 919 Const MIXERCONTROL_CT_SC_LIST_MULTIPLE = &H01000000 920 Const MIXERCONTROL_CT_UNITS_MASK = &H00FF0000 921 Const MIXERCONTROL_CT_UNITS_CUSTOM = &H00000000 922 Const MIXERCONTROL_CT_UNITS_BOOLEAN = &H00010000 923 Const MIXERCONTROL_CT_UNITS_SIGNED = &H00020000 924 Const MIXERCONTROL_CT_UNITS_UNSIGNED = &H00030000 925 Const MIXERCONTROL_CT_UNITS_DECIBELS = &H00040000 926 Const MIXERCONTROL_CT_UNITS_PERCENT = &H00050000 927 928 ' MIXERCONTROL.dwControlType 929 Const MIXERCONTROL_CONTROLTYPE_CUSTOM = (MIXERCONTROL_CT_CLASS_CUSTOM OR MIXERCONTROL_CT_UNITS_CUSTOM) 930 Const MIXERCONTROL_CONTROLTYPE_BOOLEANMETER = (MIXERCONTROL_CT_CLASS_METER OR MIXERCONTROL_CT_SC_METER_POLLED OR MIXERCONTROL_CT_UNITS_BOOLEAN) 931 Const MIXERCONTROL_CONTROLTYPE_SIGNEDMETER = (MIXERCONTROL_CT_CLASS_METER OR MIXERCONTROL_CT_SC_METER_POLLED OR MIXERCONTROL_CT_UNITS_SIGNED) 932 Const MIXERCONTROL_CONTROLTYPE_PEAKMETER = (MIXERCONTROL_CONTROLTYPE_SIGNEDMETER + 1) 933 Const MIXERCONTROL_CONTROLTYPE_UNSIGNEDMETER = (MIXERCONTROL_CT_CLASS_METER OR MIXERCONTROL_CT_SC_METER_POLLED OR MIXERCONTROL_CT_UNITS_UNSIGNED) 934 Const MIXERCONTROL_CONTROLTYPE_BOOLEAN = (MIXERCONTROL_CT_CLASS_SWITCH OR MIXERCONTROL_CT_SC_SWITCH_BOOLEAN OR MIXERCONTROL_CT_UNITS_BOOLEAN) 935 Const MIXERCONTROL_CONTROLTYPE_ONOFF = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 1) 936 Const MIXERCONTROL_CONTROLTYPE_MUTE = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 2) 937 Const MIXERCONTROL_CONTROLTYPE_MONO = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 3) 938 Const MIXERCONTROL_CONTROLTYPE_LOUDNESS = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 4) 939 Const MIXERCONTROL_CONTROLTYPE_STEREOENH = (MIXERCONTROL_CONTROLTYPE_BOOLEAN + 5) 940 Const MIXERCONTROL_CONTROLTYPE_BUTTON = (MIXERCONTROL_CT_CLASS_SWITCH OR MIXERCONTROL_CT_SC_SWITCH_BUTTON OR MIXERCONTROL_CT_UNITS_BOOLEAN) 941 Const MIXERCONTROL_CONTROLTYPE_DECIBELS = (MIXERCONTROL_CT_CLASS_NUMBER OR MIXERCONTROL_CT_UNITS_DECIBELS) 942 Const MIXERCONTROL_CONTROLTYPE_SIGNED = (MIXERCONTROL_CT_CLASS_NUMBER OR MIXERCONTROL_CT_UNITS_SIGNED) 943 Const MIXERCONTROL_CONTROLTYPE_UNSIGNED = (MIXERCONTROL_CT_CLASS_NUMBER OR MIXERCONTROL_CT_UNITS_UNSIGNED) 944 Const MIXERCONTROL_CONTROLTYPE_PERCENT = (MIXERCONTROL_CT_CLASS_NUMBER OR MIXERCONTROL_CT_UNITS_PERCENT) 945 Const MIXERCONTROL_CONTROLTYPE_SLIDER = (MIXERCONTROL_CT_CLASS_SLIDER OR MIXERCONTROL_CT_UNITS_SIGNED) 946 Const MIXERCONTROL_CONTROLTYPE_PAN = (MIXERCONTROL_CONTROLTYPE_SLIDER + 1) 947 Const MIXERCONTROL_CONTROLTYPE_QSOUNDPAN = (MIXERCONTROL_CONTROLTYPE_SLIDER + 2) 948 Const MIXERCONTROL_CONTROLTYPE_FADER = (MIXERCONTROL_CT_CLASS_FADER OR MIXERCONTROL_CT_UNITS_UNSIGNED) 949 Const MIXERCONTROL_CONTROLTYPE_VOLUME = (MIXERCONTROL_CONTROLTYPE_FADER + 1) 950 Const MIXERCONTROL_CONTROLTYPE_BASS = (MIXERCONTROL_CONTROLTYPE_FADER + 2) 951 Const MIXERCONTROL_CONTROLTYPE_TREBLE = (MIXERCONTROL_CONTROLTYPE_FADER + 3) 952 Const MIXERCONTROL_CONTROLTYPE_EQUALIZER = (MIXERCONTROL_CONTROLTYPE_FADER + 4) 953 Const MIXERCONTROL_CONTROLTYPE_SINGLESELECT = (MIXERCONTROL_CT_CLASS_LIST OR MIXERCONTROL_CT_SC_LIST_SINGLE OR MIXERCONTROL_CT_UNITS_BOOLEAN) 954 Const MIXERCONTROL_CONTROLTYPE_MUX = (MIXERCONTROL_CONTROLTYPE_SINGLESELECT + 1) 955 Const MIXERCONTROL_CONTROLTYPE_MULTIPLESELECT = (MIXERCONTROL_CT_CLASS_LIST OR MIXERCONTROL_CT_SC_LIST_MULTIPLE OR MIXERCONTROL_CT_UNITS_BOOLEAN) 956 Const MIXERCONTROL_CONTROLTYPE_MIXER = (MIXERCONTROL_CONTROLTYPE_MULTIPLESELECT + 1) 957 Const MIXERCONTROL_CONTROLTYPE_MICROTIME = (MIXERCONTROL_CT_CLASS_TIME OR MIXERCONTROL_CT_SC_TIME_MICROSECS OR MIXERCONTROL_CT_UNITS_UNSIGNED) 958 Const MIXERCONTROL_CONTROLTYPE_MILLITIME = (MIXERCONTROL_CT_CLASS_TIME OR MIXERCONTROL_CT_SC_TIME_MILLISECS OR MIXERCONTROL_CT_UNITS_UNSIGNED) 959 960 Type MIXERLINECONTROLSA 961 cbStruct As DWord 962 dwLineID As DWord 963 dwControl_ID_Type As DWord 964 cControls As DWord 965 cbmxctrl As DWord 966 pamxctrl As *MIXERCONTROL 967 End Type 968 \TypeDef PMIXERLINECONTROLSA = *MIXERLINECONTROLSA 969 TypeDef LPMIXERLINECONTROLSA = *MIXERLINECONTROLSA 970 971 TypeDef MIXERLINECONTROLS = MIXERLINECONTROLSA 972 TypeDef PMIXERLINECONTROLS = PMIXERLINECONTROLSA 973 TypeDef LPMIXERLINECONTROLS = LPMIXERLINECONTROLSA 974 975 Declare Function mixerGetLineControls Lib "winmm" Alias "mixerGetLineControlsA" (hmxobj As HMIXEROBJ, pmxlc As *MIXERLINECONTROLS, fdwControls As DWord) As MMRESULT 976 977 Const MIXER_GETLINECONTROLSF_ALL = &H00000000 978 Const MIXER_GETLINECONTROLSF_ONEBYID = &H00000001 979 Const MIXER_GETLINECONTROLSF_ONEBYTYPE = &H00000002 980 Const MIXER_GETLINECONTROLSF_QUERYMASK = &H0000000F 981 982 Type MIXERCONTROLDETAILS 983 cbStruct As DWord 984 dwControlID As DWord 985 cChannels As DWord 986 cMultipleItems As DWord 987 cbDetails As DWord 988 paDetails As VoidPtr 989 End Type 990 TypeDef PMIXERCONTROLDETAILS = *MIXERCONTROLDETAILS 991 TypeDef LPMIXERCONTROLDETAILS = *MIXERCONTROLDETAILS 992 993 Type MIXERCONTROLDETAILS_LISTTEXTA 994 dwParam1 As DWord 995 dwParam2 As DWord 996 szName[ELM(MIXER_LONG_NAME_CHARS)] As Char 997 End Type 998 TypeDef PMIXERCONTROLDETAILS_LISTTEXTA = *MIXERCONTROLDETAILS_LISTTEXTA 999 TypeDef LPMIXERCONTROLDETAILS_LISTTEXTA = *MIXERCONTROLDETAILS_LISTTEXTA 1000 1001 TypeDef MIXERCONTROLDETAILS_LISTTEXT = MIXERCONTROLDETAILS_LISTTEXTA 1002 TypeDef PMIXERCONTROLDETAILS_LISTTEXT = PMIXERCONTROLDETAILS_LISTTEXTA 1003 TypeDef LPMIXERCONTROLDETAILS_LISTTEXT = LPMIXERCONTROLDETAILS_LISTTEXTA 1004 1005 Type MIXERCONTROLDETAILS_BOOLEAN 1006 fValue As Long 1007 End Type 1008 TypeDef PMIXERCONTROLDETAILS_BOOLEAN = *MIXERCONTROLDETAILS_BOOLEAN 1009 TypeDef LPMIXERCONTROLDETAILS_BOOLEAN = *MIXERCONTROLDETAILS_BOOLEAN 1010 1011 Type MIXERCONTROLDETAILS_SIGNED 1012 lValue As Long 1013 End Type 1014 TypeDef PMIXERCONTROLDETAILS_SIGNED = *MIXERCONTROLDETAILS_SIGNED 1015 TypeDef LPMIXERCONTROLDETAILS_SIGNED = *MIXERCONTROLDETAILS_SIGNED 1016 1017 Type MIXERCONTROLDETAILS_UNSIGNED 1018 dwValue As DWord 1019 End Type 1020 TypeDef PMIXERCONTROLDETAILS_UNSIGNED = *MIXERCONTROLDETAILS_UNSIGNED 1021 TypeDef LPMIXERCONTROLDETAILS_UNSIGNED = *MIXERCONTROLDETAILS_UNSIGNED 1022 1023 Declare Function mixerGetControlDetailsA Lib "winmm" (hmxobj As HMIXEROBJ, pmxcd As *MIXERCONTROLDETAILS, fdwDetails As DWord) As MMRESULT 1024 Declare Function mixerGetControlDetailsW Lib "winmm" (hmxobj As HMIXEROBJ, pmxcd As *MIXERCONTROLDETAILS, fdwDetails As DWord) As MMRESULT 1025 Declare Function mixerGetControlDetails Lib "winmm" Alias "mixerGetControlDetailsA" (hmxobj As HMIXEROBJ, pmxcd As *MIXERCONTROLDETAILS, fdwDetails As DWord) As MMRESULT 1026 1027 Const MIXER_GETCONTROLDETAILSF_VALUE = &H00000000 1028 Const MIXER_GETCONTROLDETAILSF_LISTTEXT = &H00000001 1029 Const MIXER_GETCONTROLDETAILSF_QUERYMASK = &H0000000F 1030 1031 Declare Function mixerSetControlDetails Lib "winmm" (hmxobj As HMIXEROBJ, pmxcd As *MIXERCONTROLDETAILS, fdwDetails As DWord) As MMRESULT 1032 1033 Const MIXER_SETCONTROLDETAILSF_VALUE = &H00000000 1034 Const MIXER_SETCONTROLDETAILSF_CUSTOM = &H00000001 1035 Const MIXER_SETCONTROLDETAILSF_QUERYMASK = &H0000000F 1036 1037 1038 '-------------------------------------------------------- 1039 ' Timer support 1040 1041 ' timer error 1042 Const TIMERR_NOERROR = (0) 1043 Const TIMERR_NOCANDO = (TIMERR_BASE+1) 1044 Const TIMERR_STRUCT = (TIMERR_BASE+33) 1045 1046 TypeDef LPTIMECALLBACK = *Sub(uTimerID As DWord, uMsg As DWord, dwUser As DWord, dw1 As DWord, dw2 As DWord) 1047 1048 Const TIME_ONESHOT = &H0000 1049 Const TIME_PERIODIC = &H0001 1050 1051 Const TIME_CALLBACK_FUNCTION = &H0000 1052 Const TIME_CALLBACK_EVENT_SET = &H0010 1053 Const TIME_CALLBACK_EVENT_PULSE = &H0020 1054 1055 ' timer device capabilities data structure 1056 Type TIMECAPS 1057 wPeriodMin As DWord 1058 wPeriodMax As DWord 1059 End Type 1060 TypeDef PTIMECAPS = *TIMECAPS 1061 TypeDef NPTIMECAPS = *TIMECAPS 1062 TypeDef LPTIMECAPS = *TIMECAPS 1063 1064 ' timer function prototypes 1065 Declare Function timeGetSystemTime Lib "winmm" (pmmt As *MMTIME, cbmmt As DWord) As MMRESULT 1066 Declare Function timeGetTime Lib "winmm" () As DWord 1067 Declare Function timeSetEvent Lib "winmm" (uDelay As DWord, uResolution As DWord, fptc As LPTIMECALLBACK, dwUser As DWord, fuEvent As DWord) As MMRESULT 1068 Declare Function timeKillEvent Lib "winmm" (uTimerID As DWord) As MMRESULT 1069 Declare Function timeGetDevCaps Lib "winmm" (ptc As *TIMECAPS, cbtc As DWord) As MMRESULT 1070 Declare Function timeBeginPeriod Lib "winmm" (uPeriod As DWord) As MMRESULT 1071 Declare Function timeEndPeriod Lib "winmm" (uPeriod As DWord) As MMRESULT 1072 1073 1074 '-------------------------------------------------------- 1075 ' Joystick support 1076 1077 ' joystick error 1078 Const JOYERR_NOERROR = (0) 1079 Const JOYERR_PARMS = (JOYERR_BASE+5) 1080 Const JOYERR_NOCANDO = (JOYERR_BASE+6) 1081 Const JOYERR_UNPLUGGED = (JOYERR_BASE+7) 1082 1083 ' constants used with JOYINFO and JOYINFOEX structures and MM_JOY* messages 1084 Const JOY_BUTTON1 = &H0001 1085 Const JOY_BUTTON2 = &H0002 1086 Const JOY_BUTTON3 = &H0004 1087 Const JOY_BUTTON4 = &H0008 1088 Const JOY_BUTTON1CHG = &H0100 1089 Const JOY_BUTTON2CHG = &H0200 1090 Const JOY_BUTTON3CHG = &H0400 1091 Const JOY_BUTTON4CHG = &H0800 1092 1093 ' constants used with JOYINFOEX 1094 Const JOY_BUTTON5 = &H00000010 1095 Const JOY_BUTTON6 = &H00000020 1096 Const JOY_BUTTON7 = &H00000040 1097 Const JOY_BUTTON8 = &H00000080 1098 Const JOY_BUTTON9 = &H00000100 1099 Const JOY_BUTTON10 = &H00000200 1100 Const JOY_BUTTON11 = &H00000400 1101 Const JOY_BUTTON12 = &H00000800 1102 Const JOY_BUTTON13 = &H00001000 1103 Const JOY_BUTTON14 = &H00002000 1104 Const JOY_BUTTON15 = &H00004000 1105 Const JOY_BUTTON16 = &H00008000 1106 Const JOY_BUTTON17 = &H00010000 1107 Const JOY_BUTTON18 = &H00020000 1108 Const JOY_BUTTON19 = &H00040000 1109 Const JOY_BUTTON20 = &H00080000 1110 Const JOY_BUTTON21 = &H00100000 1111 Const JOY_BUTTON22 = &H00200000 1112 Const JOY_BUTTON23 = &H00400000 1113 Const JOY_BUTTON24 = &H00800000 1114 Const JOY_BUTTON25 = &H01000000 1115 Const JOY_BUTTON26 = &H02000000 1116 Const JOY_BUTTON27 = &H04000000 1117 Const JOY_BUTTON28 = &H08000000 1118 Const JOY_BUTTON29 = &H10000000 1119 Const JOY_BUTTON30 = &H20000000 1120 Const JOY_BUTTON31 = &H40000000 1121 Const JOY_BUTTON32 = &H80000000 1122 1123 ' constants used with JOYINFOEX structure 1124 Const JOY_POVCENTERED = (-1) 1125 Const JOY_POVFORWARD = 0 1126 Const JOY_POVRIGHT = 9000 1127 Const JOY_POVBACKWARD = 18000 1128 Const JOY_POVLEFT = 27000 1129 1130 Const JOY_RETURNX = &H00000001 1131 Const JOY_RETURNY = &H00000002 1132 Const JOY_RETURNZ = &H00000004 1133 Const JOY_RETURNR = &H00000008 1134 Const JOY_RETURNU = &H00000010 1135 Const JOY_RETURNV = &H00000020 1136 Const JOY_RETURNPOV = &H00000040 1137 Const JOY_RETURNBUTTONS = &H00000080 1138 Const JOY_RETURNRAWDATA = &H00000100 1139 Const JOY_RETURNPOVCTS = &H00000200 1140 Const JOY_RETURNCENTERED = &H00000400 1141 Const JOY_USEDEADZONE = &H00000800 1142 Const JOY_RETURNALL = (JOY_RETURNX OR JOY_RETURNY OR JOY_RETURNZ OR JOY_RETURNR OR JOY_RETURNU OR JOY_RETURNV OR JOY_RETURNPOV OR JOY_RETURNBUTTONS) 1143 Const JOY_CAL_READALWAYS = &H00010000 1144 Const JOY_CAL_READXYONLY = &H00020000 1145 Const JOY_CAL_READ3 = &H00040000 1146 Const JOY_CAL_READ4 = &H00080000 1147 Const JOY_CAL_READXONLY = &H00100000 1148 Const JOY_CAL_READYONLY = &H00200000 1149 Const JOY_CAL_READ5 = &H00400000 1150 Const JOY_CAL_READ6 = &H00800000 1151 Const JOY_CAL_READZONLY = &H01000000 1152 Const JOY_CAL_READRONLY = &H02000000 1153 Const JOY_CAL_READUONLY = &H04000000 1154 Const JOY_CAL_READVONLY = &H08000000 1155 1156 ' joystick ID constants 1157 Const JOYSTICKID1 = 0 1158 Const JOYSTICKID2 = 1 1159 1160 ' joystick driver capabilites 1161 Const JOYCAPS_HASZ = &H0001 1162 Const JOYCAPS_HASR = &H0002 1163 Const JOYCAPS_HASU = &H0004 1164 Const JOYCAPS_HASV = &H0008 1165 Const JOYCAPS_HASPOV = &H0010 1166 Const JOYCAPS_POV4DIR = &H0020 1167 Const JOYCAPS_POVCTS = &H0040 1168 1169 Type JOYCAPSA 1170 wMid As Word 1171 wPid As Word 1172 szPname[ELM(MAXPNAMELEN)] As Char 1173 wXmin As DWord 1174 wXmax As DWord 1175 wYmin As DWord 1176 wYmax As DWord 1177 wZmin As DWord 1178 wZmax As DWord 1179 wNumButtons As DWord 1180 wPeriodMin As DWord 1181 wPeriodMax As DWord 1182 wRmin As DWord 1183 wRmax As DWord 1184 wUmin As DWord 1185 wUmax As DWord 1186 wVmin As DWord 1187 wVmax As DWord 1188 wCaps As DWord 1189 wMaxAxes As DWord 1190 wNumAxes As DWord 1191 wMaxButtons As DWord 1192 szRegKey[ELM(MAXPNAMELEN)] As Char 1193 szOEMVxD[ELM(MAX_JOYSTICKOEMVXDNAME)] As Char 1194 End Type 1195 TypeDef PJOYCAPSA = *JOYCAPSA 1196 TypeDef NPJOYCAPSA = *JOYCAPSA 1197 TypeDef LPJOYCAPSA = *JOYCAPSA 1198 1199 TypeDef JOYCAPS = JOYCAPSA 1200 TypeDef PJOYCAPS = PJOYCAPSA 1201 TypeDef NPJOYCAPS = NPJOYCAPSA 1202 TypeDef LPJOYCAPS = LPJOYCAPSA 1203 1204 Type JOYINFO 1205 wXpos As DWord 1206 wYpos As DWord 1207 wZpos As DWord 1208 wButtons As DWord 1209 End Type 1210 \TypeDef PJOYINFO = *JOYINFO 1211 TypeDef NPJOYINFO = *JOYINFO 1212 TypeDef LPJOYINFO = *JOYINFO 1213 1214 Type JOYINFOEX 1215 dwSize As DWord 1216 dwFlags As DWord 1217 dwXpos As DWord 1218 dwYpos As DWord 1219 dwZpos As DWord 1220 dwRpos As DWord 1221 dwUpos As DWord 1222 dwVpos As DWord 1223 dwButtons As DWord 1224 dwButtonNumber As DWord 1225 dwPOV As DWord 1226 dwReserved1 As DWord 1227 dwReserved2 As DWord 1228 End Type 1229 TypeDef PJOYINFOEX = *JOYINFOEX 1230 TypeDef NPJOYINFOEX = *JOYINFOEX 1231 TypeDef LPJOYINFOEX = *JOYINFOEX 1232 1233 ' joystick function prototypes 1234 Declare Function joyGetNumDevs Lib "winmm" () As DWord 1235 Declare Function joyGetDevCaps Lib "winmm" Alias "joyGetDevCapsA" (uJoyID As DWord, pjc As *JOYCAPS, cbjc As DWord) As MMRESULT 1236 Declare Function joyGetPos Lib "winmm" (uJoyID As DWord, pji As *JOYINFO) As MMRESULT 1237 Declare Function joyGetPosEx Lib "winmm" (uJoyID As DWord, pji As *JOYINFOEX) As MMRESULT 1238 Declare Function joyGetThreshold Lib "winmm" (uJoyID As DWord, puThreshold As *DWord) As MMRESULT 1239 Declare Function joyReleaseCapture Lib "winmm" (uJoyID As DWord) As MMRESULT 1240 Declare Function joySetCapture Lib "winmm" (hwnd As HWND, uJoyID As DWord, uPeriod As DWord, fChanged As BOOL) As MMRESULT 1241 Declare Function joySetThreshold Lib "winmm" (uJoyID As DWord, uThreshold As DWord) As MMRESULT 1242 1243 1244 '-------------------------------------------------------- 1245 ' Multimedia File I/O support 1246 1247 ' MMIO error return values 1248 Const MMIOERR_BASE = 256 1249 Const MMIOERR_FILENOTFOUND = (MMIOERR_BASE + 1) 1250 Const MMIOERR_OUTOFMEMORY = (MMIOERR_BASE + 2) 1251 Const MMIOERR_CANNOTOPEN = (MMIOERR_BASE + 3) 1252 Const MMIOERR_CANNOTCLOSE = (MMIOERR_BASE + 4) 1253 Const MMIOERR_CANNOTREAD = (MMIOERR_BASE + 5) 1254 Const MMIOERR_CANNOTWRITE = (MMIOERR_BASE + 6) 1255 Const MMIOERR_CANNOTSEEK = (MMIOERR_BASE + 7) 1256 Const MMIOERR_CANNOTEXPAND = (MMIOERR_BASE + 8) 1257 Const MMIOERR_CHUNKNOTFOUND = (MMIOERR_BASE + 9) 1258 Const MMIOERR_UNBUFFERED = (MMIOERR_BASE + 10) 1259 Const MMIOERR_PATHNOTFOUND = (MMIOERR_BASE + 11) 1260 Const MMIOERR_ACCESSDENIED = (MMIOERR_BASE + 12) 1261 Const MMIOERR_SHARINGVIOLATION = (MMIOERR_BASE + 13) 1262 Const MMIOERR_NETWORKERROR = (MMIOERR_BASE + 14) 1263 Const MMIOERR_TOOMANYOPENFILES = (MMIOERR_BASE + 15) 1264 Const MMIOERR_INVALIDFILE = (MMIOERR_BASE + 16) 1265 1266 ' MMIO constants 1267 Const CFSEPCHAR = "+" 1268 1269 ' MMIO data types 1270 TypeDef FOURCC = DWord 1271 TypeDef HPSTR = *Char 1272 TypeDef HMMIO = VoidPtr 1273 1274 TypeDef LPMMIOPROC = *Function(lpmmioinfo As LPSTR, uMsg As DWord, lParam1 As LPARAM, lParam2 As LPARAM) As LRESULT 1275 1276 Type MMIOINFO 1277 dwFlags As DWord 1278 fccIOProc As FOURCC 1279 pIOProc As LPMMIOPROC 1280 wErrorRet As DWord 1281 htask As HTASK 1282 cchBuffer As Long 1283 pchBuffer As HPSTR 1284 pchNext As HPSTR 1285 pchEndRead As HPSTR 1286 pchEndWrite As HPSTR 1287 lBufOffset As Long 1288 lDiskOffset As Long 1289 adwInfo[ELM(3)] As DWord 1290 dwReserved1 As DWord 1291 dwReserved2 As DWord 1292 hmmio As HMMIO 1293 End Type 1294 TypeDef PMMIOINFO = *MMIOINFO 1295 TypeDef NPMMIOINFO = *MMIOINFO 1296 TypeDef LPMMIOINFO = *MMIOINFO 1297 1298 Type MMCKINFO 1299 ckid As FOURCC 1300 cksize As DWord 1301 fccType As FOURCC 1302 dwDataOffset As DWord 1303 dwFlags As DWord 1304 End Type 1305 TypeDef PMMCKINFO = *MMCKINFO 1306 TypeDef NPMMCKINFO = *MMCKINFO 1307 TypeDef LPMMCKINFO = *MMCKINFO 1308 1309 Const MMIO_RWMODE = &H00000003 1310 Const MMIO_SHAREMODE = &H00000070 1311 Const MMIO_CREATE = &H00001000 1312 Const MMIO_PARSE = &H00000100 1313 Const MMIO_DELETE = &H00000200 1314 Const MMIO_EXIST = &H00004000 1315 Const MMIO_ALLOCBUF = &H00010000 1316 Const MMIO_GETTEMP = &H00020000 1317 Const MMIO_DIRTY = &H10000000 1318 Const MMIO_READ = &H00000000 1319 Const MMIO_WRITE = &H00000001 1320 Const MMIO_READWRITE = &H00000002 1321 Const MMIO_COMPAT = &H00000000 1322 Const MMIO_EXCLUSIVE = &H00000010 1323 Const MMIO_DENYWRITE = &H00000020 1324 Const MMIO_DENYREAD = &H00000030 1325 Const MMIO_DENYNONE = &H00000040 1326 Const MMIO_FHOPEN = &H0010 1327 Const MMIO_EMPTYBUF = &H0010 1328 Const MMIO_TOUPPER = &H0010 1329 Const MMIO_INSTALLPROC = &H00010000 1330 Const MMIO_GLOBALPROC = &H10000000 1331 Const MMIO_REMOVEPROC = &H00020000 1332 Const MMIO_UNICODEPROC = &H01000000 1333 Const MMIO_FINDPROC = &H00040000 1334 Const MMIO_FINDCHUNK = &H0010 1335 Const MMIO_FINDRIFF = &H0020 1336 Const MMIO_FINDLIST = &H0040 1337 Const MMIO_CREATERIFF = &H0020 1338 Const MMIO_CREATELIST = &H0040 1339 1340 Const MMIOM_READ = MMIO_READ 1341 Const MMIOM_WRITE = MMIO_WRITE 1342 Const MMIOM_SEEK = 2 1343 Const MMIOM_OPEN = 3 1344 Const MMIOM_CLOSE = 4 1345 Const MMIOM_WRITEFLUSH = 5 1346 Const MMIOM_RENAME = 6 1347 Const MMIOM_USER = &H8000 1348 1349 Const FOURCC_RIFF = MAKEFOURCC(&H52, &H49, &H46, &H46) 1350 Const FOURCC_LIST = MAKEFOURCC(&H4C, &H49, &H53, &H54) 1351 Const FOURCC_DOS = MAKEFOURCC(&H44, &H4F, &H53, &H20) 1352 Const FOURCC_MEM = MAKEFOURCC(&H4D, &H45, &H4D, &H20) 1353 1354 Const SEEK_SET = 0 1355 Const SEEK_CUR = 1 1356 Const SEEK_END = 2 1357 1358 Const MMIO_DEFAULTBUFFER = 8192 1359 1360 Function mmioFOURCC(ch0 As String, ch1 As String, ch2 As String, ch3 As String) As FOURCC 1361 mmioFOURCC = MAKEFOURCC(Asc(ch0), Asc(ch1), Asc(ch2), Asc(ch3)) 1362 End Function 1363 1364 ' MMIO function prototypes 1365 Declare Function mmioStringToFOURCC Lib "winmm" Alias "mmioStringToFOURCCA" (sz As LPSTR, uFlags As DWord) As FOURCC 1366 Declare Function mmioInstallIOProc Lib "winmm" Alias "mmioInstallIOProcA" (fccIOProc As FOURCC, pIOProc As LPMMIOPROC, dwFlags As DWord) As LPMMIOPROC 1367 Declare Function mmioOpen Lib "winmm" Alias "mmioOpenA" (pszFileName As LPSTR, pmmioinfo As *MMIOINFO, fdwOpen As DWord) As HMMIO 1368 Declare Function mmioRename Lib "winmm" Alias "mmioRenameA" (pszFileName As LPSTR, pszNewFileName As LPSTR, pmmioinfo As *MMIOINFO, fdwRename As DWord) As MMRESULT 1369 Declare Function mmioClose Lib "winmm" (hmmio As HMMIO, fuClose As DWord) As MMRESULT 1370 Declare Function mmioRead Lib "winmm" (hmmio As HMMIO, pch As HPSTR, cch As Long) As Long 1371 Declare Function mmioWrite Lib "winmm" (hmmio As HMMIO, pch As HPSTR, cch As Long) As Long 1372 Declare Function mmioSeek Lib "winmm" (hmmio As HMMIO, lOffset As Long, iOrigin As Long) As Long 1373 Declare Function mmioGetInfo Lib "winmm" (hmmio As HMMIO, pmmioinfo As *MMIOINFO, fuInfo As DWord) As MMRESULT 1374 Declare Function mmioSetInfo Lib "winmm" (hmmio As HMMIO, pmmioinfo As *MMIOINFO, fuInfo As DWord) As MMRESULT 1375 Declare Function mmioSetBuffer Lib "winmm" (hmmio As HMMIO, pchBuffer As LPSTR, cchBuffer As Long, fuBuffer As DWord) As MMRESULT 1376 Declare Function mmioFlush Lib "winmm" (hmmio As HMMIO, fuFlush As DWord) As MMRESULT 1377 Declare Function mmioAdvance Lib "winmm" (hmmio As HMMIO, pmmioinfo As *MMIOINFO, fuAdvance As DWord) As MMRESULT 1378 Declare Function mmioSendMessage Lib "winmm" (hmmio As HMMIO, uMsg As DWord, lParam1 As LPARAM, lParam2 As LPARAM) As LRESULT 1379 Declare Function mmioDescend Lib "winmm" (hmmio As HMMIO, pmmcki As *MMCKINFO, pmmckiParent As *MMCKINFO, fuDescend As DWord) As MMRESULT 1380 Declare Function mmioAscend Lib "winmm" (hmmio As HMMIO, pmmcki As *MMCKINFO, fuAscend As DWord) As MMRESULT 1381 Declare Function mmioCreateChunk Lib "winmm" (hmmio As HMMIO, pmmcki As *MMCKINFO, fuCreate As DWord) As MMRESULT 1382 1383 1384 '-------------------------------------------------------- 1385 ' MCI support 707 1386 708 1387 '--------------------------------------------------------
Note:
See TracChangeset
for help on using the changeset viewer.