From 1fce87050381e121476f5156fbee179ab7d4e1a3 Mon Sep 17 00:00:00 2001 From: Recrown Date: Sat, 15 Jul 2017 00:48:01 -0500 Subject: [PATCH] tuning and adjustments --- core/src/zero1hd/polyjet/audio/AudioAnalyzer.java | 2 +- core/src/zero1hd/polyjet/audio/map/GamePlayMap.java | 3 --- core/src/zero1hd/polyjet/audio/map/RhythmMapAlgorithm.java | 4 ++-- core/src/zero1hd/polyjet/ui/builders/AudioGraph.java | 2 +- 4 files changed, 4 insertions(+), 7 deletions(-) diff --git a/core/src/zero1hd/polyjet/audio/AudioAnalyzer.java b/core/src/zero1hd/polyjet/audio/AudioAnalyzer.java index 3fd2b9b..0f02e04 100755 --- a/core/src/zero1hd/polyjet/audio/AudioAnalyzer.java +++ b/core/src/zero1hd/polyjet/audio/AudioAnalyzer.java @@ -64,7 +64,7 @@ public class AudioAnalyzer { int tasksDone = 0; int totalTasks = audioData.getSampleCount()/audioData.getReadWindowSize(); - bassThresholdMultiplier = 1.7f; + bassThresholdMultiplier = 1.5f; umThresholdMultiplier = 1.5f; bassBinBegin = 1; diff --git a/core/src/zero1hd/polyjet/audio/map/GamePlayMap.java b/core/src/zero1hd/polyjet/audio/map/GamePlayMap.java index 092c71c..aec4118 100755 --- a/core/src/zero1hd/polyjet/audio/map/GamePlayMap.java +++ b/core/src/zero1hd/polyjet/audio/map/GamePlayMap.java @@ -1,8 +1,6 @@ package zero1hd.polyjet.audio.map; -import com.badlogic.gdx.Gdx; import com.badlogic.gdx.audio.Music; -import com.badlogic.gdx.math.MathUtils; import com.badlogic.gdx.utils.Array; import zero1hd.polyjet.audio.AudioData; @@ -96,7 +94,6 @@ public class GamePlayMap { playableClip.readIndexUpdate(); if (index != playableClip.getReadIndex()) { index = playableClip.getReadIndex(); - Gdx.app.debug("GPM", "index: " + index); return nextEntity(false); } else { return null; diff --git a/core/src/zero1hd/polyjet/audio/map/RhythmMapAlgorithm.java b/core/src/zero1hd/polyjet/audio/map/RhythmMapAlgorithm.java index 9bf93d4..37f02e2 100755 --- a/core/src/zero1hd/polyjet/audio/map/RhythmMapAlgorithm.java +++ b/core/src/zero1hd/polyjet/audio/map/RhythmMapAlgorithm.java @@ -57,7 +57,7 @@ public class RhythmMapAlgorithm implements Runnable { for (int index = 0; index < bassPeaks.size; index++) { if (bassPeaks.get(index) != 0 || UMPeaks.get(index) != 0) { int warningTime = (int) ((3/speedMod)*windowPerSecond); - if ((index+warningTime < bassPeaks.size) && bassPeaks.get(index + warningTime) >= avgBass) { + if ((index+warningTime < bassPeaks.size) && bassPeaks.get(index + warningTime) != 0) { //TODO basic void circle spawning float endRadius = (bassPeaks.get(index + warningTime)/bassMax)*(Polyjet.GAME_AREA_HEIGHT/2f); @@ -65,7 +65,7 @@ public class RhythmMapAlgorithm implements Runnable { endRadius, rand.nextFloat()*Polyjet.GAME_AREA_WIDTH, rand.nextFloat()*Polyjet.GAME_AREA_HEIGHT, - endRadius/(avgSPB*0.5f), + endRadius/(avgSPB*0.6f), 3f/speedMod ); } diff --git a/core/src/zero1hd/polyjet/ui/builders/AudioGraph.java b/core/src/zero1hd/polyjet/ui/builders/AudioGraph.java index ed6ef0e..1859fb1 100755 --- a/core/src/zero1hd/polyjet/ui/builders/AudioGraph.java +++ b/core/src/zero1hd/polyjet/ui/builders/AudioGraph.java @@ -66,7 +66,7 @@ public class AudioGraph extends Actor { audioGraph.drawLine(x, audioGraph.getHeight(), x, (int) (audioGraph.getHeight()-(mainGraph.get(dataIndex+x-audioGraph.getWidth()/2)/normalDataG1)*scale)); } catch (NullPointerException | IndexOutOfBoundsException e) { } - audioGraph.drawLine(0,audioGraph.getHeight() - MathUtils.round(scale*(avgG1/normalDataG1)), audioGraph.getWidth(), audioGraph.getHeight() - MathUtils.round(scale*(avgG1/normalDataG1))); + audioGraph.drawLine(0, audioGraph.getHeight() - MathUtils.round(scale*(avgG1/normalDataG1)), audioGraph.getWidth(), audioGraph.getHeight() - MathUtils.round(scale*(avgG1/normalDataG1))); } case 1: