public class AudioInput extends AudioSource
You can obtain an AudioInput from Minim by using one of the getLineIn methods:
// get the default STEREO input AudioInput getLineIn() // specifiy either Minim.MONO or Minim.STEREO for type AudioInput getLineIn(int type) // bufferSize is the size of the left, right, // and mix buffers of the input you get back AudioInput getLineIn(int type, int bufferSize) // sampleRate is a request for an input of a certain sample rate AudioInput getLineIn(int type, int bufferSize, float sampleRate) // bitDepth is a request for an input with a certain bit depth AudioInput getLineIn(int type, int bufferSize, float sampleRate, int bitDepth)In the event that an input doesn't exist with the requested parameters, Minim will spit out an error and return null. In general, you will want to use the first two methods listed above.
left, mix, right
BALANCE, GAIN, MUTE, PAN, SAMPLE_RATE, VOLUME
Constructor and Description |
---|
AudioInput(ddf.minim.spi.AudioStream stream,
ddf.minim.spi.AudioOut out) |
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes this source, making it unavailable.
|
void |
disableMonitoring()
When monitoring is disabled, you will not hear
the audio that is coming through the input,
but you will still be able to access the samples
in the left, right, and mix buffers.
|
void |
enableMonitoring()
When monitoring is enabled, you will be able to hear
the audio that is coming through the input.
|
boolean |
isMonitoring()
Returns whether or not this AudioInput is monitoring.
|
addEffect, addListener, bufferSize, clearEffects, disableEffect, disableEffect, effectCount, effects, enableEffect, enableEffect, getEffect, getFormat, hasEffect, isEffected, isEnabled, noEffects, removeEffect, removeEffect, removeListener, sampleRate, type
balance, gain, getBalance, getControl, getControls, getGain, getPan, getVolume, hasControl, isMuted, mute, pan, printControls, setBalance, setGain, setPan, setVolume, shiftBalance, shiftGain, shiftPan, shiftVolume, unmute, volume
public AudioInput(ddf.minim.spi.AudioStream stream, ddf.minim.spi.AudioOut out)
stream
- the AudioStream
that provides the samplesout
- the AudioOut
that will read from stream
public void close()
AudioSource
close
in class AudioSource
public boolean isMonitoring()
public void enableMonitoring()
public void disableMonitoring()