Comments (2)
I've done some further digging and testing, and have learned that there are rigid requirements for frame lengths, so you can't throw just any input buffer length and expect it to work. So if you I changed the allocated buffer size to something like 3840 (20ms of 48khz stereo samples), it works.
This wasn't helped by the fact that the "encode" method doesn't check for errors and turn them into strings, like the decode() method does. And when I went back to the xnorpx test code, I think that was failing because my test wav file was 44100 (unsupported sample rate). The rest I'll chalk up to my own learning curve on the opus codec.
But the library's working now, thanks!
from opus.
This is by design of this library.
If you look at the code and the library methods, it just wraps the native opus methods to expose them to node, no further validation or verification is done.
from opus.
Related Issues (20)
- Support for Raspberry pi 4
- Not installing in mac m1 (macOs 11.2)
- [SECURITY] DoS in @discordjs/opus due to invalid encoders/buffers (CVE-2022-25345) HOT 1
- Can not install @discordjs/opus in build/local environment HOT 6
- Where 0.5.0 version? My project broken because it not exist anymore HOT 1
- Add JSDoc to decode method HOT 1
- question: NPM wont install ubuntu
- Json decoder error HOT 2
- I can't download opus on djs 14 HOT 1
- Unable to NPM Install HOT 1
- dyld[53422]: missing symbol called on `decode`. HOT 5
- unable to npm install macOS HOT 9
- Add Glibc 2.36 in the precompiled binaries HOT 1
- @discordjs/opus does not support nodejs versions > v18.18.2 HOT 13
- Cannot decode opus that came from openAI (Data corrupted) HOT 1
- NPM Install Failure 404 HOT 2
- [Bun] Cannot find module "@discordjs/opus/prebuild/node-v115-napi-v3-linux-x64-glibc-2.29/opus.node" HOT 3
- Support for Node 20 HOT 3
- Recent Security Concerns - CVE-2024-21521 HOT 2
- Can't install on rocky linux arm
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from opus.