+ added the win16api sound support functions

git-svn-id: trunk@31822 -
This commit is contained in:
nickysn 2015-09-24 16:21:37 +00:00
parent 926d66b9f5
commit 6767906755
2 changed files with 66 additions and 0 deletions

View File

@ -1237,3 +1237,28 @@ function EnableHardwareInput(fEnableInput: BOOL): BOOL; external 'USER';
{ Help support }
function WinHelp(hwndMain: HWND; lpszHelp: LPCSTR; usCommand: UINT; ulData: DWORD): BOOL; external 'USER';
{ Sound support }
function OpenSound: SmallInt; external 'SOUND';
procedure CloseSound; external 'SOUND';
function StartSound: SmallInt; external 'SOUND';
function StopSound: SmallInt; external 'SOUND';
function SetVoiceQueueSize(nVoice, cbQueue: SmallInt): SmallInt; external 'SOUND';
function SetVoiceNote(voice, value, length, cdots: SmallInt): SmallInt; external 'SOUND';
function SetVoiceAccent(nVoice, nTempo, nVolume, fnMode, nPitch: SmallInt): SmallInt; external 'SOUND';
function SetVoiceEnvelope(nVoice, nShape, nRepeat: SmallInt): SmallInt; external 'SOUND';
function SetVoiceSound(nVoice: SmallInt; dwFrequency: DWORD; nDuration: SmallInt): SmallInt; external 'SOUND';
function SetVoiceThreshold(voice, cNotesThreshold: SmallInt): SmallInt; external 'SOUND';
function GetThresholdEvent: LPINT; external 'SOUND';
function GetThresholdStatus: SmallInt; external 'SOUND';
function SetSoundNoise(fnSource, nDuration: SmallInt): SmallInt; external 'SOUND';
function WaitSoundState(fnState: SmallInt): SmallInt; external 'SOUND';
function SyncAllVoices: SmallInt; external 'SOUND';
function CountVoiceNotes(nvoice: SmallInt): SmallInt; external 'SOUND';

View File

@ -2726,3 +2726,44 @@ type
rgchMember: array [0..1] of char;
end;
THelpWinInfo = HELPWININFO;
{ Sound support }
const
{ SetSoundNoise() Sources }
S_PERIOD512 = 0;
S_PERIOD1024 = 1;
S_PERIOD2048 = 2;
S_PERIODVOICE = 3;
S_WHITE512 = 4;
S_WHITE1024 = 5;
S_WHITE2048 = 6;
S_WHITEVOICE = 7;
{ WaitSoundState() constants }
S_QUEUEEMPTY = 0;
S_THRESHOLD = 1;
S_ALLTHRESHOLD = 2;
{ Accent Modes }
S_NORMAL = 0;
S_LEGATO = 1;
S_STACCATO = 2;
{ Error return values }
S_SERDVNA = (-1);
S_SEROFM = (-2);
S_SERMACT = (-3);
S_SERQFUL = (-4);
S_SERBDNT = (-5);
S_SERDLN = (-6);
S_SERDCC = (-7);
S_SERDTP = (-8);
S_SERDVL = (-9);
S_SERDMD = (-10);
S_SERDSH = (-11);
S_SERDPT = (-12);
S_SERDFQ = (-13);
S_SERDDR = (-14);
S_SERDSR = (-15);
S_SERDST = (-16);