CSL 5.2

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | Private Member Functions
csl::SHARCLibrary Class Reference

SHARC library class. More...

`#include <SHARC.h>`

List of all members.

## Public Member Functions
| SHARCLibrary ()
| SHARCLibrary (char *name)
| ~SHARCLibrary ()
char ** | instrument_names ()
SHARCInstrument * | instrument_named (char *name)
SHARCSpectrum * | spectrum_named (char *inst, char *spect)
void | dump ()
void | dump_stats ()
void | dump_example ()

## Static Public Member Functions
static void | loadDefault ()
static SHARCLibrary * | library ()
static SHARCInstrument * | instrument (char *instr)
static SHARCInstrument * | instrument (unsigned instr)
static SHARCSpectrum * | spectrum (char *instr, char *note)
static SHARCSpectrum * | spectrum (char *instr, unsigned note)
static SHARCSpectrum * | spectrum (unsigned instr, unsigned note)

## Public Attributes
unsigned | _num_instruments
SHARCInstrument ** | _instruments

## Static Public Attributes
static SHARCLibrary * | sSHARCLib = 0
| The protected single instance of the HRTF Database.

## Private Member Functions
bool | read_from_directory (char *name)

## Detailed Description

SHARC library class.

Definition at line 130 of file SHARC.h.

## Constructor & Destructor Documentation

SHARCLibrary::SHARCLibrary | ( |  | ) |

Definition at line 224 of file SHARC.cpp.

Referenced by loadDefault().

SHARCLibrary::SHARCLibrary | ( | char * | name | ) |

Definition at line 232 of file SHARC.cpp.

References _instruments, _num_instruments, MAX_INSTRUMENTS, and read_from_directory().

SHARCLibrary::~SHARCLibrary | ( |  | ) |

Definition at line 226 of file SHARC.cpp.

References _instruments.

## Member Function Documentation

char ** SHARCLibrary::instrument_names | ( |  | ) |

Definition at line 274 of file SHARC.cpp.

References _instruments, csl::SHARCInstrument::_name, and _num_instruments.

Referenced by dump(), instrument(), and spectrum().

SHARCInstrument * SHARCLibrary::instrument_named | ( | char * | name | ) |

Definition at line 283 of file SHARC.cpp.

References _instruments, and _num_instruments.

Referenced by dump(), instrument(), spectrum(), spectrum_named(), and test_SHARC().

SHARCSpectrum * SHARCLibrary::spectrum_named | ( | char * | inst,
|  | char * | spect
| ) |  |

Definition at line 292 of file SHARC.cpp.

References instrument_named(), and csl::SHARCInstrument::spectrum_named().

void SHARCLibrary::dump | ( | void |  | ) |

Definition at line 381 of file SHARC.cpp.

References csl::SHARCInstrument::_name, _num_instruments, csl::SHARCInstrument::_num_spectra, instrument_named(), instrument_names(), and csl::SHARCInstrument::spectrum_names().

Referenced by test_SHARC().

void SHARCLibrary::dump_stats | ( |  | ) |

Definition at line 300 of file SHARC.cpp.

References _instruments, _num_instruments, csl::SHARCInstrument::count_partials(), csl::SHARCInstrument::count_spectra(), and csl::logMsg().

Referenced by loadDefault().

void SHARCLibrary::dump_example | ( |  | ) |

Definition at line 315 of file SHARC.cpp.

References _instruments, and csl::SHARCInstrument::dump_example().

void SHARCLibrary::loadDefault | ( |  | ) |
| static

Definition at line 327 of file SHARC.cpp.

References csl::CGestalt::dataFolder(), dump_stats(), SHARCLibrary(), and sSHARCLib.

Referenced by instrument(), library(), and spectrum().

SHARCLibrary * SHARCLibrary::library | ( |  | ) |
| static

Definition at line 338 of file SHARC.cpp.

References loadDefault(), and sSHARCLib.

SHARCInstrument * SHARCLibrary::instrument | ( | char * | instr | ) |
| static

Definition at line 346 of file SHARC.cpp.

References instrument_named(), loadDefault(), and sSHARCLib.

SHARCInstrument * SHARCLibrary::instrument | ( | unsigned | instr | ) |
| static

Definition at line 352 of file SHARC.cpp.

References instrument_named(), instrument_names(), loadDefault(), and sSHARCLib.

SHARCSpectrum * SHARCLibrary::spectrum | ( | char * | instr,
|  | char * | note
| ) |  |
| static

Definition at line 358 of file SHARC.cpp.

References instrument_named(), loadDefault(), csl::SHARCInstrument::spectrum_named(), and sSHARCLib.

Referenced by test_SHARC2().

SHARCSpectrum * SHARCLibrary::spectrum | ( | char * | instr,
|  | unsigned | note
| ) |  |
| static

Definition at line 365 of file SHARC.cpp.

References instrument_named(), loadDefault(), csl::SHARCInstrument::spectrum_with_key(), and sSHARCLib.

SHARCSpectrum * SHARCLibrary::spectrum | ( | unsigned | instr,
|  | unsigned | note
| ) |  |
| static

Definition at line 372 of file SHARC.cpp.

References instrument_named(), instrument_names(), loadDefault(), csl::SHARCInstrument::spectrum_with_key(), and sSHARCLib.

bool SHARCLibrary::read_from_directory | ( | char * | name | ) |
| private

Definition at line 240 of file SHARC.cpp.

References _instruments, and _num_instruments.

Referenced by SHARCLibrary().

## Member Data Documentation

unsigned csl::SHARCLibrary::_num_instruments

Definition at line 133 of file SHARC.h.

Referenced by dump(), dump_stats(), instrument_named(), instrument_names(), read_from_directory(), and SHARCLibrary().

SHARCInstrument** csl::SHARCLibrary::_instruments

Definition at line 134 of file SHARC.h.

Referenced by dump_example(), dump_stats(), instrument_named(), instrument_names(), read_from_directory(), SHARCLibrary(), and ~SHARCLibrary().

SHARCLibrary * SHARCLibrary::sSHARCLib = 0
| static

The protected single instance of the HRTF Database.

Global SHARC library.

Definition at line 149 of file SHARC.h.

Referenced by instrument(), library(), loadDefault(), and spectrum().

The documentation for this class was generated from the following files:

- CSL/Sources/SHARC.h
- CSL/Sources/SHARC.cpp