home *** CD-ROM | disk | FTP | other *** search
/ Media Share 9 / MEDIASHARE_09.ISO / pascal / spx10.zip / SPX_INT.ZIP / SPX_SND.INT < prev    next >
Text File  |  1993-05-04  |  2KB  |  49 lines

  1. Unit SPX_SND;
  2.  
  3. { SPX Library Version 1.0  Copyright 1993 Scott D. Ramsay }
  4.  
  5. Interface
  6.  
  7. Uses Crt,Dos,LimEms;
  8.  
  9. type
  10.   Psound    = ^Tsound;
  11.   Tsound    = object
  12.                 sblk    : pointer;
  13.                 size,
  14.                 sport   : word;
  15.                 sb_play : boolean;
  16.                 constructor init(sndfile:string;prt:word;_sb:boolean);
  17.                 function loadsnd(sndfile:string;prt:word;_sb:boolean):boolean; virtual;
  18.                 function filesnd(var fil:file;bsize,prt:word;_sb:boolean):boolean; virtual;
  19.                 procedure cleansnd; virtual;
  20.                 procedure play(canstop:boolean); virtual;
  21.                 procedure stop; virtual;
  22.                 destructor done; virtual;
  23.               end;
  24.   PEmsSound = ^TEmsSound;
  25.   TEmsSound = object(Tsound)
  26.                 EMSseg,handle : word;
  27.                 EMSok         : boolean;
  28.                 constructor init(sndfile:string;prt:word;_sb:boolean);
  29.                 function loadsnd(sndfile:string;prt:word;_sb:boolean):boolean; virtual;
  30.                 procedure cleansnd; virtual;
  31.                 procedure play(canstop:boolean); virtual;
  32.                 destructor done; virtual;
  33.               end;
  34.  
  35. var
  36.   cs,                               { Can stop flag. (Interrupt sound) }
  37.   playing     : boolean;            { TRUE - if playing a sound        }
  38.   f_clk,                            { fast clock counters              }
  39.   s_clk : array[0..3] of word;      { 18.2per sec. slow clock counters }
  40.   rate,                             { Current fast clock rate          }
  41.   cntime : word;                    { RESERVED - do not modify         }
  42.  
  43. function SBFindBase:word;
  44. function SBReset(BaseAddr : word) : boolean;
  45. procedure globalstop;
  46. procedure setrate(cycles:word);
  47. procedure wait(seconds,which:integer);
  48.  
  49.