Main Page   Class Hierarchy   Compound List   File List   Compound Members  

AUFile Class Reference

#include <AUFile.h>

Collaboration diagram for AUFile:

Collaboration graph
List of all members.

Public Member Functions

 AUFile (void)
 ~AUFile (void)
 AUFile (AUFile &source)
bool open (const char *filename)
bool write (const char *filename)
bool record (const char *filename, unsigned int duration)
bool play (void) const
void normalize (void)
bool cutSampleRange (unsigned int length)
vector< double > & getData (void)
unsigned int getSize (void)
AU_info_datagetInformation (void)
bool setInformation (unsigned int size, unsigned char *data)
void setSize (unsigned int size)
const char * getFilename (void)

Private Attributes

char * filename
au_filehdr au_header
vector< double > au_data
AU_info_data i_data
bool if_open


class GUIMainImpl

Detailed Description

One AU format sound file. Represents the entire file without information loss and provides means of changing each part of the file.

Constructor & Destructor Documentation

AUFile::AUFile void   

Standard constructor.

AUFile::~AUFile void   

Standard destructor.

AUFile::AUFile AUFile &    source

Copy constructor.

Member Function Documentation

bool AUFile::cutSampleRange unsigned int    length

Shrink an AU file to the usable samplerange.

length Length of the samplerange
true if successful, false if failed

vector< double > & AUFile::getData void   

Getter for the audio data stream

const char * AUFile::getFilename void   

Getter for the filename.

filename of the au-file this object contains.

AU_info_data * AUFile::getInformation void   

Getter for the additional header information

unsigned int AUFile::getSize void   

Getter for the audio stream size

void AUFile::normalize void   

Normalize the audio stream data.

bool AUFile::open const char *    filename

Open an AU file and write its content to the class.

filename Filename of the AU file which should be opened.
True on success, false on failure.

bool AUFile::play void    const

Play the AU file.

True on success, false on failure.

bool AUFile::record const char *    filename,
unsigned int    duration

Record a new AU file

filename Filename the data is written to.
duration Length of recording in seconds. Must be in the range of 1 to 20.
True on success, false on failure.

bool AUFile::setInformation unsigned int    size,
unsigned char *    data

Setter for the additional header information.

size The byte-length of the new information.
data The byte array data.
false in case the information could not be set, true when the information have been successfully updated.

void AUFile::setSize unsigned int    size

Setter for audio data stream size.

size New size of the stream

bool AUFile::write const char *    filename

Write the class data to an AU file.

filename Filename the data is written to.
True in case of success, false when failed.

Member Data Documentation

vector<double> AUFile::au_data [private]

The audio data stream of the au-file.

au_filehdr AUFile::au_header [private]

The header of the au-file.

char* AUFile::filename [private]

Filename when loaded from file or NULL when new object.

AU_info_data AUFile::i_data [private]

Additional information which can be added at the end of the header

bool AUFile::if_open [private]

Flag, which is set to true once a file has been loaded. Otherwise, that is before any data has been loaded, it is set to false.

The documentation for this class was generated from the following files:
Generated on Mon Feb 24 19:37:44 2003 by doxygen1.3-rc3