Processes multiple Sound objects and extracts Pitch at the C++ level, avoiding O(n) R→C boundary crossings from calling `$to_pitch()` in a loop.
Usage
sound_to_pitch_batch(
sounds,
time_step = 0,
pitch_floor = 75,
pitch_ceiling = 600,
return_r6 = TRUE
)Examples
sounds <- list(
Sound$create_tone(frequency = 150, duration = 0.5),
Sound$create_tone(frequency = 200, duration = 0.5)
)
pitches <- sound_to_pitch_batch(sounds)