Will the number of samples in a block of audio always be the same as those in the corresponding midiBuffer?

Is it safe to assume that in your processBlock method, the AudioSampleBuffer and MidiBuffer are both the same size?

ie. if i want to use MidiBuffer::addEvents, is it safe just to take the getNumSamples() from the AudioSampleBuffer to calculate the MidiBuffer size?

Yes, that’s the idea.