LOCueManager.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046 #import <Cocoa/Cocoa.h>
00047
00048 @class LOLightCue;
00049 @class LOScene;
00050 @class LOTimedDiplessCrossFadeProvider;
00051 @class LOTimingThread;
00052
00053 #define LOCueManagerGoDidBeginNotification @"LOCueManagerGoDidBeginNotification"
00054 #define LOCueManagerGoDidCompleteNotification @"LOCueManagerGoDidCompleteNotification"
00055 #define LOCueManagerDidAddCueNotification @"LOCueManagerDidAddCueNotification"
00056 #define LOCueManagerDidResetNotification @"LOCueManagerDidResetNotification"
00057 #define LOCueManagerDidAddManagerNotification @"LOCueManagerDidAddManagerNotification"
00058 #define LOCueManagerDidRenumberNotification @"LOCueManagerDidRenumberNotification"
00059 #define LOCueManagerDidRemoveCueNotification @"LOCueManagerDidRemoveCueNotification"
00060 #define LOCueManagerDidRemoveCueManager @"LOCueManagerDidRemoveCueManager"
00061 #define LOCueManagerDidRename @"LOCueManagerDidRename"
00062
00063
00064 #define CUE_NUMBER_INCREMENT 10
00065
00066
00076 @interface LOCueManager : NSObject
00077 {
00078 NSString *name;
00079 NSMutableDictionary *cues;
00080 NSArray *sortedKeys;
00081 float nextCueNumber;
00082 BOOL isTracking;
00083
00084 LOScene *emptyScene;
00085 LOTimedDiplessCrossFadeProvider *provider;
00086 LOLightCue *currentCue;
00087
00088 NSTimer *followTimer;
00089 LOTimingThread *timingThread;
00090 }
00091
00092
00103 - (id)initWithName:(NSString *)aName;
00104
00105
00115 + (LOCueManager *)defaultManager;
00116
00117
00128 + (LOCueManager *)managerForName:(NSString *)theName;
00129
00130
00138 + (LOCueManager *)managerAtIndex:(unsigned)index;
00139
00140
00149 + (NSArray *)managers;
00150
00151
00157 + (unsigned)count;
00158
00159
00168 + (NSArray *)managerNames;
00169
00170
00177 + (unsigned)indexOfManager:(LOCueManager *)cueManager;
00178
00179
00187 + (void)removeManager:(LOCueManager *)cueManager;
00188
00189
00197 - (NSString *)name;
00198
00199
00209 - (void)setName:(NSString *)aName;
00210
00211
00222 - (unsigned)index;
00223
00224
00240 - (NSXMLElement *)XML;
00241
00242
00257 - (BOOL)addCue:(LOLightCue *)theCue;
00258
00259
00268 - (void)removeCue:(LOLightCue *)theCue;
00269
00270
00278 - (LOLightCue *)cueForNumber:(float)cueNumber;
00279
00280
00286 - (BOOL)cueExistsForNumber:(float)cueNumber;
00287
00288
00297 - (BOOL)updateCueNumber:(LOLightCue *)theCue;
00298
00299
00305 - (void)autoNumber;
00306
00307
00315 - (unsigned)count;
00316
00317
00323 - (NSArray *)cueList;
00324
00325
00336 - (LOLightCue *)cueAfterCue:(LOLightCue *)aCue;
00337
00338
00349 - (LOLightCue *)cueBeforeCue:(LOLightCue *)aCue;
00350
00351
00359 - (BOOL)isTracking;
00360
00361
00374 - (void)setTracking:(BOOL)tracking;
00375
00376
00387 - (LOScene *)sceneForCue:(LOLightCue *)aCue;
00388
00389
00399 - (unsigned char)master;
00400
00401
00411 - (void)setMaster:(unsigned char)level;
00412
00413
00424 - (LOLightCue *)currentCue;
00425
00426
00441 - (void)go:(LOLightCue *)nextCue;
00442
00443
00456 - (void)go;
00457
00458
00473 - (void)snap:(LOLightCue *)nextCue;
00474
00475
00488 - (void)snap;
00489
00490
00498 - (BOOL)isFading;
00499
00500
00510 - (void)reset;
00511
00512
00521 + (void)resetAll;
00522
00523
00537 - (BOOL)loadConfigurationFromXML:(NSXMLElement *)XMLElement;
00538
00539 @end
00540
00541
00542 int floatSort(id num1, id num2, void *context);
00543
00544
00545
00546
00547
00548
00549
00550