-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathchord_formation.dot
More file actions
135 lines (118 loc) · 6.23 KB
/
chord_formation.dot
File metadata and controls
135 lines (118 loc) · 6.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
digraph chord_formation {
rankdir=TB
bgcolor="transparent"
pad=0.4
nodesep=0.3
ranksep=0.45
node [fontname="Helvetica"]
edge [fontname="Helvetica"]
// --- Row 1: Input fields ---
root [
label=<<FONT POINT-SIZE="22" COLOR="#333333"><B>C</B></FONT><BR/><FONT POINT-SIZE="14" COLOR="#888888">root</FONT>>
shape=box style="filled,rounded"
fillcolor="#e0e0e0" color="#bbbbbb"
penwidth=2 margin="0.15,0.08"
]
pattern [
label=<<FONT POINT-SIZE="22" COLOR="#333333"><B>[0,2,3,5,7,8,10]</B></FONT><BR/><FONT POINT-SIZE="14" COLOR="#888888">pattern (minor)</FONT>>
shape=box style="filled,rounded"
fillcolor="#e0e0e0" color="#bbbbbb"
penwidth=2 margin="0.15,0.08"
]
degrees [
label=<<FONT POINT-SIZE="22" COLOR="#333333"><B>[1, 3, 5]</B></FONT><BR/><FONT POINT-SIZE="14" COLOR="#888888">degrees</FONT>>
shape=box style="filled,rounded"
fillcolor="#e0e0e0" color="#bbbbbb"
penwidth=2 margin="0.15,0.08"
]
adjustments [
label=<<FONT POINT-SIZE="22" COLOR="#333333"><B>[♮, ♮, ♭]</B></FONT><BR/><FONT POINT-SIZE="14" COLOR="#888888">adjustments</FONT>>
shape=box style="filled,rounded"
fillcolor="#e0e0e0" color="#bbbbbb"
penwidth=2 margin="0.15,0.08"
]
// Force left-to-right ordering in top row
{ rank=same; root -> pattern -> degrees -> adjustments [style=invis]; }
// --- Row 2: Generated scale with brace above ---
scale [
shape=none margin=0
label=<
<TABLE BORDER="0" CELLBORDER="0" CELLSPACING="0" CELLPADDING="0">
<TR>
<TD COLSPAN="7">
<TABLE BORDER="0" CELLBORDER="0" CELLSPACING="0" CELLPADDING="0">
<TR>
<TD WIDTH="229" HEIGHT="8" SIDES="RB" BORDER="2" COLOR="#999999"></TD>
<TD PORT="brace" WIDTH="2" HEIGHT="8"></TD>
<TD WIDTH="229" HEIGHT="8" SIDES="LB" BORDER="2" COLOR="#999999"></TD>
</TR>
</TABLE>
</TD>
</TR>
<TR><TD COLSPAN="7" HEIGHT="6"></TD></TR>
<TR>
<TD PORT="c" WIDTH="65" HEIGHT="50" FIXEDSIZE="TRUE" BGCOLOR="#b8d4f0" BORDER="2" COLOR="#7a9fd4"><FONT POINT-SIZE="12" COLOR="#6688bb">1</FONT><BR/><FONT POINT-SIZE="20" COLOR="#2c3e6b"><B>C</B></FONT></TD>
<TD WIDTH="65" HEIGHT="50" FIXEDSIZE="TRUE" BGCOLOR="#f0f0f0" BORDER="2" COLOR="#cccccc"><FONT POINT-SIZE="12" COLOR="#aaaaaa">2</FONT><BR/><FONT POINT-SIZE="20" COLOR="#999999">D</FONT></TD>
<TD WIDTH="65" HEIGHT="50" FIXEDSIZE="TRUE" BGCOLOR="#b8d4f0" BORDER="2" COLOR="#7a9fd4"><FONT POINT-SIZE="12" COLOR="#6688bb">3</FONT><BR/><FONT POINT-SIZE="20" COLOR="#2c3e6b"><B>E♭</B></FONT></TD>
<TD WIDTH="65" HEIGHT="50" FIXEDSIZE="TRUE" BGCOLOR="#f0f0f0" BORDER="2" COLOR="#cccccc"><FONT POINT-SIZE="12" COLOR="#aaaaaa">4</FONT><BR/><FONT POINT-SIZE="20" COLOR="#999999">F</FONT></TD>
<TD WIDTH="65" HEIGHT="50" FIXEDSIZE="TRUE" BGCOLOR="#b8d4f0" BORDER="2" COLOR="#7a9fd4"><FONT POINT-SIZE="12" COLOR="#6688bb">5</FONT><BR/><FONT POINT-SIZE="20" COLOR="#2c3e6b"><B>G</B></FONT></TD>
<TD WIDTH="65" HEIGHT="50" FIXEDSIZE="TRUE" BGCOLOR="#f0f0f0" BORDER="2" COLOR="#cccccc"><FONT POINT-SIZE="12" COLOR="#aaaaaa">6</FONT><BR/><FONT POINT-SIZE="20" COLOR="#999999">A♭</FONT></TD>
<TD WIDTH="65" HEIGHT="50" FIXEDSIZE="TRUE" BGCOLOR="#f0f0f0" BORDER="2" COLOR="#cccccc"><FONT POINT-SIZE="12" COLOR="#aaaaaa">7</FONT><BR/><FONT POINT-SIZE="20" COLOR="#999999">B♭</FONT></TD>
</TR>
</TABLE>
>
]
scale_label [
label=<<FONT POINT-SIZE="14" COLOR="#888888"><I>scale from root + pattern</I></FONT>>
shape=plaintext
]
// --- Row 3: Selected notes before adjustment ---
selected [
shape=none margin=0
label=<
<TABLE BORDER="0" CELLBORDER="2" CELLSPACING="12" CELLPADDING="8">
<TR>
<TD WIDTH="65" HEIGHT="45" FIXEDSIZE="TRUE" BGCOLOR="#b8d4f0" COLOR="#7a9fd4"><FONT POINT-SIZE="20" COLOR="#2c3e6b"><B>C</B></FONT></TD>
<TD WIDTH="65" HEIGHT="45" FIXEDSIZE="TRUE" BGCOLOR="#b8d4f0" COLOR="#7a9fd4"><FONT POINT-SIZE="20" COLOR="#2c3e6b"><B>E♭</B></FONT></TD>
<TD WIDTH="65" HEIGHT="45" FIXEDSIZE="TRUE" BGCOLOR="#b8d4f0" COLOR="#7a9fd4"><FONT POINT-SIZE="20" COLOR="#2c3e6b"><B>G</B></FONT></TD>
</TR>
</TABLE>
>
]
selected_label [
label=<<FONT POINT-SIZE="14" COLOR="#888888"><I>selected by degrees</I></FONT>>
shape=plaintext
]
// --- Row 4: Final chord notes ---
result [
shape=none margin=0
label=<
<TABLE BORDER="0" CELLBORDER="2" CELLSPACING="12" CELLPADDING="8" STYLE="rounded">
<TR>
<TD WIDTH="65" HEIGHT="55" FIXEDSIZE="TRUE" BGCOLOR="#d4eab8" COLOR="#7aaa5a"><FONT POINT-SIZE="20" COLOR="#3a6b2c"><B>C</B></FONT><BR/><FONT POINT-SIZE="12" COLOR="#6a9b5a">♮</FONT></TD>
<TD WIDTH="65" HEIGHT="55" FIXEDSIZE="TRUE" BGCOLOR="#d4eab8" COLOR="#7aaa5a"><FONT POINT-SIZE="20" COLOR="#3a6b2c"><B>E♭</B></FONT><BR/><FONT POINT-SIZE="12" COLOR="#6a9b5a">♮</FONT></TD>
<TD WIDTH="65" HEIGHT="55" FIXEDSIZE="TRUE" BGCOLOR="#d4eab8" COLOR="#7aaa5a"><FONT POINT-SIZE="20" COLOR="#3a6b2c"><B>G♭</B></FONT><BR/><FONT POINT-SIZE="12" COLOR="#6a9b5a">♭</FONT></TD>
</TR>
</TABLE>
>
]
result_label [
label=<<FONT POINT-SIZE="16" COLOR="#3a6b2c"><B>C diminished</B></FONT>>
shape=plaintext
]
// --- Edges ---
root -> scale:c [color="#999999" penwidth=1.5]
pattern -> scale:brace [color="#999999" penwidth=1.5]
degrees -> selected [color="#7a9fd4" penwidth=1.5]
scale -> selected [color="#7a9fd4" penwidth=1.5]
adjustments -> result [color="#7aaa5a" penwidth=1.5]
selected -> result [color="#7aaa5a" penwidth=1.5]
// --- Labels positioned beside their rows ---
{ rank=same; scale; scale_label; }
{ rank=same; selected; selected_label; }
{ rank=same; result; result_label; }
// Invisible edges for label positioning
scale -> scale_label [style=invis]
selected -> selected_label [style=invis]
result -> result_label [style=invis]
}