home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / lang / cplus / 18584 < prev    next >
Encoding:
Text File  |  1992-12-30  |  1.7 KB  |  38 lines

  1. Newsgroups: comp.lang.c++
  2. Path: sparky!uunet!wupost!emory!gatech!destroyer!ais.org!empath
  3. From: empath@ais.org (Tim Triemstra)
  4. Subject: 32bit Zortech Pointers
  5. Message-ID: <C03usF.8CA@ais.org>
  6. Organization: UMCC
  7. Date: Thu, 31 Dec 1992 03:53:01 GMT
  8. Lines: 28
  9.  
  10. I've worked long and hard converting some SoundBlaster code from MicroSoft C
  11. to Zortech C++ support (added BC++ along the way as well.)  However, the
  12. one catch I have come accross seems to be related to the pointers.
  13.  
  14. I already converted all the INT calls to reflect 2bytes in the 32bit mode to
  15. ensure compatibility (I can optimize later.)  So, since it works under the
  16. Zortech 16bit modes it SHOULD work under the 32bit model.  It does compile
  17. (using the quick-and-dirty command line) and produce a "working" .exe file.
  18. However, where it is supposed to play a VOC file of ??? bytes, it comes out
  19. playing ??? bytes - but the wrong bytes!  I know the interrupts are working
  20. as you can time the routines when they work (and play something like "HELLOW
  21. STRANGER" outta the SB Speaker) and the garbage and they are equal because
  22. the length of the sample is controled in a standard 2byte short.  However,
  23. I get garbage for that period of time. I also know it is working simply
  24. because the entire thing is handed via interrupts and wouldn't work at all
  25. if it wasn't kicking in.
  26.  
  27. My assumtion is that since the data for the VOC is stored in a pointer of
  28. unsigned char's in both versions, that the pointer is somehow not protected
  29. enough for the interrupt handler.  So, any ideas on how to get this working?
  30. I thought I may need to use one of the DOS extenders pointer making
  31. functions, but none of them really seem aplicable.
  32.  
  33. I am using Zortech C++ 3.04 with FlashTek's X32-VM (very similar to the
  34. standard DOSX.)
  35.  
  36. Tim.
  37.  
  38.