another attempt to better remedy song transition for visualizer
This commit is contained in:
parent
8cbefb1f0f
commit
67f9105922
@ -39,15 +39,15 @@ public class VisualizerCore implements Disposable {
|
||||
}
|
||||
|
||||
public void setMM(MusicManager mm) {
|
||||
lock.lock();
|
||||
if (audioPCM == null || audioPCM.length != mm.getReadWindowSize()) {
|
||||
calc = false;
|
||||
lock.lock();
|
||||
fft = new FloatFFT_1D(mm.getReadWindowSize());
|
||||
audioPCM = new float[mm.getReadWindowSize()];
|
||||
lock.unlock();
|
||||
}
|
||||
this.mm = mm;
|
||||
calc = true;
|
||||
lock.unlock();
|
||||
}
|
||||
|
||||
public void render(Batch batch, float parentAlpha) {
|
||||
|
Loading…
Reference in New Issue
Block a user