Repository navigation
Add fixed-frame microphone AEC/NS seam - #9
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (6)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughДобавлен C++ API ChangesRealtime audio processing
Native runtime и pre-encoded video
Estimated code review effort: 5 (Critical) | ~120 minutes Merge Risk: ⚪ Minimal · up to This adds fixed-frame microphone AEC/NS processing with validation and tested bypass, noise suppression, echo attenuation, and thread-ownership behavior. No actionable merge-readiness risk remains. Sequence Diagram(s)sequenceDiagram
participant Application
participant RealtimeAudioProcessing
participant RustRealtimeApm
participant WebRTC APM
Application->>RealtimeAudioProcessing: process(microphone, reference, flags)
RealtimeAudioProcessing->>RustRealtimeApm: realtime_apm_process
RustRealtimeApm->>WebRTC APM: process_10ms
WebRTC APM-->>RustRealtimeApm: processed samples and status
RustRealtimeApm-->>RealtimeAudioProcessing: result code
RealtimeAudioProcessing-->>Application: RealtimeAudioProcessingResult
Suggested reviewers: Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 23.08% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 13 functions across 3 files. (3 skipped: 3 unsupported.)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
The existing microphone APM path makes 17,000 heap allocations for 1,000 warmed forward/reverse/delay frames through protobuf FFI. This adds an exclusively owned fixed 48 kHz mono/10 ms AEC/NS seam for application issue #127, preserving the existing APM API.
The private ABI is limited to create/process/destroy. Two independent processors are allocated and prewarmed during construction; processing uses fixed buffers and integer errors without Room state or the global FFI handle table. AEC is bypassed when reference is unavailable while NS remains usable. There is no reset API: an initial experiment found 1,369 allocations in WebRTC Initialize, so a new renderer timeline requires a newly prepared processor. The application's frame callback reports unsupported AEC on that transition rather than allocating.
Validation on Windows x64 Release:
These are bounded synthetic/local results, not a full ETW, physical-room, double-talk, or all-platform qualification. Details and limitations are in
docs/realtime-microphone-dsp.md. Application capture/publication soak and remaining acceptance remain tracked in #127.Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.Summary by CodeRabbit
Новые возможности
Исправления
Документация