Struct alto::Alto
[−]
[src]
pub struct Alto { /* fields omitted */ }
This struct is the entry point of the API. Instantiating it will load an OpenAL implementation. From here, available devices can be queried and opened.
Methods
impl Alto
[src]
fn load_default() -> AltoResult<Alto>
Load the default OpenAL implementation for the platform. This will prefer OpenAL-Soft if it is present, otherwise it will search for a generic implementation.
fn load_default_with_soft_hints(hints: SoftHints) -> AltoResult<Alto>
Load the default OpenAL implementation for the platform.
This will prefer OpenAL-Soft if it is present, and will pass along the specified hints in a temporary
configuration file that will be read by OpenAL-Soft.
NOTE: This involves setting the value of the ALSOFT_CONF
environment variable. If it is already set,
then the provided hints will be discarded.
fn load<P: AsRef<Path>>(path: P) -> AltoResult<Alto>
Loads a specific OpenAL implementation from a specififed path.
fn load_with_soft_hints<P: AsRef<Path>>(
path: P,
hints: SoftHints
) -> AltoResult<Alto>
path: P,
hints: SoftHints
) -> AltoResult<Alto>
Loads a specific OpenAL implementation from a specififed path.
If that implementation is OpenAL-Soft, the specified hints will be passed along in a temporary
configuration file.
NOTE: This involves setting the value of the ALSOFT_CONF
environment variable. If it is already set,
then the provided hints will be discarded.
fn raw_api(&self) -> &AlApi
Raw entry points of the OpenAL API.
fn default_output(&self) -> AltoResult<CString>
alcGetString(ALC_DEFAULT_DEVICE_SPECIFIER)
fn default_capture(&self) -> AltoResult<CString>
alcGetString(ALC_CAPTURE_DEFAULT_DEVICE_SPECIFIER)
fn enumerate_outputs(&self) -> AltoResult<Vec<CString>>
alcGetString(ALC_DEVICE_SPECIFIER)
fn enumerate_captures(&self) -> AltoResult<Vec<CString>>
alcGetString(ALC_CAPTURE_DEVICE_SPECIFIER)
fn open<'s, S: Into<Option<&'s CStr>>>(&self, spec: S) -> AltoResult<Device>
alcOpenDevice()
fn open_loopback<'s, S: Into<Option<&'s CStr>>, F: LoopbackFrame>(
&self,
spec: S
) -> AltoResult<LoopbackDevice<F>>
&self,
spec: S
) -> AltoResult<LoopbackDevice<F>>
alcLoopbackOpenDeviceSOFT()
Requires ALC_SOFT_loopback
fn open_capture<'s, S: Into<Option<&'s CStr>>, F: StandardFrame>(
&self,
spec: S,
freq: ALCuint,
len: ALCsizei
) -> AltoResult<CaptureDevice<F>>
&self,
spec: S,
freq: ALCuint,
len: ALCsizei
) -> AltoResult<CaptureDevice<F>>
alcCaptureOpenDevice()