SAF
Loading...
Searching...
No Matches
saf_utility_matrixConv.h
Go to the documentation of this file.
1/*
2 * Copyright 2019 Leo McCormack
3 *
4 * Permission to use, copy, modify, and/or distribute this software for any
5 * purpose with or without fee is hereby granted, provided that the above
6 * copyright notice and this permission notice appear in all copies.
7 *
8 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
9 * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
10 * AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
11 * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
12 * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
13 * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
14 * PERFORMANCE OF THIS SOFTWARE.
15 */
16
28#ifndef SAF_MATRIXCOLV_H_INCLUDED
29#define SAF_MATRIXCOLV_H_INCLUDED
30
31#ifdef __cplusplus
32extern "C" {
33#endif /* __cplusplus */
34
35/* ========================================================================== */
36/* Matrix Convolver */
37/* ========================================================================== */
38
55void saf_matrixConv_create(/* Input Arguments */
56 void ** const phMC,
57 int hopSize,
58 float* H,
59 int length_h,
60 int nCHin,
61 int nCHout,
62 int usePartFLAG);
63
69void saf_matrixConv_destroy(/* Input Arguments */
70 void ** const phMC);
71
72
78void saf_matrixConv_reset(void * const hMC);
79
90void saf_matrixConv_apply(/* Input Arguments */
91 void * const hMC,
92 float* inputSigs,
93 /* Output Arguments */
94 float* outputSigs);
95
96
97/* ========================================================================== */
98/* Multi-Channel Convolver */
99/* ========================================================================== */
100
117void saf_multiConv_create(/* Input Arguments */
118 void ** const phMC,
119 int hopSize,
120 float* H,
121 int length_h,
122 int nCH,
123 int usePartFLAG);
124
130void saf_multiConv_destroy(/* Input Arguments */
131 void ** const phMC);
132
138void saf_multiConv_reset(void * const hMC);
139
147void saf_multiConv_apply(/* Input Arguments */
148 void * const hMC,
149 float* inputSigs,
150 /* Output Arguments */
151 float* outputSigs);
152
153/* ========================================================================== */
154/* Time-Varying Convolver */
155/* ========================================================================== */
156
172void saf_TVConv_create(/* Input Arguments */
173 void ** const phTVC,
174 int hopSize,
175 float** H,
176 int length_h,
177 int nIRs,
178 int nCHout,
179 int initIdx);
180
186void saf_TVConv_destroy(/* Input Arguments */
187 void ** const phTVC);
188
200void saf_TVConv_apply(/* Input Arguments */
201 void * const hTVC,
202 float* inputSigs,
203 /* Output Arguments */
204 float* outputSigs,
205 int irIdx);
206
207#ifdef __cplusplus
208}/* extern "C" */
209#endif /* __cplusplus */
210
211#endif /* SAF_MATRIXCOLV_H_INCLUDED */
212
213 /* doxygen addtogroup Utilities */
void saf_multiConv_destroy(void **const phMC)
Destroys an instance of multiConv.
void saf_matrixConv_apply(void *const hMC, float *inputSigs, float *outputSigs)
Performs the matrix convolution.
void saf_TVConv_apply(void *const hTVC, float *inputSigs, float *outputSigs, int irIdx)
Performs the matrix convolution.
void saf_multiConv_apply(void *const hMC, float *inputSigs, float *outputSigs)
Performs the multi-channel convolution.
void saf_multiConv_reset(void *const hMC)
Flushes internal buffers with zeros.
void saf_matrixConv_create(void **const phMC, int hopSize, float *H, int length_h, int nCHin, int nCHout, int usePartFLAG)
Creates an instance of matrixConv.
void saf_TVConv_create(void **const phTVC, int hopSize, float **H, int length_h, int nIRs, int nCHout, int initIdx)
Creates an instance of TVConv.
void saf_multiConv_create(void **const phMC, int hopSize, float *H, int length_h, int nCH, int usePartFLAG)
Creates an instance of multiConv.
void saf_TVConv_destroy(void **const phTVC)
Destroys an instance of matrixConv.
void saf_matrixConv_destroy(void **const phMC)
Destroys an instance of matrixConv.
void saf_matrixConv_reset(void *const hMC)
Flushes internal buffers with zeros.