LinuxAudioInputDevice Class Reference

#include <LinuxAudioInputDevice.hh>

List of all members.


Detailed Description

It derives AudioInputDevice of LiveMedia.

Definition at line 38 of file LinuxAudioInputDevice.hh.

Public Member Functions

 LinuxAudioInputDevice (UsageEnvironment &env, int input_port_number, unsigned char bits_per_sample, unsigned char num_channels, unsigned int sampling_frequency, unsigned int granularity_in_ms)
 Constructor.
virtual ~LinuxAudioInputDevice ()

Private Member Functions

virtual Boolean setInputPort (int port_index)
 Redefined virtual functions.
virtual void doGetNextFrame ()
 redefined virtual functions.
virtual void doStopGettingFrames ()
 redefined virtual functions.
virtual double getAverageLevel () const
 redefined virtual functions.

Private Attributes

const char * _audio_grab_format
 Usually used for indicate "audio_device".
bool _initialized
 Specify whether the class is initialized or not.
AVFormatContext * _format_context
 pointer to ffmpeg 's struct AVFormatContext
AVFormatParameters * _ap
 pointer to ffmpeg 's struct AVFormatParameters.
AVInputFormat * _input_fmt
 pointer to ffmpeg 's struct AVInputFormat.
AVCodec * _pcm_codec
 Codec context.

Friends

class AudioInputDevice
 LiveMedia AudioInputDevice class.


Constructor & Destructor Documentation

LinuxAudioInputDevice::LinuxAudioInputDevice ( UsageEnvironment &  env,
int  input_port_number,
unsigned char  bits_per_sample,
unsigned char  num_channels,
unsigned int  sampling_frequency,
unsigned int  granularity_in_ms 
)

Parameters:
env UsageEnvironment see LiveMedia doc. here http://www.live555.com/liveMedia/public/doxygen/html
input_port_number Port number in which the microphone is mapped to by the system.
bits_per_sample Number of bits for sample.
num_channels Number of channels the grabbing process will have: 2 = stereo 1 = mono.
sampling_frequency Frequence of sampling.
granularity_in_ms Time between a grab and the other.

LinuxAudioInputDevice::~LinuxAudioInputDevice (  )  [virtual]

Definition at line 126 of file LinuxAudioInputDevice.cpp.


Member Function Documentation

void LinuxAudioInputDevice::doGetNextFrame (  )  [private, virtual]

Definition at line 131 of file LinuxAudioInputDevice.cpp.

References _format_context, _initialized, and DEBUG_PRINT.

void LinuxAudioInputDevice::doStopGettingFrames (  )  [private, virtual]

Definition at line 155 of file LinuxAudioInputDevice.cpp.

References NULL.

double LinuxAudioInputDevice::getAverageLevel (  )  const [private, virtual]

Definition at line 168 of file LinuxAudioInputDevice.cpp.

Boolean LinuxAudioInputDevice::setInputPort ( int  port_index  )  [private, virtual]

Parameters:
port_index Input port.
Returns:
true if setting went fine, false if something went wrong.
See also:
LinuxAudioInputDevice constructor.

Definition at line 163 of file LinuxAudioInputDevice.cpp.


Friends And Related Function Documentation

friend class AudioInputDevice [friend]

See http://www.live555.com/liveMedia/public/doxygen/html/

Definition at line 42 of file LinuxAudioInputDevice.hh.


Member Data Documentation

AVFormatParameters* LinuxAudioInputDevice::_ap [private]

Used to specify parameters to the input stream opening.

Definition at line 100 of file LinuxAudioInputDevice.hh.

const char* LinuxAudioInputDevice::_audio_grab_format [private]

See ffmpeg doc or samples on audio grabbing.

Definition at line 88 of file LinuxAudioInputDevice.hh.

AVFormatContext* LinuxAudioInputDevice::_format_context [private]

Definition at line 94 of file LinuxAudioInputDevice.hh.

Referenced by doGetNextFrame().

bool LinuxAudioInputDevice::_initialized [private]

Definition at line 91 of file LinuxAudioInputDevice.hh.

Referenced by doGetNextFrame().

AVInputFormat* LinuxAudioInputDevice::_input_fmt [private]

Used to manage Input streams.

Definition at line 103 of file LinuxAudioInputDevice.hh.

AVCodec* LinuxAudioInputDevice::_pcm_codec [private]

Refers to ffmpeg. Will grab PCM data packets.

Definition at line 106 of file LinuxAudioInputDevice.hh.


The documentation for this class was generated from the following files:
Generated on Tue Dec 26 10:36:46 2006 for Omnimeeting by  doxygen 1.4.7