diff options
author | Aleksey Lim <alsroot@member.fsf.org> | 2008-12-19 00:24:50 (GMT) |
---|---|---|
committer | Aleksey Lim <alsroot@member.fsf.org> | 2008-12-19 23:50:57 (GMT) |
commit | df75dd3b08c5ae87cc0c9d43870a5a73467eeb0f (patch) | |
tree | 877c8d81c47c71a38b824ca3f73c69edc7b5e783 /common/Util/InstrumentDB.py | |
parent | 9bb74bd2bb85cb5fc51f81b6f28e4291c3cdf286 (diff) |
add kitStage member to Instrument class; refactor code to use .kit and .kitStage instead of .name parsing
Diffstat (limited to 'common/Util/InstrumentDB.py')
-rw-r--r-- | common/Util/InstrumentDB.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/common/Util/InstrumentDB.py b/common/Util/InstrumentDB.py index 36a7a84..68928a5 100644 --- a/common/Util/InstrumentDB.py +++ b/common/Util/InstrumentDB.py @@ -8,6 +8,7 @@ import os class Instrument: def __init__(self, id): self.instrumentId = id + self.kitStage = False # build an Instrument instance from argument list def loadFromArgs( self, name, csoundInstrumentId, register, loopStart, @@ -54,10 +55,11 @@ class InstrumentDB: # TEMP? add instrument from args def addInstrumentFromArgs( self, name, csoundInstrumentId, register, loopStart, - loopEnd, crossDur, ampScale, kit, wav, img, category ): + loopEnd, crossDur, ampScale, kit, wav, img, category, kitStage = False ): i = Instrument(len(self.inst)) self.inst += [ i ] i.loadFromArgs( name, csoundInstrumentId, register, loopStart, loopEnd, crossDur, ampScale, kit, wav, img, category ) + i.kitStage = kitStage self.instNamed[ i.name ] = i self.instId[i.instrumentId] = i |