Hitchhiker's Guide to Openbsd


- Can I use OpenBSD to record audio samples?


Download 1.27 Mb.
Pdf ko'rish
bet190/258
Sana04.04.2023
Hajmi1.27 Mb.
#1328980
1   ...   186   187   188   189   190   191   192   193   ...   258
Bog'liq
obsd-faq49

13.4 - Can I use OpenBSD to record audio samples?
Yes. Most devices support recording. 
aucat(1)
 comes with OpenBSD and can be used for recording. 
aucat -o file.wav
The above command will start the recording of a file in WAV format. Press [CTRL]-C to finish the 
recording. The file will contain signed 16-bit stereo samples, sampled at 44.1 kHz. Other sample 
formats, sample rates and number of channels can be recorded. See the manual for more details. 
Use aucat to play the file back: 
aucat -i file.wav
If recording seemed to work, but playback of the recording was silent or not what was expected, the 
mixer probably needs some configuration. Make sure that you select the right device to record from and 
that the source is unmuted. You can set the necessary parameters using 
mixerctl(1)
. For example: 
inputs.mic.mute=off
inputs.mic.preamp=on
inputs.mic.source=mic0
record.source=mic
record.volume=255,255
record.volume.mute=off
record.mic=255
record.mic.mute=off
These are settings for recording from a microphone. Pre-amplifying has been enabled, otherwise the 
recorded sound can be pretty silent on some systems. However, pre-amplifying can also be quite loud on 
other systems. 
13.5 - How do I setup an audio server?
http://www.openbsd.org/faq/faq13.html (8 of 25)9/4/2011 10:02:21 AM


13 - Multimedia
Do I need an audio server?
The 
aucat(1)
 utility can be used as an audio server, which acts as a layer between the audio(4) driver and 
audio applications. It aims to: 

Overcome incompatibilities between hardware and applications. For instance the application may 
not support the encodings or sample rates of the hardware; if so, the server can do the necessary 
conversions on the fly. 

Allow multiple applications to use the hardware concurrently. For instance, to use a background 
music player while running an application playing sounds, or to simultaneously use the front 
speakers for music and the headphone socket for telephony is another example. 
If applications you use are compatible with your hardware and you don't plan to run multiple 
applications concurently, then you don't need an audio server. 

Download 1.27 Mb.

Do'stlaringiz bilan baham:
1   ...   186   187   188   189   190   191   192   193   ...   258




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling