struct property

StructType<AudioStreamD> struct
final

Describes the raw memory layout, construction, and pointer representation of this struct type.

Implementation

static final StructType<AudioStreamD> struct = .new(
  factory: AudioStreamD.new,
  layout: .aligned<AudioStreamField>({
    .buffer:     RPointer(ROpaque()), // Pointer to internal data used by the audio system
    .processor:  RPointer(ROpaque()), // Pointer to internal data processor, useful for audio effects
    .sampleRate: RUnsignedInt(), // Frequency (samples per second)
    .sampleSize: RUnsignedInt(), // Bit depth (bits per sample): 8, 16, 32 (24 not supported)
    .channels:   RUnsignedInt(), // Number of channels (1-mono, 2-stereo, ...)
  }),
);