Autor Beitrag
mimi
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 3458

Ubuntu, Win XP
Lazarus
BeitragVerfasst: Fr 17.10.03 19:28 
Hallo,
warum funktioniert folgene procedure nicht ?:

ausblenden volle Höhe Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
procedure TSound.LoadMusikFile(Index:Integer; RM:Boolean);
var
  Datei:String;
  Music:TPlayListe;
begin
  if RM = True then
    Music:=Random_Music[index]
  else
    Music:=PlayListe[index];


  if PlayListe[Index].GetLoaddet = True then begin
    PlayMusikFile(index,False);
    Exit;
  end;

  Datei:=Music.FileName;

  Music.stream:=NIL;
  TSI;
  Music.Module:=FMUSIC_LoadSong(PChar(Datei) );

  if Music.Module = Nil then
    Music.Stream := FSOUND_Stream_OpenFile(PChar(Datei), FSOUND_NORMAL, 0)
  else
    FMUSIC_SetLooping(Music.Module,False);

  if (Music.Module = nil) and ( Music.Stream = NIL ) then begin
    Showmessage('ErrorTEST! Opening file - ' + FMOD_ErrorString(FSOUND_GetError()));
    FSOUND_Close();
    Exit;
  end;

  Music.GetLoaddet:=True;

  if RM = True then
    Random_Music[Index]:=Music
  else
    PlayListe[Index]:=Music;
end;


vom qullcode her ist alles richtg.
fmod wird in der Create funktion von der TSound klasse aufgerufen !!!

_________________
MFG
Michael Springwald, "kann kein englisch...."
mimi Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 3458

Ubuntu, Win XP
Lazarus
BeitragVerfasst: So 26.10.03 18:22 
das problem ist mit FMOd_SoundInit ich wollte es gerne NUR einmal ausführen und nicht 1000 mal.aber das geht irgendwie nicht so wie ich es haben möchte :( :(

_________________
MFG
Michael Springwald, "kann kein englisch...."