on Jan 24, 2017 at 8:44:06 pm Last Edited By Projectile Creative on Jan 24, 2017 at 8:52:23 pm
I'm looking to build something like this for myself which visualises MIDI data for a piano:
So far I've done the following:
- Created a background graphic with piano keys laid out on it.
- Created separate .ai file with piano keys in blue (for left hand). This file is imported into my project as a Comp called Bass Clef with Footage Dimensions as Layer Size.
- Created separate .ai file with piano keys in pink (for right hand) same as the blue one. Named Comp Treble Clef.
- Split the MIDI file into Bass Clef and Treble Clef, imported the MIDI data into each Bass and Treble comp.
Each of the Bass and Treble Clef has this expression per layer from the .ai files:
The expression isn't doing a good job because it can't work out chords from the MIDI layer. It only picks the value of the Slider Control. This is how the render came out with the expressions per layer above (notice how the chords aren't being shown but only the peak value per Bass and Clef comps).
How can I correct this and can I clean up the code for the layers so there's only one or two places to control all the functions from?
Here's the chord data in dots but the values are always the peak values at that time:
Also, how do I go about creating the falling notes with the little flashing sparks and particles coming off as sprinkles like in the video above?
You're going to need to parse the MIDI note on/off data to know when each key presses down and when it releases.
Once you've done that, you can simulate the piano-roll/Rock-Band-style falling notes by precomping the whole thing, squeezing it down to a single pixel in height, duplicating it a bunch of times and stacking them on top of each other to fill the top half of the screen, then offsetting them in time.