Mail Archives: djgpp/1997/02/14/22:09:53
Jorge Fernandez Suarez (cascoscuro AT redestb DOT es) wrote:
: Hello:
: I'm trying to make work some watcom code I've download
: from Soundblaster site to play .wav files in a SB16 card, but
: it's watcom code, and I've found some problems when I've tried
: to translate...
Firstly, get and read the FAQ.
When you've done that, you have two choices:
1) Get a DJGPP-specific library
2) Hack the code you already have
As for (1), there's sb05_dj2, which has routines to play wav files and mod
files, I think, and there's Allegro, which does a whole lot more.
Re (2), briefly, you need to:
* Sort out the ISR so that it works in protected mode (RTFAQ)
* Allocate the buffer in the low memory area (RTFAQ)
* Put the data into this buffer
* Set up and initiate the DMA transfer, passing it the address of this buffer
These aren't serious modifications, and the FAQ has a lot of information
on porting Watcom/Borland/etc programs to DJGPP.
--
George Foot <gfoot AT mc31 DOT merton DOT ox DOT ac DOT uk>
Merton College, Oxford.
- Raw text -