MPD: pcm/PcmPack.hxx File Reference

MPD 0.20.15

Functions
PcmPack.hxx File Reference

Library for working with packed 24 bit samples. More...

`#include <stdint.h>`
Include dependency graph for PcmPack.hxx:

Go to the source code of this file.

## Functions
void | pcm_pack_24 (uint8_t *dest, const int32_t *src, const int32_t *src_end)
| Converts padded 24 bit samples (4 bytes per sample) to packed 24 bit samples (3 bytes per sample). More...
void | pcm_unpack_24 (int32_t *dest, const uint8_t *src, const uint8_t *src_end)
| Converts packed 24 bit samples (3 bytes per sample) to padded 24 bit samples (4 bytes per sample). More...

## Detailed Description

Library for working with packed 24 bit samples.

Definition in file PcmPack.hxx.

## Function Documentation

## ◆ pcm_pack_24()

void pcm_pack_24 | ( | uint8_t * | dest,
|  | const int32_t * | src,
|  | const int32_t * | src_end
| ) |  |

Converts padded 24 bit samples (4 bytes per sample) to packed 24 bit samples (3 bytes per sample).

This function can be used to convert a buffer in-place.

Parameters

  dest | the destination buffer (array of triples)
  src | the source buffer

## ◆ pcm_unpack_24()

void pcm_unpack_24 | ( | int32_t * | dest,
|  | const uint8_t * | src,
|  | const uint8_t * | src_end
| ) |  |

Converts packed 24 bit samples (3 bytes per sample) to padded 24 bit samples (4 bytes per sample).

Parameters

  dest | the destination buffer
  src | the source buffer (array of triples)