home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #30 / NN_1992_30.iso / spool / comp / os / linux / 20523 < prev    next >
Encoding:
Text File  |  1992-12-15  |  1.4 KB  |  36 lines

  1. Newsgroups: comp.os.linux
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!usc!rpi!batcomputer!db.TC.Cornell.EDU!mdw
  3. From: mdw@db.TC.Cornell.EDU (Matt Welsh)
  4. Subject: Re: ANNOUNCE: Sound for Linux 0.99 (Sound driver v 0.4)
  5. Message-ID: <1992Dec15.170644.14703@tc.cornell.edu>
  6. Keywords: SOUND
  7. Sender: news@tc.cornell.edu
  8. Nntp-Posting-Host: db.tc.cornell.edu
  9. Organization: The Linux Inquisition, Propaganda Division
  10. References: <kenc.724299040@sol> <arumble.724377463@extro.ucc.su.OZ.AU> <9235020.16960@mulga.cs.mu.OZ.AU>
  11. Date: Tue, 15 Dec 1992 17:06:44 GMT
  12. Lines: 22
  13.  
  14. In article <9235020.16960@mulga.cs.mu.OZ.AU> fjh@munta.cs.mu.OZ.AU (Fergus James HENDERSON) writes:
  15. >arumble@extro.ucc.su.OZ.AU (Anthony Rumble) writes:
  16. >>kenc@sol.acs.unt.edu (Ken Corey - Operator) writes:
  17. >>>(Also, there's a sneaky little voice in the back of my head 
  18. >>>thinking..."Wow..rogue would be *cool* with a few sound effects...")
  19. >>
  20. >>Very easy to do.. Just make the source code fork() and 
  21. >>cat the sample to /dev/dsp..
  22. >
  23. >What about just
  24. >    system("cat sample > /dev/dsp &");
  25.  
  26. That's pretty hefty overhead for playing a sound effect within a
  27. program. If you want it to be faster, open /dev/dsp by hand and send
  28. the sample directly to it with a series of writes. This way you don't
  29. create a whole new process (or, in this case, two processes) for
  30. playing the sound effect.
  31.  
  32. mdw
  33. -- 
  34. Matt Welsh     mdw@tc.cornell.edu     Cornell Theory Center
  35.   "Go on, emote! I was raised on thought balloons!"
  36.