Skip to content

discordjs/opus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

679ff3f · Jan 28, 2025

History

64 Commits
Jan 28, 2025
May 19, 2024
Oct 20, 2022
Jul 11, 2024
Mar 9, 2024
Mar 9, 2024
Oct 20, 2022
Jan 15, 2020
May 2, 2020
Oct 20, 2022
Jun 10, 2021
Mar 19, 2021
Oct 20, 2022
Nov 12, 2021
Jan 25, 2025
Jan 25, 2025

Repository files navigation

@discordjs/opus Build Prebuild

Native bindings to libopus v1.3

Usage

const { OpusEncoder } = require('@discordjs/opus');

// Create the encoder.
// Specify 48kHz sampling rate and 2 channel size.
const encoder = new OpusEncoder(48000, 2);

// Encode and decode.
const encoded = encoder.encode(buffer);
const decoded = encoder.decode(encoded);

Platform support

⚠ Node.js 12.0.0 or newer is required.

  • Linux x64 & ia32
  • Linux arm (RPi 1 & 2)
  • Linux arm64 (RPi 3)
  • macOS x64
  • macOS arm64
  • Windows x64