AgsDevout

AgsDevout — Output to soundcard

Functions

Properties

AgsApplicationContext * application-context Read / Write
gpointer application-mutex Read / Write
gpointer attack Read
gdouble bpm Read / Write
gpointer buffer Read
guint buffer-size Read / Write
gdouble delay-factor Read / Write
gchar * device Read / Write
guint dsp-channels Read / Write
guint format Read / Write
guint pcm-channels Read / Write
guint samplerate Read / Write

Types and Values

Object Hierarchy

    GObject
    ╰── AgsDevout

Implemented Interfaces

AgsDevout implements AgsConnectable, AgsSoundcard and AgsConcurrentTree.

Includes

#include <ags/audio/ags_devout.h>

Description

AgsDevout represents a soundcard and supports output.

Functions

ags_devout_error_quark ()

GQuark
ags_devout_error_quark ();

ags_devout_switch_buffer_flag ()

void
ags_devout_switch_buffer_flag (AgsDevout *devout);

The buffer flag indicates the currently played buffer.

Parameters

devout

an AgsDevout

 

Since: 1.0.0


ags_devout_adjust_delay_and_attack ()

void
ags_devout_adjust_delay_and_attack (AgsDevout *devout);

Calculate delay and attack and reset it.

Parameters

devout

the AgsDevout

 

Since: 1.0.0


ags_devout_realloc_buffer ()

void
ags_devout_realloc_buffer (AgsDevout *devout);

Reallocate the internal audio buffer.

Parameters

devout

the AgsDevout

 

Since: 1.0.0


ags_devout_new ()

AgsDevout *
ags_devout_new (GObject *application_context);

Creates an AgsDevout, refering to application_context .

Parameters

application_context

the AgsApplicationContext

 

Returns

a new AgsDevout

Since: 1.0.0


AGS_DEVOUT()

#define AGS_DEVOUT(obj)                (G_TYPE_CHECK_INSTANCE_CAST((obj), AGS_TYPE_DEVOUT, AgsDevout))

AGS_DEVOUT_CLASS()

#define AGS_DEVOUT_CLASS(class)        (G_TYPE_CHECK_CLASS_CAST(class, AGS_TYPE_DEVOUT, AgsDevout))

AGS_DEVOUT_GET_CLASS()

#define AGS_DEVOUT_GET_CLASS(obj)      (G_TYPE_INSTANCE_GET_CLASS(obj, AGS_TYPE_DEVOUT, AgsDevoutClass))

AGS_IS_DEVOUT()

#define AGS_IS_DEVOUT(obj)             (G_TYPE_CHECK_INSTANCE_TYPE ((obj), AGS_TYPE_DEVOUT))

ags_devout_get_type ()

GType
ags_devout_get_type ();

Types and Values

AGS_DEVOUT_DEFAULT_ALSA_DEVICE

#define AGS_DEVOUT_DEFAULT_ALSA_DEVICE "hw:0,0\0"

AGS_DEVOUT_DEFAULT_OSS_DEVICE

#define AGS_DEVOUT_DEFAULT_OSS_DEVICE "/dev/dsp\0"

AGS_DEVOUT_DEFAULT_RING_BUFFER_SIZE

#define AGS_DEVOUT_DEFAULT_RING_BUFFER_SIZE (8)

enum AgsDevoutFlags

Enum values to control the behavior or indicate internal state of AgsDevout by enable/disable as flags.

Members

AGS_DEVOUT_BUFFER0

ring-buffer 0

 

AGS_DEVOUT_BUFFER1

ring-buffer 1

 

AGS_DEVOUT_BUFFER2

ring-buffer 2

 

AGS_DEVOUT_BUFFER3

ring-buffer 3

 

AGS_DEVOUT_ATTACK_FIRST

use first attack, instead of second one

 

AGS_DEVOUT_PLAY

use first attack, instead of second one

 

AGS_DEVOUT_OSS

use OSS4 backend

 

AGS_DEVOUT_ALSA

use ALSA backend

 

AGS_DEVOUT_SHUTDOWN

stop playback

 

AGS_DEVOUT_START_PLAY

playback starting

 

AGS_DEVOUT_NONBLOCKING

do non-blocking calls

 

AGS_DEVOUT_INITIALIZED

the soundcard was initialized

 

AGS_DEVOUT_ERROR

#define AGS_DEVOUT_ERROR (ags_devout_error_quark())

enum AgsDevoutError

Members

AGS_DEVOUT_ERROR_LOCKED_SOUNDCARD

   

AGS_DEVOUT_ERROR_BROKEN_CONFIGURATION

   

AGS_DEVOUT_ERROR_ACCESS_TYPE_NOT_AVAILABLE

   

AGS_DEVOUT_ERROR_SAMPLE_FORMAT_NOT_AVAILABLE

   

AGS_DEVOUT_ERROR_CHANNELS_NOT_AVAILABLE

   

AGS_DEVOUT_ERROR_SAMPLERATE_NOT_AVAILABLE

   

AGS_DEVOUT_ERROR_BUFFER_SIZE_NOT_AVAILABLE

   

AGS_DEVOUT_ERROR_HW_PARAMETERS_NOT_AVAILABLE

   

AGS_TYPE_DEVOUT

#define AGS_TYPE_DEVOUT                (ags_devout_get_type())

struct AgsDevout

struct AgsDevout;

struct AgsDevoutClass

struct AgsDevoutClass {
  GObjectClass object;
};

Property Details

The “application-context” property

  “application-context”      AgsApplicationContext *

The assigned AgsApplicationContext

Flags: Read / Write

Since: 1.0.0.7


The “application-mutex” property

  “application-mutex”        gpointer

The assigned application mutex

Flags: Read / Write

Since: 1.0.0


The “attack” property

  “attack”                   gpointer

Attack of the buffer

Flags: Read

Since: 1.0.0


The “bpm” property

  “bpm”                      gdouble

Beats per minute

Flags: Read / Write

Allowed values: [1,240]

Default value: 120

Since: 1.0.0


The “buffer” property

  “buffer”                   gpointer

The buffer

Flags: Read

Since: 1.0.0


The “buffer-size” property

  “buffer-size”              guint

The buffer size

Flags: Read / Write

Allowed values: [1,44100]

Default value: 1024

Since: 1.0.0


The “delay-factor” property

  “delay-factor”             gdouble

tact

Flags: Read / Write

Allowed values: [0,16]

Default value: 1

Since: 1.0.0


The “device” property

  “device”                   gchar *

The alsa soundcard indentifier

Flags: Read / Write

Default value: "hw:0"

Since: 1.0.0


The “dsp-channels” property

  “dsp-channels”             guint

The dsp channel count

Flags: Read / Write

Allowed values: [1,64]

Default value: 2

Since: 1.0.0


The “format” property

  “format”                   guint

The precision of the buffer

Flags: Read / Write

Allowed values: [1,64]

Default value: 16

Since: 1.0.0


The “pcm-channels” property

  “pcm-channels”             guint

The pcm channel count

Flags: Read / Write

Allowed values: [1,64]

Default value: 2

Since: 1.0.0


The “samplerate” property

  “samplerate”               guint

The samplerate

Flags: Read / Write

Allowed values: [8000,96000]

Default value: 44100

Since: 1.0.0