Utility class for resampling audio data.
More...
Utility class for resampling audio data.
◆ Resampler() [1/2]
| fm.liveswitch.Resampler.Resampler |
( |
double |
factor | ) |
|
◆ Resampler() [2/2]
| fm.liveswitch.Resampler.Resampler |
( |
int |
sourceClockRate, |
|
|
int |
targetClockRate |
|
) |
| |
Initializes a new instance of the fm.liveswitch.Resampler class.
- Parameters
-
| sourceClockRate | The source clock rate. |
| targetClockRate | The target clock rate. |
◆ getDefaultLowPassOrder()
| static int fm.liveswitch.Resampler.getDefaultLowPassOrder |
( |
| ) |
|
|
static |
Gets the default low pass order.
◆ getFactor()
| double fm.liveswitch.Resampler.getFactor |
( |
| ) |
|
Gets the resampling factor.
◆ getHighQuality()
| boolean fm.liveswitch.Resampler.getHighQuality |
( |
| ) |
|
Gets whether to use high-quality anti-aliasing during resampling.
◆ getOutputLength()
Gets the length of the output given an input set.
- Parameters
-
◆ resample() [1/2]
Resamples the given audio buffer.
- Parameters
-
| input | The input to resample. |
| output | The output to target. |
◆ resample() [2/2]
Resamples the given audio buffer.
- Parameters
-
| input | The input to resample. |
| output | The output to target. |
| lastBatch | Whether or not this is the last batch. If , input will be read to the end. |
- Returns
- if the resampling operation was successful; otherwise, .
◆ setDefaultLowPassOrder()
| static void fm.liveswitch.Resampler.setDefaultLowPassOrder |
( |
int |
value | ) |
|
|
static |
Sets the default low pass order.
◆ setHighQuality()
| void fm.liveswitch.Resampler.setHighQuality |
( |
boolean |
value | ) |
|
Sets whether to use high-quality anti-aliasing during resampling.