gtkIOStream  1.7.0
GTK+ << C++ IOStream operators for GTK+. Now with ORBing, numerical computation, audio client and more ...
ALSA::PCM Class Reference

#include <PCM.H>

Inheritance diagram for ALSA::PCM:
[legend]

Public Member Functions

 PCM ()
 
virtual ~PCM ()
 
virtual snd_pcm_t * getPCM ()
 
snd_pcm_t ** getPCMP ()
 
int open (const char *device, snd_pcm_stream_t streamType, const int block)
 
int close ()
 
int drop ()
 
int drain ()
 
int reset ()
 
void enableLog ()
 
int logEnabled ()
 
int dumpStatus ()
 
int dumpPCM ()
 
int dumpSetup ()
 
int dumpHWSetup ()
 
int dumpSWSetup ()
 
int start ()
 
snd_pcm_state_t getState ()
 
const char * getStateName ()
 
bool prepared ()
 
bool opened ()
 
bool isSetup ()
 
bool running ()
 
bool hasXrun ()
 
bool draining ()
 
bool paused ()
 
bool suspended ()
 
bool disconnected ()
 

Protected Attributes

snd_output_t * log
 The log stream if enabled. More...
 
snd_pcm_t * handle
 PCM handle. More...
 

Detailed Description

Class to handle an ALSA pcm object

Definition at line 26 of file PCM.H.

Constructor & Destructor Documentation

◆ PCM()

ALSA::PCM::PCM ( )
inline

Definition at line 31 of file PCM.H.

◆ ~PCM()

virtual ALSA::PCM::~PCM ( )
inlinevirtual

Definition at line 36 of file PCM.H.

Here is the call graph for this function:

Member Function Documentation

◆ close()

int ALSA::PCM::close ( )
inline

Close the stream

Returns
>= 0 on success

Definition at line 70 of file PCM.H.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ disconnected()

bool ALSA::PCM::disconnected ( )
inline

Returns true if in the disconnected state

Definition at line 238 of file PCM.H.

Here is the call graph for this function:

◆ drain()

int ALSA::PCM::drain ( )
inline

Stops the PCM allowing it to finish draining frames.

Returns
<0 on error

Definition at line 96 of file PCM.H.

Here is the call graph for this function:

◆ draining()

bool ALSA::PCM::draining ( )
inline

Returns true if in the draining state

Definition at line 217 of file PCM.H.

Here is the call graph for this function:

◆ drop()

int ALSA::PCM::drop ( )
inline

Stops the PCM dropping frames.

Returns
<0 on error

Definition at line 83 of file PCM.H.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ dumpHWSetup()

int ALSA::PCM::dumpHWSetup ( )
inline

Definition at line 150 of file PCM.H.

Here is the call graph for this function:

◆ dumpPCM()

int ALSA::PCM::dumpPCM ( )
inline

Definition at line 134 of file PCM.H.

Here is the call graph for this function:

◆ dumpSetup()

int ALSA::PCM::dumpSetup ( )
inline

Definition at line 142 of file PCM.H.

Here is the call graph for this function:

◆ dumpStatus()

int ALSA::PCM::dumpStatus ( )
inline

Definition at line 121 of file PCM.H.

Here is the call graph for this function:

◆ dumpSWSetup()

int ALSA::PCM::dumpSWSetup ( )
inline

Definition at line 158 of file PCM.H.

Here is the call graph for this function:

◆ enableLog()

void ALSA::PCM::enableLog ( )
inline

Definition at line 109 of file PCM.H.

◆ getPCM()

virtual snd_pcm_t* ALSA::PCM::getPCM ( )
inlinevirtual

Reimplemented in ALSA::ALSAExternalPlugin, and ALSA::ALSAPlugin.

Definition at line 42 of file PCM.H.

Here is the caller graph for this function:

◆ getPCMP()

snd_pcm_t** ALSA::PCM::getPCMP ( )
inline

Get a pointer to the handle pointer of the stream

Returns
A pointer to the handle pointer

Definition at line 49 of file PCM.H.

Here is the caller graph for this function:

◆ getState()

snd_pcm_state_t ALSA::PCM::getState ( )
inline

Definition at line 171 of file PCM.H.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getStateName()

const char* ALSA::PCM::getStateName ( )
inline

Definition at line 176 of file PCM.H.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ hasXrun()

bool ALSA::PCM::hasXrun ( )
inline

Returns true if in the xrun state

Definition at line 210 of file PCM.H.

Here is the call graph for this function:

◆ isSetup()

bool ALSA::PCM::isSetup ( )
inline

Returns true if in the setup state

Definition at line 196 of file PCM.H.

Here is the call graph for this function:

◆ logEnabled()

int ALSA::PCM::logEnabled ( )
inline

Definition at line 113 of file PCM.H.

Here is the caller graph for this function:

◆ open()

int ALSA::PCM::open ( const char *  device,
snd_pcm_stream_t  streamType,
const int  block 
)
inline

Open the stream

Parameters
deviceThe name of the device
streamTypeSND_PCM_STREAM_PLAYBACK or SND_PCM_STREAM_CAPTURE
blockWhether to open non blocking
Returns
>= 0 on success

Definition at line 59 of file PCM.H.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ opened()

bool ALSA::PCM::opened ( )
inline

Returns true if in the open state

Definition at line 189 of file PCM.H.

Here is the call graph for this function:

◆ paused()

bool ALSA::PCM::paused ( )
inline

Returns true if in the PAUSED state

Definition at line 224 of file PCM.H.

Here is the call graph for this function:

◆ prepared()

bool ALSA::PCM::prepared ( )
inline

Returns true if in the prepared state

Definition at line 182 of file PCM.H.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ reset()

int ALSA::PCM::reset ( )
inline

Resets the PCM.

Returns
<0 on error

Definition at line 104 of file PCM.H.

Here is the call graph for this function:

◆ running()

bool ALSA::PCM::running ( )
inline

Returns true if in the running state

Definition at line 203 of file PCM.H.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ start()

int ALSA::PCM::start ( )
inline

Definition at line 166 of file PCM.H.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ suspended()

bool ALSA::PCM::suspended ( )
inline

Returns true if in the SUSPENDED state

Definition at line 231 of file PCM.H.

Here is the call graph for this function:

Member Data Documentation

◆ handle

snd_pcm_t* ALSA::PCM::handle
protected

PCM handle.

Definition at line 29 of file PCM.H.

◆ log

snd_output_t* ALSA::PCM::log
protected

The log stream if enabled.

Definition at line 28 of file PCM.H.


The documentation for this class was generated from the following file:
gtkIOStream: ALSA::PCM Class Reference
GTK+ IOStream  Beta