The cl-out123 Reference Manual

This is the cl-out123 Reference Manual, version 1.0.0, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Sep 15 04:19:11 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

The main system appears first, followed by any subsystem dependency.


2.1 cl-out123

Bindings to libout123, providing cross-platform audio output.

Maintainer

Yukari Hafner <>

Author

Yukari Hafner <>

Home Page

https://Shirakumo.github.io/cl-out123/

Source Control

(GIT https://github.com/Shirakumo/cl-out123.git)

Bug Tracker

https://github.com/Shirakumo/cl-out123/issues

License

zlib

Version

1.0.0

Dependencies
  • cffi (system).
  • trivial-features (system).
  • trivial-garbage (system).
  • documentation-utils (system).
  • bordeaux-threads (system).
Source

cl-out123.asd.

Child Components

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


3.1 Lisp


3.1.1 cl-out123/cl-out123.asd

Source

cl-out123.asd.

Parent Component

cl-out123 (system).

ASDF Systems

cl-out123.


3.1.2 cl-out123/package.lisp

Source

cl-out123.asd.

Parent Component

cl-out123 (system).

Packages

3.1.3 cl-out123/toolkit.lisp

Dependency

package.lisp (file).

Source

cl-out123.asd.

Parent Component

cl-out123 (system).

Public Interface

device-default-name (function).

Internals

3.1.4 cl-out123/conditions.lisp

Dependency

toolkit.lisp (file).

Source

cl-out123.asd.

Parent Component

cl-out123 (system).

Public Interface

3.1.5 cl-out123/low-level.lisp

Dependency

conditions.lisp (file).

Source

cl-out123.asd.

Parent Component

cl-out123 (system).

Public Interface
Internals

3.1.6 cl-out123/wrapper.lisp

Dependency

low-level.lisp (file).

Source

cl-out123.asd.

Parent Component

cl-out123 (system).

Public Interface
Internals

3.1.7 cl-out123/documentation.lisp

Dependency

wrapper.lisp (file).

Source

cl-out123.asd.

Parent Component

cl-out123 (system).


4 Packages

Packages are listed by definition order.


4.1 cl-out123

Source

package.lisp.

Nickname

org.shirakumo.fraf.out123

Use List
  • cffi.
  • common-lisp.
Public Interface
Internals

4.2 cl-out123-cffi

Source

package.lisp.

Nickname

org.shirakumo.fraf.out123.cffi

Use List
  • cffi.
  • common-lisp.
Public Interface
Internals

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


5.1 Public Interface


5.1.1 Special variables

Special Variable: *static*

Variable containing a pathname to the static directory.

Package

cl-out123-cffi.

Source

low-level.lisp.


5.1.2 Macros

Macro: with-playback ((output &key rate channels encoding) &body body)

Ensures a clean playback environment for the body.

First calls START with the given options, then evaluates the body forms in an unwind-protect that calls STOP on exit.

See START
See STOP

Package

cl-out123.

Source

wrapper.lisp.


5.1.3 Ordinary functions

Function: buffered (output)

Returns the number of bytes that currently reside in the internal buffer.

This number changes constantly as audio is played back.

This is setfable. Once set, a fork occurs to spawn a
"thread" to process the buffer in in the background.
See the <out123.h> file for more information.

See OUTPUT

Package

cl-out123.

Source

wrapper.lisp.

Function: (setf buffered) (output)
Package

cl-out123.

Source

wrapper.lisp.

Function: buffered (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: close (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: connect (output &key driver device)

Connects the output to the requested driver and device.

The output must not be connected already.

If the connection was successful, the output’s DRIVER and DEVICE are updated to reflect the ones that were actually chosen by the backend. This might differ from what you requested.

This function is safe to be called from multiple threads,
as it will mutually exclude them through a lock.

See OUTPUT
See DRIVER
See DEVICE
See CONNECTED

Package

cl-out123.

Source

wrapper.lisp.

Function: continue (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: del (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: device-default-name (&optional ident)

Attempts to return a somewhat sensible name to use for our application.

Package

cl-out123.

Source

toolkit.lisp.

Function: disconnect (output)

Disconnects the output from its driver and device.

If the output is already disconnected, this does nothing.

If there is still audio data to be played on the buffer, then this will block until it is finished. If you wish to abort immediately,

This function is safe to be called from multiple threads,
as it will mutually exclude them through a lock.
call DROP first.

See OUTPUT
See DROP
See CONNECTED

Package

cl-out123.

Source

wrapper.lisp.

Function: drain (output)

Blocks until all output in the buffer has been played back.

Implicitly resumes playback if it is paused first and then pauses it again once it finishes.

This function is safe to be called from multiple threads, as it will mutually exclude them through a lock.

See PLAYING
See OUTPUT
See NDRAIN

Package

cl-out123.

Source

wrapper.lisp.

Function: drain (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: driver-info (output)

Returns the current driver and device the output uses, if any.

This might differ from DRIVER and DEVICE if the handle was not yet CONNECTed, was connected by non-standard means, or something else went wrong.

See OUTPUT
See CONNECT

Package

cl-out123.

Source

wrapper.lisp.

Function: driver-info (handle driver device)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: drivers (output)

Returns a list of drivers with their name and description.

You can use this to determine the available drivers and pick a suitable backend based on that.

See OUTPUT

Package

cl-out123.

Source

wrapper.lisp.

Function: drivers (handle names descr)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: drop (output)

Drops all remaining output from the internal buffers.

This function is safe to be called from multiple threads, as it will mutually exclude them through a lock.

See OUTPUT

Package

cl-out123.

Source

wrapper.lisp.

Function: drop (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: enc-byname (name)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: enc-list (enclist)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: enc-longname (encoding)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: enc-name (encoding)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: encodings (output rate channels)

Returns a list of the possible encodings for the output rate and channel count you specified.

The output must be connected and will be stopped if it is playing.

See OTUPUT

Package

cl-out123.

Source

wrapper.lisp.

Function: encodings (handle rate channels)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: encsize (encoding)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: errcode (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: fmt-channels (pointer-to-fmt)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: (setf fmt-channels) (pointer-to-fmt)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: fmt-encoding (pointer-to-fmt)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: (setf fmt-encoding) (pointer-to-fmt)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: fmt-rate (pointer-to-fmt)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: (setf fmt-rate) (pointer-to-fmt)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: formats (output rates min-channels max-channels)

Returns a list of possible formats for the requested rates and channels.

RATES should be a list of integers.

The output must be connected and will be stopped if it is playing.

Each item in the list is a plist with :RATE, :CHANNELS, and :ENCODINGS as keys.

Package

cl-out123.

Source

wrapper.lisp.

Function: formats (handle rates ratecount minchannels maxchannels fmtlist)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: getformat (handle rate channels encoding framesize)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: getparam (handle code ret-value ret-fvalue ret-svalue)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: getparam-float (handle code value)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: getparam-int (handle code value)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: getparam-string (handle code value)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: make-output (driver &rest args &key &allow-other-keys)
Package

cl-out123.

Source

wrapper.lisp.

Function: ndrain (output bytes)

Blocks until either all or bytes number of bytes have been played back.

Implictly resumes playback if it is paused first and then
pauses it again if there are no remaining bytes to be played
back.

This function is safe to be called from multiple threads,
as it will mutually exclude them through a lock.

See PLAYING
See OUTPUT
See DRAIN

Package

cl-out123.

Source

wrapper.lisp.

Function: ndrain (handle bytes)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: new ()
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: open (handle driver device)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: param (handle code value fvalue svalue)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: param-float (handle code value)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: param-from (handle handle-from)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: param-int (handle code value)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: param-string (handle code value)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: pause (output)

Pauses playback.

This function is safe to be called from multiple threads, as it will mutually exclude them through a lock.

See OUTPUT
See PLAYING

Package

cl-out123.

Source

wrapper.lisp.

Function: pause (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: plain-strerror (errcode)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: play (output bytes &optional count)

Send the octet-vector or array-pointer to out123 to be played back on the output.

If you need low latency, then this is definitely not the
function for you. The buffer is converted into a foreign
byte array before being sent off.

Returns the number of bytes that were actually played back.

This function is safe to be called from multiple threads,
as it will mutually exclude them through a lock.

See PLAY-DIRECTLY
See OUTPUT

Package

cl-out123.

Source

wrapper.lisp.

Function: play (handle buffer bytes)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: play-directly (output buffer bytes)

Directly sends the given buffer to out123 to be played back on the output.

BUFFER must be a pointer to a foreign byte array of at least
BYTES size. Returns the number of bytes that were actually
played back.

This does not catch errors. If you need to check for errors,
see CL-OUT123-CFFI:ERRCODE.

This does not care for synchronisation or mutual exclusion.
If you call this simultaneously from multiple threads, things
/will/ crash and burn horribly.

See CL-OUT123-CFFI:ERRCODE
See HANDLE
See OUTPUT

Package

cl-out123.

Source

wrapper.lisp.

Function: playback-format (output)

Returns the current rate, channels, encoding, and framesize used by the output, if any.

This might differ from RATE, CHANNELS, ENCODING, and FRAMESIZE
if the handle has not yet been STARTed, was started by
non-standard means, or something else went wrong.

See OUTPUT
See START

Package

cl-out123.

Source

wrapper.lisp.

Function: resume (output)

Resumes playback.

This function is safe to be called from multiple threads, as it will mutually exclude them through a lock.

See OUTPUT
See PLAYING

Package

cl-out123.

Source

wrapper.lisp.

Function: set-buffer (handle buffer-bytes)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: start (output &key rate channels encoding)

Starts playback to the connected output.

The output must be connected and must not have been started before.

If the start was successful, the output’s RATE, CHANNELS, ENCODING, and FRAMESIZE are updated to reflect the values that were actually chosen by the backend. This might differ from what you requested.

This function is safe to be called from multiple threads,
as it will mutually exclude them through a lock.

See OUTPUT
See RATE
See CHANNELS
See ENCODING
See FRAMESIZE
See PLAYING

Package

cl-out123.

Source

wrapper.lisp.

Function: start (handle rate channels encoding)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: stop (output)

Stops playback.

If there is still audio data to be played on the buffer, then this will block until it is finished. If you wish to abort immediately, call DROP first.

This function is safe to be called from multiple threads,
as it will mutually exclude them through a lock.

See OUTPUT
See PLAYING

Package

cl-out123.

Source

wrapper.lisp.

Function: stop (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.

Function: strerror (handle)
Package

cl-out123-cffi.

Source

low-level.lisp.


5.1.4 Generic functions

Generic Reader: bytes (condition)
Package

cl-out123.

Methods
Reader Method: bytes ((condition buffer-set-failed))
Source

conditions.lisp.

Target Slot

bytes.

Reader Method: bytes ((condition playback-failed))
Source

conditions.lisp.

Target Slot

bytes.

Generic Reader: channels (condition)

Returns the number of audio channels the backend uses to process the buffer data.

Can be set as an initarg on the output.

See OUTPUT
See START

Package

cl-out123.

Methods
Reader Method: channels ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

channels.

Reader Method: channels ((condition start-failed))
Source

conditions.lisp.

Target Slot

channels.

Generic Reader: connected (object)

Returns T if the output is connected to a device.

Package

cl-out123.

Methods
Reader Method: connected ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

connected.

Generic Reader: device (condition)

Returns the string naming the device used to play back sound or NIL if unknown.

Can be set as an initarg on the output.

See OUTPUT
See CONNECT

Package

cl-out123.

Methods
Reader Method: device ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

device.

Reader Method: device ((condition connection-failed))
Source

conditions.lisp.

Target Slot

device.

Generic Reader: device-buffer (object)

Returns the number of seconds that the device buffer should hold.

Can be set as an initarg on the output.

Allowed values are:
T for the default that the backend will choose for itself. REAL for the approximate amount of seconds of buffering. Should not be more than 0.5.

See OUTPUT

Package

cl-out123.

Methods
Reader Method: device-buffer ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

device-buffer.

Generic Reader: driver (condition)

Returns the string naming the driver used to play back sound or NIL if unknown.

Can be set as an initarg on the output.

In order to get a listing of all possible drivers, see DRIVERS.

See OUTPUT
See DRIVERS
See CONNECT

Package

cl-out123.

Methods
Reader Method: driver ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

driver.

Reader Method: driver ((condition connection-failed))
Source

conditions.lisp.

Target Slot

driver.

Generic Reader: encoding (condition)

Returns the encoding the backend uses to decode the buffer data.

Can be set as an initarg on the output.

See ENCODINGS for a list of possible encodings.

See OUTPUT
See START
See ENCODINGS

Package

cl-out123.

Methods
Reader Method: encoding ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

encoding.

Reader Method: encoding ((condition start-failed))
Source

conditions.lisp.

Target Slot

encoding.

Generic Reader: error-string (condition)

Returns the error string from the out123 library for the error we encountered.

See ERROR-STRING-ERROR

Package

cl-out123.

Methods
Reader Method: error-string ((condition error-string-error))
Source

conditions.lisp.

Target Slot

error.

Generic Reader: gain (object)

Returns an integer representing the output device gain. This is driver-specific.

Can be set as an initarg on the output.

See OUTPUT

Package

cl-out123.

Methods
Reader Method: gain ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

gain.

Generic Reader: handle (object)

Returns the pointer to the actual handle object that the output object encapsulates.

You should not need this unless you are working with the internals of the library.

See OUTPUT

Package

cl-out123.

Methods
Reader Method: handle ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

handle.

Generic Reader: name (object)

Returns the name used to identify the output in the audio playback device, if permitted.

Can be set as an initarg on the otuput.

The default value is calculated by DEVICE-DEFAULT-NAME

See OUTPUT
See DEVICE-DEFAULT-NAME

Package

cl-out123.

Methods
Reader Method: name ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

name.

Generic Reader: output (condition)

Returns the output object associated with the condition.

See OUTPUT-ERROR

Package

cl-out123.

Methods
Reader Method: output ((condition output-error))
Source

conditions.lisp.

Target Slot

output.

Generic Reader: output-to (object)

Returns a list of special flags that tell the backend (if possible) where to output to.

Can be set as an initarg on the output.

The flags in the list can be one of :HEADPHONES :INTERNAL-SPEAKER :LINE-OUT

See OUTPUT

Package

cl-out123.

Methods
Reader Method: output-to ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

output-to.

Generic Reader: playing (object)

Returns T if the output is currently playing audio.

Package

cl-out123.

Methods
Reader Method: playing ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

playing.

Generic Reader: preload (object)

Returns the percentage of data that is preloaded into the device buffer.

Can be set as an initarg on the output.

Allowed values are:
T for the default that the backend will choose for itself.
NIL for no preloading, aka 0.0.
REAL for the approximate fraction that should be preloaded [0,1].

See OUTPUT

Package

cl-out123.

Methods
Reader Method: preload ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

preload.

Generic Reader: rate (condition)

Returns the sampling rate the backend uses to process the buffer data.

Can be set as an initarg on the output.

See OUTPUT
See START

Package

cl-out123.

Methods
Reader Method: rate ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

rate.

Reader Method: rate ((condition start-failed))
Source

conditions.lisp.

Target Slot

rate.


5.1.5 Standalone methods

Method: print-object ((output output) stream)
Source

wrapper.lisp.

Method: reinitialize-instance :around ((output output) &key)
Source

wrapper.lisp.

Method: shared-initialize :after ((output output) slots &key)
Source

wrapper.lisp.


5.1.6 Conditions

Condition: already-connected

Condition signalled if an attempt is made to connect again while the output is still connected.

See OUTPUT-ERROR

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

output-error.

Condition: buffer-set-failed

Condition signalled if the setting of the background buffer fails.

See ERROR-STRING-ERROR
See BYTES

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

error-string-error.

Direct methods

bytes.

Direct slots
Slot: bytes
Initargs

:bytes

Readers

bytes.

Writers

This slot is read-only.

Condition: connection-failed

Condition signalled if the connection of an output to its device fails.

See ERROR-STRING-ERROR
See DRIVER
See DEVICE

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

error-string-error.

Direct methods
Direct slots
Slot: driver
Initargs

:driver

Readers

driver.

Writers

This slot is read-only.

Slot: device
Initargs

:device

Readers

device.

Writers

This slot is read-only.

Condition: creation-failure

Condition signalled in the case the allocation of the output handler fails.

See OUTPUT-ERROR

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

output-error.

Condition: error-string-error

Error condition superclass for errors that have an error-string from the out123 library.

See ERROR-STRING
See OUTPUT-ERROR

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

output-error.

Direct subclasses
Direct methods

error-string.

Direct slots
Slot: error
Package

common-lisp.

Initargs

:error

Readers

error-string.

Writers

This slot is read-only.

Condition: failed-driver-info
Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

output-error.

Condition: failed-driver-listing

Condition signalled if the listing of available drivers fails for some reason.

See OUTPUT-ERROR

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

output-error.

Condition: failed-format-listing

Condition signalled if the listing of available formats fails for some reason.

See OUTPUT-ERROR

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

output-error.

Condition: failed-playback-format
Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

output-error.

Condition: not-connected

Condition signalled if an operation is attempted that requires the output to be connected, but it isn’t.

See OUTPUT-ERROR

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

output-error.

Condition: output-error

Error condition superclass for all errors related to this library.

See OUTPUT

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

error.

Direct subclasses
Direct methods

output.

Direct slots
Slot: output
Initargs

:output

Readers

output.

Writers

This slot is read-only.

Condition: playback-failed

Condition signalled if the playback of a buffer fails.

See ERROR-STRING-ERROR
See BYTES

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

error-string-error.

Direct methods

bytes.

Direct slots
Slot: bytes
Initargs

:bytes

Readers

bytes.

Writers

This slot is read-only.

Condition: start-failed

Condition signalled if starting the device fails.

See ERROR-STRING-ERROR
See RATE
See CHANNELS
See ENCODING

Package

cl-out123.

Source

conditions.lisp.

Direct superclasses

error-string-error.

Direct methods
Direct slots
Slot: rate
Initargs

:rate

Readers

rate.

Writers

This slot is read-only.

Slot: channels
Initargs

:channels

Readers

channels.

Writers

This slot is read-only.

Slot: encoding
Initargs

:encoding

Readers

encoding.

Writers

This slot is read-only.


5.1.7 Classes

Class: fmt
Package

cl-out123-cffi.

Source

low-level.lisp.

Direct superclasses
  • foreign-struct-type.
  • translatable-foreign-type.
Class: handle
Package

cl-out123-cffi.

Source

low-level.lisp.

Direct superclasses
  • foreign-struct-type.
  • translatable-foreign-type.
Class: output

Class representing an output to a sound playback device.

This holds all the necessary state and information in order to connect and play back audio data to a device.

Some options can only be changed by closing and opening a new connection to the backend. In order to do this, you can use REINITIALIZE-INSTANCE. It will attempt to preserve state across reinitialisation, but pending sound data will be disposed off immediately as to not block.

See HANDLE
See PLAYING
See CONNECTED
See DRIVER
See DEVICE
See RATE
See CHANNELS
See ENCODING
See OUTPUT-TO
See PRELOAD
See GAIN
See DEVICE-BUFFER
See NAME
See OUTPUT-LOCK

Package

cl-out123.

Source

wrapper.lisp.

Direct methods
Direct Default Initargs
InitargValue
:drivernil
:devicenil
:rate44100
:channels2
:encodingint16
:output-tonil
:preloadt
:gainnil
:device-buffert
:name(device-default-name)
Direct slots
Slot: handle
Readers

handle.

Writers

This slot is read-only.

Slot: playing
Readers

playing.

Writers

set-playing.

Slot: connected
Readers

connected.

Writers

set-connected.

Slot: driver
Initargs

:driver

Readers

driver.

Writers

This slot is read-only.

Slot: device
Initargs

:device

Readers

device.

Writers

This slot is read-only.

Slot: rate
Initargs

:rate

Readers

rate.

Writers

This slot is read-only.

Slot: channels
Initargs

:channels

Readers

channels.

Writers

This slot is read-only.

Slot: encoding
Initargs

:encoding

Readers

encoding.

Writers

This slot is read-only.

Slot: framesize
Readers

framesize.

Writers

This slot is read-only.

Slot: output-to
Initargs

:output-to

Readers

output-to.

Writers

This slot is read-only.

Slot: preload
Initargs

:preload

Readers

preload.

Writers

This slot is read-only.

Slot: gain
Initargs

:gain

Readers

gain.

Writers

This slot is read-only.

Slot: device-buffer
Initargs

:device-buffer

Readers

device-buffer.

Writers

This slot is read-only.

Slot: name
Initargs

:name

Readers

name.

Writers

This slot is read-only.

Slot: cthread
Initform

(cons (bordeaux-threads:current-thread) nil)

Readers

cthread.

Writers

This slot is read-only.

Slot: playback-lock
Initform

(bordeaux-threads:make-lock "output lock")

Readers

playback-lock.

Writers

This slot is read-only.


5.2 Internals


5.2.1 Special variables

Special Variable: *here*

Variable containing the path to this very file, hopefully.

Package

cl-out123-cffi.

Source

low-level.lisp.


5.2.2 Macros

Macro: with-error ((err datum &rest datum-args) &body form)

Checks the result of FORM against an error and if found, signals a condition according to the spec.

Package

cl-out123.

Source

toolkit.lisp.

Macro: with-foreign-values (bindings &body body)

Same as CFFI:WITH-FOREIGN-OBJECTS, but resolves the bindings at the end and returns them as values.

Package

cl-out123.

Source

toolkit.lisp.

Macro: with-generic-error (form)

Signals a simple-error if the result of FORM is an error.

See WITH-ERROR

Package

cl-out123.

Source

toolkit.lisp.


5.2.3 Ordinary functions

Function: check-connected (output)

Signals an error if the output is not connected.

See OUTPUT
See CONNECTED
See NOT-CONNECTED

Package

cl-out123.

Source

wrapper.lisp.

Function: decode-encodings (encs)

Decodes the ORed together encodings into a list of keywords.

Package

cl-out123.

Source

wrapper.lisp.

Function: dispose-handle (handle thread &key delete)

Properly disposes of the handle as quickly as possible.

Performs three steps if the handle is not a null-pointer:
Output is drained by DRAIN, the handle is CLOSEd, and finally DELeted.

See CL-OUT123-CFFI:DRAIN
See CL-OUT123-CFFI:CLOSE
See CL-OUT123-CFFI:DEL

Package

cl-out123.

Source

wrapper.lisp.

Function: samplesize (enc)
Package

cl-out123-cffi.

Source

low-level.lisp.


5.2.4 Generic functions

Generic Reader: cthread (object)
Package

cl-out123.

Methods
Reader Method: cthread ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

cthread.

Generic Reader: framesize (object)

Returns the framesize the backend uses to decode the buffer data.

This is determined automatically by the backend once the output has STARTed.

See OUTPUT
See START

Package

cl-out123.

Methods
Reader Method: framesize ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

framesize.

Generic Reader: playback-lock (object)
Package

cl-out123.

Methods
Reader Method: playback-lock ((output output))

automatically generated reader method

Source

wrapper.lisp.

Target Slot

playback-lock.

Generic Writer: set-connected (new-value object)
Package

cl-out123.

Methods
Writer Method: set-connected ((new-value output) output)

automatically generated writer method

Source

wrapper.lisp.

Target Slot

connected.

Generic Writer: set-playing (new-value object)
Package

cl-out123.

Methods
Writer Method: set-playing ((new-value output) output)

automatically generated writer method

Source

wrapper.lisp.

Target Slot

playing.


Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   (  
B   C   D   E   F   G   H   M   N   O   P   R   S   W  
Index Entry  Section

(
(setf buffered): Public ordinary functions
(setf fmt-channels): Public ordinary functions
(setf fmt-encoding): Public ordinary functions
(setf fmt-rate): Public ordinary functions

B
buffered: Public ordinary functions
buffered: Public ordinary functions
bytes: Public generic functions
bytes: Public generic functions
bytes: Public generic functions

C
channels: Public generic functions
channels: Public generic functions
channels: Public generic functions
check-connected: Private ordinary functions
close: Public ordinary functions
connect: Public ordinary functions
connected: Public generic functions
connected: Public generic functions
continue: Public ordinary functions
cthread: Private generic functions
cthread: Private generic functions

D
decode-encodings: Private ordinary functions
del: Public ordinary functions
device: Public generic functions
device: Public generic functions
device: Public generic functions
device-buffer: Public generic functions
device-buffer: Public generic functions
device-default-name: Public ordinary functions
disconnect: Public ordinary functions
dispose-handle: Private ordinary functions
drain: Public ordinary functions
drain: Public ordinary functions
driver: Public generic functions
driver: Public generic functions
driver: Public generic functions
driver-info: Public ordinary functions
driver-info: Public ordinary functions
drivers: Public ordinary functions
drivers: Public ordinary functions
drop: Public ordinary functions
drop: Public ordinary functions

E
enc-byname: Public ordinary functions
enc-list: Public ordinary functions
enc-longname: Public ordinary functions
enc-name: Public ordinary functions
encoding: Public generic functions
encoding: Public generic functions
encoding: Public generic functions
encodings: Public ordinary functions
encodings: Public ordinary functions
encsize: Public ordinary functions
errcode: Public ordinary functions
error-string: Public generic functions
error-string: Public generic functions

F
fmt-channels: Public ordinary functions
fmt-encoding: Public ordinary functions
fmt-rate: Public ordinary functions
formats: Public ordinary functions
formats: Public ordinary functions
framesize: Private generic functions
framesize: Private generic functions
Function, (setf buffered): Public ordinary functions
Function, (setf fmt-channels): Public ordinary functions
Function, (setf fmt-encoding): Public ordinary functions
Function, (setf fmt-rate): Public ordinary functions
Function, buffered: Public ordinary functions
Function, buffered: Public ordinary functions
Function, check-connected: Private ordinary functions
Function, close: Public ordinary functions
Function, connect: Public ordinary functions
Function, continue: Public ordinary functions
Function, decode-encodings: Private ordinary functions
Function, del: Public ordinary functions
Function, device-default-name: Public ordinary functions
Function, disconnect: Public ordinary functions
Function, dispose-handle: Private ordinary functions
Function, drain: Public ordinary functions
Function, drain: Public ordinary functions
Function, driver-info: Public ordinary functions
Function, driver-info: Public ordinary functions
Function, drivers: Public ordinary functions
Function, drivers: Public ordinary functions
Function, drop: Public ordinary functions
Function, drop: Public ordinary functions
Function, enc-byname: Public ordinary functions
Function, enc-list: Public ordinary functions
Function, enc-longname: Public ordinary functions
Function, enc-name: Public ordinary functions
Function, encodings: Public ordinary functions
Function, encodings: Public ordinary functions
Function, encsize: Public ordinary functions
Function, errcode: Public ordinary functions
Function, fmt-channels: Public ordinary functions
Function, fmt-encoding: Public ordinary functions
Function, fmt-rate: Public ordinary functions
Function, formats: Public ordinary functions
Function, formats: Public ordinary functions
Function, getformat: Public ordinary functions
Function, getparam: Public ordinary functions
Function, getparam-float: Public ordinary functions
Function, getparam-int: Public ordinary functions
Function, getparam-string: Public ordinary functions
Function, make-output: Public ordinary functions
Function, ndrain: Public ordinary functions
Function, ndrain: Public ordinary functions
Function, new: Public ordinary functions
Function, open: Public ordinary functions
Function, param: Public ordinary functions
Function, param-float: Public ordinary functions
Function, param-from: Public ordinary functions
Function, param-int: Public ordinary functions
Function, param-string: Public ordinary functions
Function, pause: Public ordinary functions
Function, pause: Public ordinary functions
Function, plain-strerror: Public ordinary functions
Function, play: Public ordinary functions
Function, play: Public ordinary functions
Function, play-directly: Public ordinary functions
Function, playback-format: Public ordinary functions
Function, resume: Public ordinary functions
Function, samplesize: Private ordinary functions
Function, set-buffer: Public ordinary functions
Function, start: Public ordinary functions
Function, start: Public ordinary functions
Function, stop: Public ordinary functions
Function, stop: Public ordinary functions
Function, strerror: Public ordinary functions

G
gain: Public generic functions
gain: Public generic functions
Generic Function, bytes: Public generic functions
Generic Function, channels: Public generic functions
Generic Function, connected: Public generic functions
Generic Function, cthread: Private generic functions
Generic Function, device: Public generic functions
Generic Function, device-buffer: Public generic functions
Generic Function, driver: Public generic functions
Generic Function, encoding: Public generic functions
Generic Function, error-string: Public generic functions
Generic Function, framesize: Private generic functions
Generic Function, gain: Public generic functions
Generic Function, handle: Public generic functions
Generic Function, name: Public generic functions
Generic Function, output: Public generic functions
Generic Function, output-to: Public generic functions
Generic Function, playback-lock: Private generic functions
Generic Function, playing: Public generic functions
Generic Function, preload: Public generic functions
Generic Function, rate: Public generic functions
Generic Function, set-connected: Private generic functions
Generic Function, set-playing: Private generic functions
getformat: Public ordinary functions
getparam: Public ordinary functions
getparam-float: Public ordinary functions
getparam-int: Public ordinary functions
getparam-string: Public ordinary functions

H
handle: Public generic functions
handle: Public generic functions

M
Macro, with-error: Private macros
Macro, with-foreign-values: Private macros
Macro, with-generic-error: Private macros
Macro, with-playback: Public macros
make-output: Public ordinary functions
Method, bytes: Public generic functions
Method, bytes: Public generic functions
Method, channels: Public generic functions
Method, channels: Public generic functions
Method, connected: Public generic functions
Method, cthread: Private generic functions
Method, device: Public generic functions
Method, device: Public generic functions
Method, device-buffer: Public generic functions
Method, driver: Public generic functions
Method, driver: Public generic functions
Method, encoding: Public generic functions
Method, encoding: Public generic functions
Method, error-string: Public generic functions
Method, framesize: Private generic functions
Method, gain: Public generic functions
Method, handle: Public generic functions
Method, name: Public generic functions
Method, output: Public generic functions
Method, output-to: Public generic functions
Method, playback-lock: Private generic functions
Method, playing: Public generic functions
Method, preload: Public generic functions
Method, print-object: Public standalone methods
Method, rate: Public generic functions
Method, rate: Public generic functions
Method, reinitialize-instance: Public standalone methods
Method, set-connected: Private generic functions
Method, set-playing: Private generic functions
Method, shared-initialize: Public standalone methods

N
name: Public generic functions
name: Public generic functions
ndrain: Public ordinary functions
ndrain: Public ordinary functions
new: Public ordinary functions

O
open: Public ordinary functions
output: Public generic functions
output: Public generic functions
output-to: Public generic functions
output-to: Public generic functions

P
param: Public ordinary functions
param-float: Public ordinary functions
param-from: Public ordinary functions
param-int: Public ordinary functions
param-string: Public ordinary functions
pause: Public ordinary functions
pause: Public ordinary functions
plain-strerror: Public ordinary functions
play: Public ordinary functions
play: Public ordinary functions
play-directly: Public ordinary functions
playback-format: Public ordinary functions
playback-lock: Private generic functions
playback-lock: Private generic functions
playing: Public generic functions
playing: Public generic functions
preload: Public generic functions
preload: Public generic functions
print-object: Public standalone methods

R
rate: Public generic functions
rate: Public generic functions
rate: Public generic functions
reinitialize-instance: Public standalone methods
resume: Public ordinary functions

S
samplesize: Private ordinary functions
set-buffer: Public ordinary functions
set-connected: Private generic functions
set-connected: Private generic functions
set-playing: Private generic functions
set-playing: Private generic functions
shared-initialize: Public standalone methods
start: Public ordinary functions
start: Public ordinary functions
stop: Public ordinary functions
stop: Public ordinary functions
strerror: Public ordinary functions

W
with-error: Private macros
with-foreign-values: Private macros
with-generic-error: Private macros
with-playback: Public macros


A.3 Variables

Jump to:   *  
B   C   D   E   F   G   H   N   O   P   R   S  
Index Entry  Section

*
*here*: Private special variables
*static*: Public special variables

B
bytes: Public conditions
bytes: Public conditions

C
channels: Public conditions
channels: Public classes
connected: Public classes
cthread: Public classes

D
device: Public conditions
device: Public classes
device-buffer: Public classes
driver: Public conditions
driver: Public classes

E
encoding: Public conditions
encoding: Public classes
error: Public conditions

F
framesize: Public classes

G
gain: Public classes

H
handle: Public classes

N
name: Public classes

O
output: Public conditions
output-to: Public classes

P
playback-lock: Public classes
playing: Public classes
preload: Public classes

R
rate: Public conditions
rate: Public classes

S
Slot, bytes: Public conditions
Slot, bytes: Public conditions
Slot, channels: Public conditions
Slot, channels: Public classes
Slot, connected: Public classes
Slot, cthread: Public classes
Slot, device: Public conditions
Slot, device: Public classes
Slot, device-buffer: Public classes
Slot, driver: Public conditions
Slot, driver: Public classes
Slot, encoding: Public conditions
Slot, encoding: Public classes
Slot, error: Public conditions
Slot, framesize: Public classes
Slot, gain: Public classes
Slot, handle: Public classes
Slot, name: Public classes
Slot, output: Public conditions
Slot, output-to: Public classes
Slot, playback-lock: Public classes
Slot, playing: Public classes
Slot, preload: Public classes
Slot, rate: Public conditions
Slot, rate: Public classes
Special Variable, *here*: Private special variables
Special Variable, *static*: Public special variables


A.4 Data types

Jump to:   A   B   C   D   E   F   H   L   N   O   P   S   T   W  
Index Entry  Section

A
already-connected: Public conditions

B
buffer-set-failed: Public conditions

C
cl-out123: The cl-out123 system
cl-out123: The cl-out123 package
cl-out123-cffi: The cl-out123-cffi package
cl-out123.asd: The cl-out123/cl-out123․asd file
Class, fmt: Public classes
Class, handle: Public classes
Class, output: Public classes
Condition, already-connected: Public conditions
Condition, buffer-set-failed: Public conditions
Condition, connection-failed: Public conditions
Condition, creation-failure: Public conditions
Condition, error-string-error: Public conditions
Condition, failed-driver-info: Public conditions
Condition, failed-driver-listing: Public conditions
Condition, failed-format-listing: Public conditions
Condition, failed-playback-format: Public conditions
Condition, not-connected: Public conditions
Condition, output-error: Public conditions
Condition, playback-failed: Public conditions
Condition, start-failed: Public conditions
conditions.lisp: The cl-out123/conditions․lisp file
connection-failed: Public conditions
creation-failure: Public conditions

D
documentation.lisp: The cl-out123/documentation․lisp file

E
error-string-error: Public conditions

F
failed-driver-info: Public conditions
failed-driver-listing: Public conditions
failed-format-listing: Public conditions
failed-playback-format: Public conditions
File, cl-out123.asd: The cl-out123/cl-out123․asd file
File, conditions.lisp: The cl-out123/conditions․lisp file
File, documentation.lisp: The cl-out123/documentation․lisp file
File, low-level.lisp: The cl-out123/low-level․lisp file
File, package.lisp: The cl-out123/package․lisp file
File, toolkit.lisp: The cl-out123/toolkit․lisp file
File, wrapper.lisp: The cl-out123/wrapper․lisp file
fmt: Public classes

H
handle: Public classes

L
low-level.lisp: The cl-out123/low-level․lisp file

N
not-connected: Public conditions

O
output: Public classes
output-error: Public conditions

P
Package, cl-out123: The cl-out123 package
Package, cl-out123-cffi: The cl-out123-cffi package
package.lisp: The cl-out123/package․lisp file
playback-failed: Public conditions

S
start-failed: Public conditions
System, cl-out123: The cl-out123 system

T
toolkit.lisp: The cl-out123/toolkit․lisp file

W
wrapper.lisp: The cl-out123/wrapper․lisp file