Comments (4)
目前我这个插件暂时无法解决你的需求。
但是我可以提供一个思路,比如你可以把项目fork下来,在https://github.com/jiwenjiang/react-audio-analyser/blob/e63193b3f413b0c60deb0d54fdada74e8ba40d02/src/component/AudioAnalyser/RenderCanvas.js#L53 这里找到音频上下文中拿到的音频信息数组(是一个长度为2048的类型数组,默认值都为128,录音信息会在128上下波动),通过设立一个阈值,来标记你认为有效音频的音频范围(实际开发这个功能在这个函数外边去操作,这里只是方便你查看),做一个debounce,在一定时间内如果满足你的阈值,就将之前的音频存储下来,然后记录新的音频。
from react-audio-analyser.
我看到这里了,可以获取波形数据和频域数据,那么获取的频域数据是Float32Array的数据,如何再重新转换成wav呢? 现在看你的转换是将getUserMedia获取的MediaStream -> AudioBuffer -> wav
from react-audio-analyser.
本身获取的音频数据,只是为了让你知道什么时候去做音频的分片,并不是在那里拿。
你可以在做wav转换这里来进行你的操作,把音频上下文去转换类型数组的这个逻辑拿出来,放在转码wav的地方,当满足你对音频分片的逻辑时,就把这个wav取出来就行了。简单说,类型数组使你用来判断什么时间节点来分片的。
from react-audio-analyser.
您好,我想了很久,还是没有想到如何操作,能不能帮我一下呢?
from react-audio-analyser.
Related Issues (20)
- 音频波没有正常波动 HOT 5
- 手机录音报错啊 HOT 1
- Error when install on a next project HOT 2
- 录制时长问题 HOT 6
- 生产环境 Cannot read property 'errorCallback' of undefined HOT 10
- 当页面上同时有多个AudioAnalyser组件时,波只会显示在其中一个组件上。 HOT 2
- safari支持
- The AudioContext was not allowed to start. HOT 3
- 点击stop后,网页端麦克风没有关闭的问题 HOT 2
- Issue with import ./AudioAnalyser
- 您好,我想计算audio的时间,有获取audio对象的方法吗 HOT 1
- Cannot record on IOS HOT 1
- react antd 下运行报错 HOT 1
- Safari 浏览器下会录制会出现如下错误: HOT 1
- Need blob during audio recording HOT 2
- Migrate from Class to React Hooks Functional Component
- recording red dot icon is remain same on browser tab after i stop recording . HOT 2
- Still WaveForm Canvas after pressing Stop HOT 8
- 加上了您注释的采样率,录音后播放没声音了。
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 react-audio-analyser.