Audio Processing

2 posts

discord2 min readCurated summary

Discord’s Powerful Cross-Platform Chat: Ready for Your Game

Discord is moving its Social SDK communication features out of closed beta, allowing games to integrate Discord-powered voice and text chat across desktop, console, and mobile. The SDK is designed to strengthen multiplayer connections, improve player retention, and let users communicate even without Discord accounts. New features such as lobby chat history, custom audio processing, and diagnostics make the integration more practical for developers. ## Social Features for Games - **Unified friends lists** let players access Discord friends in-game and connect with friends made through the game. - **Rich Presence** works across desktop, console, and mobile, displaying gameplay activity and supporting one-click joins. - **Game Invites** help players launch games and enter the correct party or lobby quickly. - **Cross-platform chat** supports communication between desktop, mobile, and console players, including users without Discord accounts. - **Discord Voice Chat** brings Discord’s real-time voice infrastructure into game lobbies, guilds, and matches. - **Linked Channels** connect in-game text lobbies with selected Discord channels. ## New Communication Improvements - **Chat history for active lobbies** allows conversations to persist between play sessions. - **Direct-message history** is planned for a future release. - **Custom effect processing** lets developers route Discord voice audio through middleware such as FMOD or Wwise. - **Audio diagnostics** provide debugging information about issues including echo cancellation and noise reduction. - **Mobile audio improvements** increase audio quality and connection stability. - Updated documentation covers voice chat management, moderation, lobby history, and chat-history design. ## Accessing the SDK - Developers must use the Discord Developer Portal. - The setup process involves selecting a platform, creating a Discord Application, and enabling the Social SDK. - Communication features are included in the initial SDK package. - Usage is rate-limited during testing. ## Approval Requirements Before submitting a game for approval, developers must: - Integrate core features such as account linking, Rich Presence with Discord Joins, and Discord Friends. - Ensure all selected features work end-to-end across both the game and Discord clients. - Handle user denials and other failure states correctly. - Make account linking accessible and clearly explained to players. - Provide supporting materials, including integration captures and a development timeline. - Meet Discord’s age-restricted user protection requirements, which are not fully detailed in the provided text. Developers interested in cross-platform social features can begin with the Social SDK now, using Discord’s documentation and developer community for implementation guidance.

Read original(opens in new tab)
datadog3 min readCurated summary

How we built a real-time, client-side noise suppression library without server dependencies

Datadog’s CoScreen team needed high-quality noise suppression that could run in real time on client devices and integrate with WebRTC. Since existing solutions were either too slow, server-dependent, expensive, or difficult to embed, they built and open-sourced **dtln-rs**, a portable Rust library based on the DTLN model. It processes one second of audio in about 33 ms on an M1 MacBook Pro and supports WebAssembly, Node.js, and native clients. ## Introducing dtln-rs - dtln-rs is a lightweight, open-source noise reduction library based on the Dual-Signal Transformation LSTM Network (DTLN). - It can produce: - A WebAssembly module - A native Rust library - A Node.js native module - The library is designed to integrate with WebRTC-based applications. - Datadog also released a demo showing how to embed the filter in an application or webpage. ## Demonstrating Real-World Noise Suppression - The project was motivated by common remote-work disruptions, including lawn mowers and other background noise. - In one test, the filter removed a neighbor’s lawn mower so effectively that a colleague could not tell it was running. - The team used this result as evidence that the embedded library could provide meaningful value to CoScreen users. ## How DTLN Enables Real-Time Processing - AI noise suppression learns to distinguish desired speech from unwanted background sounds. - DTLN uses a short-time Fourier transform (STFT) to divide audio into smaller segments and analyze the magnitude of different frequencies. - It also uses phase information, which describes the starting position of each frequency in the sound wave. - A model analyzes magnitude and phase data to determine which parts are speech and which are noise. - Its LSTM-based architecture can adapt to different environments, such as: - Air-conditioner hum - Cafe conversations - Paper rustling - The combination of deep learning and efficient signal processing allows DTLN to operate with near-instantaneous latency. ## Why Existing Noise Suppression Solutions Were Insufficient - Many advanced machine-learning models require powerful backend servers, with processed audio sent back over the network. - This approach adds latency, infrastructure complexity, and operating costs. - WebRTC remains widely adopted but generally relies on older, built-in noise reduction techniques. - Earlier solutions such as RNNoise can reduce noise but often do not match the quality of newer commercial systems. - Although Web Audio and WebAssembly make custom client-side processing possible, implementation still requires substantial engineering effort. - Large companies can deploy specialized servers and models trained on enormous speech datasets, but smaller teams may not have the resources to do so. - CoScreen’s search for an alternative led to DTLN, which could run in real time on standard hardware and be embedded directly into client applications. ## Practical Recommendation For WebRTC applications needing client-side, real-time noise suppression, dtln-rs offers a portable alternative to expensive server-based services. Its Rust foundation and support for WebAssembly, Node.js, and native targets make it suitable for web, desktop, and embedded clients.

Read original(opens in new tab)