0

From a text file, i should get the necessary information in order to create a beat map, a representation of what we see in music sheets, from this text file:

3 measures
3 4 time signature
4 beats
4 note, measure 1
3 note, measure 1
1R rest, measure 1
4 note, measure 1
4 4 time signature
1 beat, measure 1
0 note, measure 1
2 4 time signature
1 beat, measure 1
1R (corresponds to the half rest)

How do I determine the number of measures[Line 1],
the time signature of each measure[LINE 2,8,11],
the number of beats for each measure[Lines 3,9,12]
and their durations(each note)?

All i can do is a code that reads from this file :(
Any suggestion would be welcome

Reason why I should be able to get this is to create an output that looks like:
(output should be redirected to a text file)

||-----------|----------|---------|---------|-----------||----
||---4-------|----------|---------|---------|-----------||----
||-----------|----------|---------|---------|-----------||----
||-----------|----------|---------|---------|-----------||----
||---4-------|----------|---------|---------|-----------||----
||-----------|----------|---------|---------|-----------||----
10          Mary       had                  a           11

In which

This corresponds to a Measure 10 with 4/4 time, and the lyrics laid out among its four beats, 1 of which is a rest (so that it had to be skipped).

The beats must be spaced out proportionally in relation to each other. For example, a half beat is noticeably wider than a quarter beat, which is noticeably wider than an eighth beat, and so on.

If there are multiple measures then they must be laid out side by side. There should only be one column of double-pipes ("||") in between them. The left vertical line should have the measure number below it, just as you saw above (10).

2
Contributors
1
Reply
3
Views
5 Years
Discussion Span
Last Post by YAMNA MIDHAT
-1

From a text file, i should get the necessary information in order to create a beat map, a representation of what we see in music sheets, from this text file:

3 measures
3 4 time signature
4 beats
4 note, measure 1
3 note, measure 1
1R rest, measure 1
4 note, measure 1
4 4 time signature
1 beat, measure 1
0 note, measure 1
2 4 time signature
1 beat, measure 1
1R (corresponds to the half rest)

How do I determine the number of measures[Line 1],
the time signature of each measure[LINE 2,8,11],
the number of beats for each measure[Lines 3,9,12]
and their durations(each note)?

All i can do is a code that reads from this file :(
Any suggestion would be welcome

Reason why I should be able to get this is to create an output that looks like:
(output should be redirected to a text file)

||-----------|----------|---------|---------|-----------||----
||---4-------|----------|---------|---------|-----------||----
||-----------|----------|---------|---------|-----------||----
||-----------|----------|---------|---------|-----------||----
||---4-------|----------|---------|---------|-----------||----
||-----------|----------|---------|---------|-----------||----
10          Mary       had                  a           11

In which

This corresponds to a Measure 10 with 4/4 time, and the lyrics laid out among its four beats, 1 of which is a rest (so that it had to be skipped).

The beats must be spaced out proportionally in relation to each other. For example, a half beat is noticeably wider than a quarter beat, which is noticeably wider than an eighth beat, and so on.

If there are multiple measures then they must be laid out side by side. There should only be one column of double-pipes ("||") in between them. The left vertical line should have the measure number below it, just as you saw above (10).

SORRY i cant help you because i am also a new learner.

Votes + Comments
Then don't bother posting!
This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.