pitch method
double
pitch(
- Float32List input, {
- double sampleRate = 16000,
- @Deprecated('Use sampleRate instead.') double? sample_rate,
- double fmin = 60,
- double fmax = 600,
Implementation
double pitch(
Float32List input, {
double sampleRate = 16000,
@Deprecated('Use sampleRate instead.')
// ignore: non_constant_identifier_names
double? sample_rate,
double fmin = 60,
double fmax = 600,
}) {
if (input.length != inputLen) {
throw ArgumentError('input length ${input.length} != inputLen $inputLen');
}
final r = res;
r.input.asTypedList(n).setAll(0, input);
final pitch = yl_pitch_acf_frame(
r.plan,
r.input,
inputLen,
r.xcorr,
1,
sample_rate ?? sampleRate,
fmin,
fmax,
);
return pitch;
}