opus_projection_decode_float method

int opus_projection_decode_float(
  1. Pointer<OpusProjectionDecoder> st,
  2. Pointer<Uint8> data,
  3. int len,
  4. Pointer<Float> pcm,
  5. int frame_size,
  6. int decode_fec,
)

Decode a projection Opus packet with floating point output. @param st OpusProjectionDecoder*: Projection decoder state. @paramin data const unsigned char*: Input payload. Use a NULL pointer to indicate packet loss. @param len opus_int32: Number of bytes in payload. @paramout pcm opus_int16*: Output signal, with interleaved samples. This must contain room for frame_size*channels samples. @param frame_size int: The number of samples per channel of available space in a pcm. If this is less than the maximum packet duration (120 ms; 5760 for 48kHz), this function will not be capable of decoding some packets. In the case of PLC (data==NULL) or FEC (decode_fec=1), then frame_size needs to be exactly the duration of audio that is missing, otherwise the decoder will not be in the optimal state to decode the next incoming packet. For the PLC and FEC cases, frame_size must be a multiple of 2.5 ms. @param decode_fec int: Flag (0 or 1) to request that any in-band forward error correction data be decoded. If no such data is available, the frame is decoded as if it were lost. @returns Number of samples decoded on success or a negative error code (see @ref opus_errorcodes) on failure.

Implementation

int opus_projection_decode_float(
  ffi.Pointer<OpusProjectionDecoder> st,
  ffi.Pointer<ffi.Uint8> data,
  int len,
  ffi.Pointer<ffi.Float> pcm,
  int frame_size,
  int decode_fec,
) {
  return _opus_projection_decode_float(
      st, data, len, pcm, frame_size, decode_fec);
}