Saturday, 21 March 2015

Controlling Visualiser with Keys and Amplitude

The last development post showed the visualiser being controlled with the keys on the Microkorg. However, the velocity made the 3D bars static and boring. The next step was therefore to find a way to route the audio of the synthesiser to each rendered bar.

One of the rendered bars. Main elements of discussion is circled

The objects that are circled in the image above are what allows the bars to be controlled by amplitude. The 'r k1' object is the receiving the velocity of the corresponding key being pressed. The 'r band1' is receiving the amplitude. These are both being sent to a multiplication object which is then being fed to control the scale of the 3D bar. This works because even if the amplitude being sent is high, unless the key is being pressed sending a velocity number, the amplitude is being multiplied by 0, so it's equal to 0 meaning no scale increase. However, what I found was because the velocity went up to 15, as it was being clipped at 15, the scale got pretty big when being multiplied by 15. To fix this, I changed the pong object so it was now being limited to 1. This kept the scale under control and looking good.

Screenshot showing that velocity is limited to 1 with pong object.

The keys were now doing exactly what I wanted this project to do now. Each key controlled a corresponding 3D rendered bar, with the scale being dictated by the amplitude of the audio. It looked brilliant. But I wanted to make it look a bit more interesting. I was inspired by how another project was spinning as it was showing it's visualiser. See blog post Other Interesting Max MSP Visualisers . I also wanted to add another element that would allow a backing track to be represented with a 3D rendered shape. This would be the next step that will hopefully finish the project.

No comments:

Post a Comment