home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!cis.ohio-state.edu!pacific.mps.ohio-state.edu!linac!uwm.edu!wupost!cs.utexas.edu!tamsun.tamu.edu!tamsun.tamu.edu!news
- From: bpb9204@tamsun.tamu.edu (Brent Burton)
- Newsgroups: comp.sys.mac.programmer
- Subject: Sound Input questions (real time usage)
- Date: 14 Dec 1992 00:04:21 -0600
- Organization: Texas A&M Univ., Inc.
- Lines: 37
- Distribution: usa
- Message-ID: <1gh855INNj70@tamsun.tamu.edu>
- NNTP-Posting-Host: tamsun.tamu.edu
-
-
- In short, I'm writing a program to draw the shape of the
- sound coming in on the built-in device. However, I'm new to
- using the new Sound Manager and I don't know how to properly
- approach it.
-
- Think of my program as simply drawing a bar, which has a height
- that is proportional to the sound level coming in, like a meter.
-
- In IM-6, p 22-95, (talking about the sound parameter blocks), they
- say that, "if the bufferPtr field contains NIL, then the count,
- milliseconds, and bufferLength fields are ignored, and the recording
- continues indefinitely until you cal SPBStopRecording. If bufferPtr is
- NIL, the audio data is not saved anywhere; this feature is useful only
- if you want to do something in your interrupt routine and do not want
- to save the audio data."
-
- It says the data is not saved anywhere, but since I'm not interested in
- saving any portion of the input stream (I want the current value only),
- is there a location I can look to get the current digitized value?
- Do I have to do this through the interrupt routine?
-
- Since my program is effectively a level meter, I just need the current
- values. Another approach I was thinking about was using a small buffer,
- like << 100 bytes. Since the buffer is small, the value contained in
- it would be relatively close the the current value. Is this feasible?
-
- Anyway, if you have some ideas, please let me know.
-
- thanks,
- -Brent
-
- --
- +-------------------------+
- | Brent Burton N5VMG |
- | bpb9204@tamsun.tamu.edu |
- +-------------------------+
-