aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authork-m_schindler <k-m_schindler@b956fd51-792f-4845-bead-9b4dfca2ff2c>2009-04-09 23:52:22 +0000
committerk-m_schindler <k-m_schindler@b956fd51-792f-4845-bead-9b4dfca2ff2c>2009-04-09 23:52:22 +0000
commit1f6d632264411399a142393da0cbc2fb478159b2 (patch)
tree96fcd51b99835afc996b96b55c02f2d1d0a0d2ef /src
parent9ec474eb703bfb72a88b26f63d40039c860919e6 (diff)
downloadusdx-1f6d632264411399a142393da0cbc2fb478159b2.tar.gz
usdx-1f6d632264411399a142393da0cbc2fb478159b2.tar.xz
usdx-1f6d632264411399a142393da0cbc2fb478159b2.zip
Warnings and Notes cleanup
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1663 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to 'src')
-rw-r--r--src/base/URecord.pas10
-rw-r--r--src/media/UAudioInput_Bass.pas2
2 files changed, 5 insertions, 7 deletions
diff --git a/src/base/URecord.pas b/src/base/URecord.pas
index 8f37262d..2c2093a0 100644
--- a/src/base/URecord.pas
+++ b/src/base/URecord.pas
@@ -54,7 +54,7 @@ type
function GetToneString: string; // converts a tone to its string represenatation;
- procedure BoostBuffer(Buffer: PByteArray; Size: cardinal);
+ procedure BoostBuffer(Buffer: PByteArray; Size: integer);
procedure ProcessNewBuffer(Buffer: PByteArray; BufferSize: integer);
// we call it to analyze sound by checking Autocorrelation
@@ -135,7 +135,7 @@ type
procedure UpdateInputDeviceConfig;
// handle microphone input
- procedure HandleMicrophoneData(Buffer: PByteArray; Size: cardinal;
+ procedure HandleMicrophoneData(Buffer: PByteArray; Size: integer;
InputDevice: TAudioInputDevice);
end;
@@ -459,7 +459,7 @@ begin
Result := '-';
end;
-procedure TCaptureBuffer.BoostBuffer(Buffer: PByteArray; Size: cardinal);
+procedure TCaptureBuffer.BoostBuffer(Buffer: PByteArray; Size: integer);
var
i: integer;
Value: longint;
@@ -602,7 +602,7 @@ end;
* Length - number of bytes in Buffer
* Input - Soundcard-Input used for capture
*}
-procedure TAudioInputProcessor.HandleMicrophoneData(Buffer: PByteArray; Size: cardinal; InputDevice: TAudioInputDevice);
+procedure TAudioInputProcessor.HandleMicrophoneData(Buffer: PByteArray; Size: integer; InputDevice: TAudioInputDevice);
var
MultiChannelBuffer: PByteArray; // buffer handled as array of bytes (offset relative to channel)
SingleChannelBuffer: PByteArray; // temporary buffer for new samples per channel
@@ -611,13 +611,11 @@ var
CaptureChannel: TCaptureBuffer;
AudioFormat: TAudioFormatInfo;
SampleSize: integer;
- SampleCount: integer;
SamplesPerChannel: integer;
i: integer;
begin
AudioFormat := InputDevice.AudioFormat;
SampleSize := AudioSampleSize[AudioFormat.Format];
- SampleCount := Size div SampleSize;
SamplesPerChannel := Size div AudioFormat.FrameSize;
SingleChannelBufferSize := SamplesPerChannel * SampleSize;
diff --git a/src/media/UAudioInput_Bass.pas b/src/media/UAudioInput_Bass.pas
index cf292c45..ad6c3818 100644
--- a/src/media/UAudioInput_Bass.pas
+++ b/src/media/UAudioInput_Bass.pas
@@ -95,7 +95,7 @@ var
* user - players associated with left/right channels
*}
function MicrophoneCallback(stream: HSTREAM; buffer: Pointer;
- len: Cardinal; inputDevice: Pointer): boolean; {$IFDEF MSWINDOWS}stdcall;{$ELSE}cdecl;{$ENDIF}
+ len: integer; inputDevice: Pointer): boolean; {$IFDEF MSWINDOWS}stdcall;{$ELSE}cdecl;{$ENDIF}
begin
AudioInputProcessor.HandleMicrophoneData(buffer, len, inputDevice);
Result := true;