diff --git a/Project.xml b/Project.xml
index d93cf3e42..e0e25883d 100644
--- a/Project.xml
+++ b/Project.xml
@@ -126,6 +126,7 @@ xsi:schemaLocation="http://lime.openfl.org/project/1.0.4 http://lime.openfl.org/
+
diff --git a/hmm.json b/hmm.json
index f94b662ac..68e0c5cb0 100644
--- a/hmm.json
+++ b/hmm.json
@@ -56,9 +56,16 @@
"name": "funkin.vis",
"type": "git",
"dir": null,
- "ref": "2aa654b974507ab51ab1724d2d97e75726fd7d78",
+ "ref": "38261833590773cb1de34ac5d11e0825696fc340",
"url": "https://github.com/FunkinCrew/funkVis"
},
+ {
+ "name": "grig.audio",
+ "type": "git",
+ "dir": "src",
+ "ref": "57f5d47f2533fd0c3dcd025a86cb86c0dfa0b6d2",
+ "url": "https://gitlab.com/haxe-grig/grig.audio.git"
+ },
{
"name": "hamcrest",
"type": "haxelib",
diff --git a/source/funkin/audio/visualize/ABotVis.hx b/source/funkin/audio/visualize/ABotVis.hx
index b94f20b38..1b0463144 100644
--- a/source/funkin/audio/visualize/ABotVis.hx
+++ b/source/funkin/audio/visualize/ABotVis.hx
@@ -54,8 +54,15 @@ class ABotVis extends FlxTypedSpriteGroup
public function initAnalyzer()
{
@:privateAccess
- analyzer = new SpectralAnalyzer(7, new LimeAudioClip(cast snd._channel.__source), 0.01, 30);
- analyzer.maxDb = -35;
+ analyzer = new SpectralAnalyzer(snd._channel.__source, 7, 0.1, 30);
+
+ #if desktop
+ // On desktop it uses FFT stuff that isn't as optimized as the direct browser stuff we use on HTML5
+ // So we want to manually change it!
+ analyzer.fftN = 512;
+ #end
+
+ // analyzer.maxDb = -35;
// analyzer.fftN = 2048;
}
@@ -79,9 +86,7 @@ class ABotVis extends FlxTypedSpriteGroup
override function draw()
{
- #if web
if (analyzer != null) drawFFT();
- #end
super.draw();
}
@@ -90,7 +95,7 @@ class ABotVis extends FlxTypedSpriteGroup
*/
function drawFFT():Void
{
- var levels = analyzer.getLevels(false);
+ var levels = analyzer.getLevels();
for (i in 0...min(group.members.length, levels.length))
{