voice_audio_multi/include/engine/framework/audio/streaming_resampler.h
Fabio c36510c21e
Some checks failed
Linux Build / Linux cpu (push) Has been cancelled
Linux Build / Linux cpu-clang (push) Has been cancelled
Linux Build / Linux vulkan (push) Has been cancelled
mac-build / macOS CPU (push) Has been cancelled
Nix Build / Nix (cpu) (push) Has been cancelled
Nix Build / Nix (vulkan) (push) Has been cancelled
windows-build / Windows CPU (push) Has been cancelled
Initial import: audio.cpp with Orange Pi documentation
2026-11-04 19:05:22 +01:00

19 lines
478 B
C++

#pragma once
#include <memory>
#include <vector>
namespace engine::audio {
// Stateful mono F32 resampling. Flush once at end; never resample chunks independently.
class StreamingSoxrResampler {
public:
StreamingSoxrResampler(int source_rate, int target_rate);
~StreamingSoxrResampler();
std::vector<float> process(const std::vector<float> & samples, bool final = false);
private:
class Impl;
std::unique_ptr<Impl> impl_;
};
} // namespace engine::audio