Cauldron3D.Formats.Wav (Cauldron3D.Formats v0.3.3)

Copy Markdown View Source

RIFF WAVE sounds of 8- or 16-bit mono PCM, read to 16-bit PCM.

{:ok, %{rate: rate, pcm: pcm, loop: loop}} = Cauldron3D.Formats.Wav.read(bytes)

A file with a cue point loops from it; loop says where, in seconds.

Summary

Functions

The sound's rate, 16-bit PCM and loop start in seconds (nil for a sound that plays once).

Functions

read(arg1)

@spec read(binary() | nil) ::
  {:ok, %{rate: pos_integer(), pcm: binary(), loop: float() | nil}} | :error

The sound's rate, 16-bit PCM and loop start in seconds (nil for a sound that plays once).