aboutsummaryrefslogtreecommitdiffstats
path: root/Game/Code/Classes/UMedia_dummy.pas
diff options
context:
space:
mode:
authortobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c>2008-05-09 19:19:28 +0000
committertobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c>2008-05-09 19:19:28 +0000
commitb5a738fa52c8b0f2212deb5febd2d7f0b8f6544f (patch)
tree3c2812cffdd035b385d5b0f0f8f5ea0702973739 /Game/Code/Classes/UMedia_dummy.pas
parent37744cee627605db0675efd3a6e0c42bd51c48d6 (diff)
downloadusdx-b5a738fa52c8b0f2212deb5febd2d7f0b8f6544f.tar.gz
usdx-b5a738fa52c8b0f2212deb5febd2d7f0b8f6544f.tar.xz
usdx-b5a738fa52c8b0f2212deb5febd2d7f0b8f6544f.zip
- input-source selection works now (with bass or portaudio with portmixer)
- audio-effects (DSP) interface for audio-playback plus a simple voice removal example (does not sound that good) - FFMpeg support for BASS - audio-clock for FFMpeg for GetPosition and synchronisation - more compatible seeking in FFMpeg - clean termination of the audio interfaces/streams (especially ffmpeg) - Audio output device enumeration (selection will be added later to the sounds option screen) - display of threshold and volume in the record-options screen - threshold and volume can be changed with the 'T' (threshold) and '+'/'-' (source volume) keys - added a FadeIn() method to the IAudioPlayback interface - some minor changes to the audio classes/screens - new base-class for audio-playback classes (used by bass, portaudio and sdl) git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@1078 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to 'Game/Code/Classes/UMedia_dummy.pas')
-rw-r--r--Game/Code/Classes/UMedia_dummy.pas38
1 files changed, 33 insertions, 5 deletions
diff --git a/Game/Code/Classes/UMedia_dummy.pas b/Game/Code/Classes/UMedia_dummy.pas
index dcdcd710..ad3aa94e 100644
--- a/Game/Code/Classes/UMedia_dummy.pas
+++ b/Game/Code/Classes/UMedia_dummy.pas
@@ -30,8 +30,9 @@ var
singleton_dummy : IVideoPlayback;
type
- Tmedia_dummy = class( TInterfacedObject, IVideoPlayback, IVideoVisualization, IAudioPlayback, IAudioInput )
+ TMedia_dummy = class( TInterfacedObject, IVideoPlayback, IVideoVisualization, IAudioPlayback, IAudioInput )
private
+ DummyOutputDeviceList: TAudioOutputDeviceList;
public
constructor create();
function GetName: String;
@@ -53,6 +54,7 @@ type
// IAudioInput
function InitializeRecord: boolean;
+ function FinalizeRecord: boolean;
procedure CaptureStart;
procedure CaptureStop;
procedure GetFFTData(var data: TFFTData);
@@ -60,8 +62,12 @@ type
// IAudioPlayback
function InitializePlayback: boolean;
+ function FinalizePlayback: boolean;
+
+ function GetOutputDeviceList(): TAudioOutputDeviceList;
+ procedure FadeIn(Time: real; TargetVolume: integer);
+ procedure SetAppVolume(Volume: integer);
procedure SetVolume(Volume: integer);
- procedure SetMusicVolume(Volume: integer);
procedure SetLoop(Enabled: boolean);
procedure Rewind;
@@ -124,7 +130,7 @@ procedure Tmedia_dummy.SetPosition(Time: real);
begin
end;
-function Tmedia_dummy.getPosition: real;
+function Tmedia_dummy.GetPosition: real;
begin
result := 0;
end;
@@ -135,6 +141,11 @@ begin
result := true;
end;
+function Tmedia_dummy.FinalizeRecord: boolean;
+begin
+ result := true;
+end;
+
procedure Tmedia_dummy.CaptureStart;
begin
end;
@@ -155,14 +166,27 @@ end;
// IAudioPlayback
function Tmedia_dummy.InitializePlayback: boolean;
begin
+ SetLength(DummyOutputDeviceList, 1);
+ DummyOutputDeviceList[0] := TAudioOutputDevice.Create();
+ DummyOutputDeviceList[0].Name := '[Dummy Device]';
result := true;
end;
-procedure Tmedia_dummy.SetVolume(Volume: integer);
+function Tmedia_dummy.FinalizePlayback: boolean;
+begin
+ result := true;
+end;
+
+function Tmedia_dummy.GetOutputDeviceList(): TAudioOutputDeviceList;
+begin
+ Result := DummyOutputDeviceList;
+end;
+
+procedure Tmedia_dummy.SetAppVolume(Volume: integer);
begin
end;
-procedure Tmedia_dummy.SetMusicVolume(Volume: integer);
+procedure Tmedia_dummy.SetVolume(Volume: integer);
begin
end;
@@ -170,6 +194,10 @@ procedure Tmedia_dummy.SetLoop(Enabled: boolean);
begin
end;
+procedure Tmedia_dummy.FadeIn(Time: real; TargetVolume: integer);
+begin
+end;
+
procedure Tmedia_dummy.Rewind;
begin
end;