JFugue Problems

First Problem

This is my simple source code to export my jfugue music to MIDI

Player player = new Player();

try {

player.saveMidi(“T80 V1 I[Koto] F5s G5s G#5s G5s F5s

C#5s F5s G5s G5s F5s C#5s G#5s F5s F5s F5s G5s”,

new File(“OUTPUT.MID”));

} catch (IOException ex) {

ex.printStackTrace();

}

The midi output open in notation composer, show like this:

Look at the duration, not same with my jfugue string.

Then if I open it in Guitar Pro 5, the tempo become 20. Not 80 again…

Second Problem

This my simple code to export to MusicXML :

MusicXmlRenderer renderer = new MusicXmlRenderer();

renderer.tempoEvent(new Tempo(120));

for (int i=0;i < 32;i++) {

renderer.noteEvent(new Note((byte)64, Note.getDecimalForDuration(“t”)));

}

for (int i=0;i < 32;i++) {

renderer.noteEvent(new Note((byte)65, Note.getDecimalForDuration(“t”)));

}

try {

FileWriter writer = new FileWriter(new File(“OUTPUT.xml”));; BufferedWriter out = new BufferedWriter(writer);

out.write(renderer.getMusicXMLString());

out.close();

} catch (IOException ex) {

ex.printStackTrace();

}

If I open OUTPUT.xml in MuseScore become like this :

Then if I open it in Guitar Pro become like this :

This is I use jfugue-4.0.3, note t become q.

Third Problems

My Third problem is for percussions :

String s = “T80 V9 [42]+[36]s. Rt [42]s Rs [38]+[42]s. Rt [42]s Rs [36]+[42]i [42]s Rs [38]+[42]s. Rt [42]s Rs”;

Player player = new Player();

try {

player.saveMidi(s, new File(“OUT.MID”));

} catch (IOException ex) {

ex.printStackTrace();

}

Output midi open in notation composer :

Iklan
Perihal

Selalu berusaha menjadi lebih baik... I have a BIG DREAM

Ditulis dalam Java

Tinggalkan Balasan

Isikan data di bawah atau klik salah satu ikon untuk log in:

Logo WordPress.com

You are commenting using your WordPress.com account. Logout /  Ubah )

Foto Google

You are commenting using your Google account. Logout /  Ubah )

Gambar Twitter

You are commenting using your Twitter account. Logout /  Ubah )

Foto Facebook

You are commenting using your Facebook account. Logout /  Ubah )

Connecting to %s

%d blogger menyukai ini: