Menu

#42 out of bounds error

open
nobody
5
2013-02-07
2012-03-27
Anonymous
No

When creating a histogram of a midi file, an OutOFBoundsException is raised.
The array dimensions of dynamicValues was 127 and should be 128.

private void analysis() {
// rest values
pitchValues = new int[128];
rhythmValues = new int[66];
dynamicValues = new int[128]; // <----- fixed!

Discussion


Log in to post a comment.