I have made one unit that wraps openal and ogg loading in nice small packet. Everything works fine, except for minor detail... When i play Ogg during game and have something heavy running background it causes lag that makes ogg play start looping a half second block to infinite. It normalizes when i restart playing the piece...
I have no idea why it starts looping. Here's my play function if it helps:
Code:
procedure alPlay(OggStream: TOggStream);
begin
  if OggStream<>nil then
    with OggStream do begin
      Update;
      if not playing then Playback;
    end;
end;
Btw, do any of you have mp3 loading functions, or is it just old and bad format?