com.tuneology.avm.recorder
Class ALSARecorder

java.lang.Object
  |
  +--com.tuneology.avm.recorder.Recorder
        |
        +--com.tuneology.avm.recorder.ALSARecorder
All Implemented Interfaces:
AudioRecorder, MediaRecorder

public class ALSARecorder
extends Recorder
implements AudioRecorder

A native API to ALSA recorder.

Version:
$Id: ALSARecorder.java,v 1.3 2003/07/10 19:52:12 xnarf Exp $
Author:
Fran Taylor

Fields inherited from class com.tuneology.avm.recorder.Recorder
dev
 
Constructor Summary
ALSARecorder(java.lang.String d)
           
 
Method Summary
 void close()
           
 int getChannels()
           
 int getDataFormat()
           
static java.lang.String getDescription()
           
static java.lang.String[] getDevices()
           
 java.lang.String getName()
           
 int getRate()
           
 int getStreamFormat()
           
static java.lang.String getVersionString()
          Returns the version string for the underlying library, or blank if none.
static boolean isEnabled()
          Returns true if ALSA libraries are present.
 void record(MediaData md, long offset, int msecs)
           
 void setChannels(int c)
           
 void setDataFormat(int fmt)
           
 void setRate(int r)
           
 void setStreamFormat(int fmt)
           
 void stop()
           
static void touch()
           
 
Methods inherited from class com.tuneology.avm.recorder.Recorder
getAudioDevices, getAudioRecorders, getDescription, getDeviceDescription, getVersions, getVideoRecorders, newAudioRecorder, newRecorder
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ALSARecorder

public ALSARecorder(java.lang.String d)
             throws java.io.IOException
Throws:
java.io.IOException -  
Method Detail

isEnabled

public static boolean isEnabled()
Returns true if ALSA libraries are present.

getDevices

public static java.lang.String[] getDevices()

setDataFormat

public void setDataFormat(int fmt)
                   throws java.io.IOException
Specified by:
setDataFormat in interface AudioRecorder
Throws:
java.io.IOException -  

getDataFormat

public int getDataFormat()
Specified by:
getDataFormat in interface AudioRecorder

setStreamFormat

public void setStreamFormat(int fmt)
                     throws java.io.IOException
Specified by:
setStreamFormat in interface AudioRecorder
Throws:
java.io.IOException -  

getStreamFormat

public int getStreamFormat()
Specified by:
getStreamFormat in interface AudioRecorder

setRate

public void setRate(int r)
             throws java.io.IOException
Specified by:
setRate in interface AudioRecorder
Throws:
java.io.IOException -  

getRate

public int getRate()
Specified by:
getRate in interface AudioRecorder

setChannels

public void setChannels(int c)
                 throws java.io.IOException
Specified by:
setChannels in interface AudioRecorder
Throws:
java.io.IOException -  

getChannels

public int getChannels()
Specified by:
getChannels in interface AudioRecorder

record

public void record(MediaData md,
                   long offset,
                   int msecs)
            throws java.io.IOException
Specified by:
record in interface MediaRecorder
Throws:
java.io.IOException -  

getVersionString

public static java.lang.String getVersionString()
Returns the version string for the underlying library, or blank if none.
Returns:
the version string for the underlying library, or blank if none.

stop

public void stop()
          throws java.io.IOException
Specified by:
stop in interface MediaRecorder
Throws:
java.io.IOException -  

close

public void close()
           throws java.io.IOException
Specified by:
close in interface MediaRecorder
Throws:
java.io.IOException -  

getName

public java.lang.String getName()
Specified by:
getName in interface MediaRecorder

touch

public static void touch()

getDescription

public static java.lang.String getDescription()