Class Alsa.Player

java.lang.Object
net.avadeaux.klipspringer.alsa.Alsa
net.avadeaux.klipspringer.alsa.Alsa.Player
All Implemented Interfaces:
Closeable, AutoCloseable, Device.Player, PcmWriter
Enclosing class:
Alsa

public static class Alsa.Player extends Alsa implements Device.Player
Class for sending PCM data to an ALSA device.
  • Field Details

    • devices

      public static final Map<String,Device> devices
      Map from available output device names to the device objects.
  • Constructor Details

    • Player

      public Player(Device device, PcmFormat format, double bufferSecs, int recoveryAttempts) throws IOException
      Creates a player to output PCM to the given device in the given format, specifying the size of the external buffer, and the number of recovery attempts in case of buffer underrun. Available devices are obtained through devices. A reasonable number of recovery attempts is 2, unless you want to set it to 0 and get an exception as soon as an underrun happens.
      Throws:
      IOException
  • Method Details