mod.h 1.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /* $Id$
  2. * MegaZeux
  3. *
  4. * Copyright (C) 1996 Greg Janson
  5. * Copyright (C) 1998 Matthew D. Williams - dbwilli@scsn.net
  6. *
  7. * This program is free software; you can redistribute it and/or
  8. * modify it under the terms of the GNU General Public License as
  9. * published by the Free Software Foundation; either version 2 of
  10. * the License, or (at your option) any later version.
  11. *
  12. * This program is distributed in the hope that it will be useful,
  13. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  15. * General Public License for more details.
  16. *
  17. * You should have received a copy of the GNU General Public License
  18. * along with this program; if not, write to the Free Software
  19. * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  20. */
  21. /* Declarations for MOD.CPP */
  22. #ifndef __MOD_H
  23. #define __MOD_H
  24. void load_mod(char far *filename);
  25. void end_mod(void);
  26. void play_sample(int freq,char far *file);
  27. void end_sample(void);
  28. void jump_mod(int order);
  29. void volume_mod(int vol);
  30. void mod_exit(void);
  31. //Set to 0 for editor, 1 for debugging games, 2 for regular games
  32. extern unsigned char error_mode;
  33. void mod_init(void);
  34. void spot_sample(int freq,int sample);
  35. //This function will remove samples from the cache one at a time,
  36. //starting with least-played and ending with currently-playing.
  37. //Call it removes ONE sample unless CLEAR_ALL is set. Returns 1
  38. //if nothing was found to deallocate (IE no further fixes possible)
  39. char free_sam_cache(char clear_all);
  40. //Call if music_gvol or sound_gvol changes
  41. void fix_global_volumes(void);
  42. #endif