vvopensource
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Properties Macros Groups Pages
VVMIDIMessage.h
1 
2 #import <Cocoa/Cocoa.h>
3 #import <CoreMIDI/CoreMIDI.h>
4 
5 
6 
7 @interface VVMIDIMessage : NSObject <NSCopying> {
8  Byte type;
9  Byte channel;
10  Byte data1; // usually controller/note #
11  Byte data2; // usually controller/note value. if 14-bit, the MSB ("coarse")
12  Byte data3; // usually -1. if 14-bit, the LSB ("fine").
13  // array of NSNumbers, or nil if this isn't a sysex message
14  // DOES NOT CONTAIN SYSEX START/STOP STATUS BYTES (0xF0 / 0xF7)
15  NSMutableArray *sysexArray;
16  uint64_t timestamp; // timestamp that message should be sent. if it's 0 we'll just use mach_absolute_time
17 }
18 
19 + (id) createWithType:(Byte)t channel:(Byte)c;
20 + (id) createWithType:(Byte)t channel:(Byte)c timestamp:(uint64_t)time;
21 + (id) createWithSysexArray:(NSMutableArray *)s;
22 + (id) createWithSysexArray:(NSMutableArray *)s timestamp:(uint64_t)time;
23 + (id) createFromVals:(Byte)t :(Byte)c :(Byte)d1 :(Byte)d2;
24 + (id) createFromVals:(Byte)t :(Byte)c :(Byte)d1 :(Byte)d2 :(Byte)d3;
25 + (id) createFromVals:(Byte)t :(Byte)c :(Byte)d1 :(Byte)d2 :(Byte)d3 :(uint64_t)t;
26 
27 - (id) initWithType:(Byte)t channel:(Byte)c;
28 - (id) initWithType:(Byte)t channel:(Byte)c timestamp:(uint64_t)time;
29 - (id) initWithSysexArray:(NSMutableArray *)s;
30 - (id) initWithSysexArray:(NSMutableArray *)s timestamp:(uint64_t)time;
31 - (id) initFromVals:(Byte)t :(Byte)c :(Byte)d1 :(Byte)d2;
32 - (id) initFromVals:(Byte)t :(Byte)c :(Byte)d1 :(Byte)d2 :(Byte)d3;
33 - (id) initFromVals:(Byte)t :(Byte)c :(Byte)d1 :(Byte)d2 :(Byte)d3 :(uint64_t)t;
34 
35 - (NSString *) description;
36 - (NSString *) lengthyDescription;
37 - (BOOL) isFullFrameSMPTE;
38 
39 - (Byte) type;
40 - (void) setType:(Byte)newType;
41 - (Byte) channel;
42 - (void) setData1:(Byte)newData;
43 - (Byte) data1;
44 - (void) setData2:(Byte)newData;
45 - (Byte) data2;
46 - (void) setData3:(Byte)newData;
47 - (Byte) data3;
48 - (NSMutableArray *) sysexArray;
49 - (void) setTimestamp:(uint64_t)newTimestamp;
50 - (uint64_t) timestamp;
51 - (double) doubleValue;
52 
53 @end