Hi, Just wondering if anyone could help me with this problem.

Currently I am developing a singing game type game, same style as sing star but with scrolling e.g. rock band.

The problem I’m having is that I don’t exactly know how long should the bars to be drawn.

Right now, i currently read midi file that contains the information I need for finding what time the notes are being played (the timings the in the midi file get converted correctly to milliseconds).

Lets say for example, I screen the size of 1920 pixles where the bars(notes) will scroll along.

The first note appears at 0 seconds and ends at 2 seconds.

How long should the note be drawn?

Right now I though perhaps if the screen is 1920 = distance and I can decide how long should a note stay on a screen (lets say for 10 seconds)

If i use the distance = speed * time;

then the speed of the notes should go at :

speed = 1920 / 10 => 192 pixels per second;

then for the note for the note lasting for 2 seconds should be at a length of 384 pixels?

This does not seem correct.

Has anyone else attempted to do something similar I am?

I am also wondering if I should be using the tempo of the song for the speed of the scrolling?

  • You must to post comments

Hi TheMadMe, as far as I am aware there is not a cut and dry solution to that problem. I think you should try some values out and see what works. I would suspect it would be at least partially dependant on the complexity of the song, how repetitive it is as well as the tempo. I also think abstracting out the ‘pixels’ and thinking of things as fractions of the view area would be a good start, if you decide to support more resolutions or introduce a graphical border changing view area’s width in pixels, it could change that and throw everything off if you measure things in pixels.

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.