loopback — alsaaudio documentation 0.10.1 documentation

# `loopback`

## Module Contents

### Classes

`PollDescriptor` | File Descriptor, event mask and a name for logging
`Loopback` | Loopback state and event handling
`VolumeForwarder` | Volume control event handling
`Reactor` | A wrapper around select.poll

### Functions

`poll_desc`(mask) |

### Attributes

`poll_names` |
`state_names` |
`parser` |

loopback.poll_names

loopback.state_names

loopback.poll_desc(mask)

class loopback.PollDescriptor(name, fd, mask)

  Bases: `object`

  File Descriptor, event mask and a name for logging

  as_tuple()
  classmethod from_alsa_object(name, alsaobject, mask=None)

class loopback.Loopback(capture, playback_args, volume_handler, run_after_stop=None, run_before_start=None)

  Bases: `object`

  Loopback state and event handling

  static compute_energy(data)
  static run_command(cmd)
  register(reactor)
  start()
  timeout_handler()
  pop()
  handle_capture_event(eventmask, name)

    called when data is available for reading

  __call__(fd, eventmask, name)

class loopback.VolumeForwarder(capture_control, playback_control)

  Bases: `object`

  Volume control event handling

  start()
  stop()
  __call__(fd, eventmask, name)

class loopback.Reactor

  Bases: `object`

  A wrapper around select.poll

  register(polldescriptor, callable)
  unregister(polldescriptor)
  register_timeout_handler(callable)
  unregister_timeout_handler(callable)
  run()

loopback.parser