#include <stddef.h>
#include <string.h>
Go to the source code of this file.
clones the context and returns a pointer to the newly allocated copy
deinitializes a "dsd2pcm engine" (releases memory, don't forget!)
initializes a "dsd2pcm engine" for one channel (precomputes tables and allocates memory)
This is the only function that is not thread-safe in terms of the POSIX thread-safety definition because it modifies global state (lookup tables are computed during the first call)
resets the internal state for a fresh new stream
void dsd2pcm_translate |
( |
dsd2pcm_ctx * |
ctx, |
|
|
size_t |
samples, |
|
|
const unsigned char * |
src, |
|
|
ptrdiff_t |
src_stride, |
|
|
int |
lsbitfirst, |
|
|
float * |
dst, |
|
|
ptrdiff_t |
dst_stride |
|
) |
| |
"translates" a stream of octets to a stream of floats (8:1 decimation)
- Parameters
-
ctx | – pointer to abstract context (buffers) |
samples | – number of octets/samples to "translate" |
src | – pointer to first octet (input) |
src_stride | – src pointer increment |
lsbitfirst | – bitorder, 0=msb first, 1=lsbfirst |
dst | – pointer to first float (output) |
dst_stride | – dst pointer increment |