# `ExCubecl.AudioSamples`
[🔗](https://github.com/ohhi-vn/ex_cubecl/blob/v0.4.0/lib/ex_cubecl/audio_samples.ex#L1)

An audio sample buffer residing on the GPU (f32 planar PCM).

## Fields

  * `handle` — GPU buffer reference (Rustler ResourceArc)
  * `channels` — number of audio channels
  * `sample_rate` — samples per second (e.g. 48000)
  * `frames` — number of samples per channel
  * `pts` — presentation timestamp in microseconds

# `t`

```elixir
@type t() :: %ExCubecl.AudioSamples{
  channels: non_neg_integer(),
  frames: non_neg_integer(),
  handle: reference(),
  pts: non_neg_integer(),
  sample_rate: non_neg_integer()
}
```

# `from_map`

```elixir
@spec from_map(map()) :: t()
```

Creates an AudioSamples from a map returned by the NIF.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
