Comments (8)
I'm not an expert but I think this is certainly possible in Godot. But I really think it is better if you ask this in Godot Q&A, Godot Discord server, Godot subreddit, etc. I maybe can help you there and others can help as well.
from godot-voip.
Yes, you just have to add the capture effect to the same audio bus you play your music in and you will be able to capture it.
from godot-voip.
Ok, I think i will make an account at Godot Q&A.
from godot-voip.
I will look at you Input threshold.e2e78b2 Maybe something like that is what I need.
from godot-voip.
Somehow you send the audio data only when the input sensitivity is lower than the sound. Could you shortly explain how you did that and if it is possible to get a signal when the music is "louder"?
Edit: Have you used the new effect capture for that?
https://github.com/casbrugman/godot-voip/blob/e2e78b29cd1d944ca501f93eccd87c054ceeba37/addons/godot-voip/scripts/voip_instance.gd#L60
from godot-voip.
Yes I use the capture effect to get the microphone input for the plugin.
See:
var stereo_data = _effect_capture.get_buffer(_effect_capture.get_frames_available())
#Loop over the array to get the highest value.
var max_value = 0.0
for i in range(stereo_data.size()):
var value = (stereo_data[i].x + stereo_data[i].y) / 2.0
max_value = max(value, max_value)
#If value is lower than the threshold stop
if max_value < input_threshold:
return
After that the logic you want to run when the threshold is reached.
from godot-voip.
Thank you!
I will try to implement this in the next few days.
Would the audio capture also work with music files or only with a mic?
from godot-voip.
I'm glad to tell you that the beat detection works :)
Thanks a lot for this code!
I have not done any fine tuning yet.
Here is an example (with audio):
Beat.mp4
from godot-voip.
Related Issues (20)
- for some reason it won't let me activate the plugin HOT 3
- Problem to connect to server HOT 1
- The sound is choppy when the program receives 9+ input signals HOT 21
- Error In Demo HOT 7
- Update to 3.3.1 HOT 2
- Tip for submitting both a demo and an addon from the same repo HOT 1
- Use Opus HOT 7
- Not working using Godot 3.3 and Godot 3.4 HOT 13
- ENet compatibility HOT 1
- Not Working on Android Platform HOT 2
- [Feature Request] - encryption HOT 1
- Buffer consistently growing, making the application lag and unusable HOT 1
- [Feature] Attack/Release settings HOT 1
- Compatibility with Godot 3.5 HOT 4
- [HELP WANTED] Any idea on removing echo?
- Does it have Godot 4 support? HOT 4
- Set stereo to false
- Update 3.2.4 / 4.0 -> real time VoIP HOT 4
- [Feature] - Disconnect HOT 2
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 godot-voip.