What's new

Best way to get typ of a played chord?

Dynamitec

Senior Member
Thank you very much Nils!

One question

```chord := sh_left(notes[0], 0) + ...
`````````````sh_left(notes[1], 4) + ...
`````````````sh_left(notes[2], Cool + ...
`````````````sh_left(notes[3], 12)

There is a smiley...how is this line supposed to be? 0,4,8,12,16,20,...?
8 Notes are enough for me :)

Another question: so how could i detect inversions of chords? If the skripts detect always the chord independet from the root note and the second note?
 
Sorry, i found out i don't need to detect inversions urgently.
But anyway: maybe someone here would be interested how i would work... :)
 
Another question: so how could i detect inversions of chords? If the skripts detect always the chord independet from the root note and the second note?
The script I posted works irrespectively of inversions of chords since it uses the sort function in encode_chord. I tried to extend the code above to something that is actually possible to use. Please check out the https://nilsliberg.se/ksp/scripts/chords_demo_script.html (extended version) which is a complete script. It detects major, minor, sus2, 7 and maj7 chords in all keys and displays a message describing the chord you play.

Inversions are a bit tricky because sometimes the chord description is determined based on the inversion, eg. Csus4 and Fsus2 has the same notes so in that case one wants to choose based on the lowest key.

Cheers,
Nils
 
I learn something new here every day!!

I'm now getting a better understanding of the bitwise .and. statements. I don't fullly understand it... but it's getting there :smile:

Thanks for the examples Nils.

T
 
Top Bottom