「VexFlow タブ譜 コードフォーム」の版間の差分
499行目: | 499行目: | ||
Guitar1St1.addKeySignature('D').setContext(ctx); | Guitar1St1.addKeySignature('D').setContext(ctx); | ||
Guitar1St1.draw(); | Guitar1St1.draw(); | ||
const Guitar1_St1_notes_1 = [ | |||
new VF.StaveNote({ keys: ["b/4"], duration: "4" }), | |||
new VF.StaveNote({ keys: ["b/4"], duration: "8" }), | |||
new VF.StaveNote({ keys: ["b/4"], duration: "8" }), | |||
new VF.StaveNote({ keys: ["b/4"], duration: "8" }), | |||
new VF.StaveNote({ keys: ["b/4"], duration: "8" }), | |||
new VF.StaveNote({ keys: ["b/4"], duration: "8" }), | |||
new VF.StaveNote({ keys: ["b/4"], duration: "8" }), | |||
]; | |||
const Guitar1_St1_notes_2 = [ | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
new VF.GhostNote({ keys: ["f/4"], duration: "16"}), | |||
]; | |||
var Guitar1_St1_Voice_1 = new Vex.Flow.Voice({ num_beats: 4, beat_value: 4 }); | |||
Guitar1_St1_Voice_1.setStrict(true); | |||
Guitar1_St1_1Voice_1.addTickables(Guitar1_St1_notes_1); | |||
var Guitar1_St1_Voice_2 = new Vex.Flow.Voice({ num_beats: 4, beat_value: 4 }); | |||
Guitar1_St1_Voice_2.setStrict(true); | |||
Guitar1_St1_Voice_2.addTickables(Guitar1_St1_notes_2); | |||
var formatterGuitar1_St1 = new Vex.Flow.Formatter().joinVoices([Guitar1_St1_Voice_1, Guitar1_St1_Voice_2]); | |||
formatterGuitar1_St1.format([Guitar1_St1_Voice_1, Guitar1_St1_Voice_2], nStaveWidth - 20 - 10); | |||
Guitar1_St1_Voice_1.draw(ctx, Guitar1St1); | |||
Guitar1_St1_Voice_2.draw(ctx, Guitar1St1); | |||
const Guitar1St2 = new Stave(Guitar1St1.width + Guitar1St1.x, Guitar1St1.y, nStaveWidth).setContext(ctx); | const Guitar1St2 = new Stave(Guitar1St1.width + Guitar1St1.x, Guitar1St1.y, nStaveWidth).setContext(ctx); |
2024年4月11日 (木) 22:51時点における版
VexFlow 使い方に戻る。
概要
コードフォームをタブ譜に載せるという手法もありまして、コードが一小節で2個種類くらいしか無いような曲で見られる描画方法です。その場合、五線譜には同一コード用の音符を使ってリズムだけをハタ棒とハタで表現します。
タブ譜 コードフォーム
コードは以下のとおりです。
<div id="yonet202403Mid_Output01"></div>
<script>
</script>
VexFlow 使い方に戻る。