home *** CD-ROM | disk | FTP | other *** search
/ Collection of Hack-Phreak Scene Programs / cleanhpvac.zip / cleanhpvac / ADVHSC18.ZIP / EQUAL.PAS < prev    next >
Pascal/Delphi Source File  |  1994-11-04  |  1KB  |  58 lines

  1. Program ADVHSC_Equalizer_Demo;
  2.  
  3. { Little Example To Show The Use Of The Equalizer in the Antares HSC Player }
  4. { Coded By Access/ADV - 06/94 }
  5. { Modification By aCceSs/aNTaReS - 11/94 }
  6.  
  7. Uses Crt,ADVHSC;
  8.  
  9. Var i,j:Byte;
  10.  
  11. PROCEDURE VerticalRetrace;Assembler;  { Simply Wait The VGA Video Retrace }
  12.      ASM
  13.         mov dx,$3da
  14. @1:     in al,dx
  15.         test al,8
  16.         jz @1
  17. @2:     in al,dx
  18.         test al,8
  19.         jnz @2
  20. END;
  21.  
  22. Begin
  23. ClrScr;
  24.  
  25. if LOADSONG('MUSIC.HSC') then   { Loading the Song Into Memory }
  26. Begin
  27. PLAYSONG; { Play The Song }
  28.  
  29. Writeln('ADV HSC Player Version '+Version+' - Example 1');
  30. Writeln;
  31. Writeln('Press A Key...');
  32.  
  33. Repeat
  34. GetPlayerState;
  35. VerticalRetrace;
  36.  
  37. GOTOXY(1,8); Write('Pattern : ',PlayerState.Pattern,'  Position : ',PlayerState.Position,' ');
  38.  
  39. For i:=1 to 9 do
  40. Begin
  41. GotoXY(1,i+10);
  42.  
  43. if PlayerState.Equalizer[i]<>255 then
  44.    Begin
  45.    For j:=1 to Playerstate.Equalizer[i] do Write('■');
  46.    For j:=Playerstate.Equalizer[i] to 15 do Write(' ');
  47.    End;
  48.  
  49. End;
  50.  
  51. Until KeyPressed;
  52.  
  53. FADESONG; { Fade Out The Volume }
  54. Delay(2000); { Wait For 2 Seconds }
  55. STOPSONG; { Stop The Player }
  56. CLEARMEM; { Free Memory }
  57. End;
  58. End.