From 789e7c10bc8765d498ba9f1e4c3eac35b64b41e7 Mon Sep 17 00:00:00 2001 From: Houyhnhnm Date: Thu, 7 Jun 2018 14:16:34 +0200 Subject: render rhythms to score --- cadence.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'cadence.py') diff --git a/cadence.py b/cadence.py index b84c6c0..8b7b585 100644 --- a/cadence.py +++ b/cadence.py @@ -20,15 +20,15 @@ Cadence class Cadence(object): """a musical morpheme bundling rhythmic, gestural and harmonic features""" - def __init__(self, footprint=None, function=None, path=None): - self.footprint = footprint + def __init__(self, ligature=None, function=None, path=None): + self.ligature = ligature self.function = function self.path = path # string represention of cadence - note list ? def __str__(self): features = { - 'footprint': self.footprint, + 'ligature': self.ligature, 'function': self.function, 'path': self.path, } @@ -37,15 +37,15 @@ class Cadence(object): @property def features(self): features = { - 'footprint': self.footprint, + 'ligature': self.ligature, 'function': self.function, 'path': self.path, } return features def update(featureDict): - if 'footprint' in featureDict: - self.footprint = featureDict['footprint'] + if 'ligature' in featureDict: + self.ligature = featureDict['ligature'] if 'function' in featureDict: self.function.update(featureDict['function']) if 'path' in featureDict: @@ -53,7 +53,7 @@ class Cadence(object): def print(self): features = { - 'footprint': self.footprint, + 'ligature': self.ligature, 'function': self.function, 'path': self.path, } @@ -63,7 +63,7 @@ class Cadence(object): # example cad = Cadence() -cad.footprint = [{ +cad.ligature = [{ 'span': 2, 'gait': 'double', # Gait.double or Gait['double']... 'foot': [-1/2, -1/4, 0, 1/2], -- cgit v1.2.3