home *** CD-ROM | disk | FTP | other *** search
/ Merciful 3 / Merciful_Release_3.bin / software / o / octamed / octamedv6.12.lha / programmers / examples / example1.c next >
C/C++ Source or Header  |  1995-03-26  |  648b  |  26 lines

  1. /* This is a very simple example how to play a module which is converted
  2.    to an object file with Objconv.
  3.  
  4. Linking info (assuming the object file is 'module.o'):
  5. slink from lib:c.o+example1.o+module.o+reloc.o+proplayer.o to example1
  6.     lib lib:sc.lib+lib:amiga.lib nd sc sd
  7.  
  8. */
  9.  
  10. #include <exec/types.h>
  11. #include <libraries/dos.h>
  12. #include <proto/exec.h>
  13. #include "proplayer.h"
  14.  
  15. /* Use symbol name 'song' when using Objconv, or change this. */
  16. extern struct MMD0 far song;
  17.  
  18. void main() /* this can be linked without c.o */
  19. {
  20.     RelocModule(&song);
  21.     InitPlayer();
  22.     PlayModule(&song);
  23.     Wait(SIGBREAKF_CTRL_C); /* press Ctrl-C to quit */
  24.     RemPlayer();
  25. }
  26.