quasarstream / opus
A lightweight PHP wrapper for the libopus audio codec using PHP FFI.
Fund package maintenance!
php-webrtc
Requires
- php: ^8.4
- ext-ffi: *
- quasarstream/av: ^1.0
- quasarstream/exception: ^1.0
- quasarstream/mixin: ^1.0
Requires (Dev)
- phpunit/php-code-coverage: 11.0.x-dev
- phpunit/phpunit: ^11.3
This package is auto-updated.
Last update: 2025-05-12 20:43:41 UTC
README
Deprecation Notice: This library will be replaced with the AV library in a future update.
A lightweight PHP wrapper for the libopus audio codec using PHP FFI.
This package provides encoder and decoder classes for working with raw PCM audio and the Opus format.
Features
- Encode raw PCM audio to Opus format
- Decode Opus-encoded audio back to PCM
- Based on FFI bindings to the native libopus library
- Compatible with multi-channel and variable sample rate audio
Requirements
- PHP ≥ 8.4 with FFI extension enabled
- libopus development libraries
- Linux environment (Windows/macOS support planned)
Documentation
This package is part of the PHP WebRTC library. For complete documentation, examples, and API reference, visit:
Credits
Authors
-
Amin Yazdanpanah
aminyazdanpanah.com github@aminyazdanpanah.com -
Sana Moniri
GitHub
Reporting Issues
Found a bug? Please report it on our issues.
License
BSD 3-Clause License. See LICENSE for details.