Vuo  2.0.2
VuoRunnerCocoa.h
Go to the documentation of this file.
1 
10 #pragma once
11 
12 #if defined(__OBJC__) || defined(DOXYGEN)
13 
14 #ifdef NS_RETURNS_INNER_POINTER
15  #undef NS_RETURNS_INNER_POINTER
16 #endif
17 #ifndef NS_RETURNS_INNER_POINTER
20 #define NS_RETURNS_INNER_POINTER
21 #endif
22 #import <Cocoa/Cocoa.h>
23 #undef NS_RETURNS_INNER_POINTER
24 
26 #define VuoRunner void
27 #define VuoCompiler void
28 #define VuoComposition void
29 #define VuoProtocol void
30 struct _VuoImage;
31 typedef struct _VuoImage * VuoImage;
32 typedef struct json_object json_object;
34 
42 @interface VuoRunnerCocoa : NSObject
43 
49 @property (readonly) NSString *compositionName;
50 
56 @property (readonly) NSString *compositionDescription;
57 
63 @property (readonly) NSString *compositionCopyright;
64 
65 + (void)setGlobalRootContext:(CGLContextObj)context;
66 + (void)prepareForFastBuild;
67 
68 - (NSArray *)inputPorts;
69 - (NSArray *)outputPorts;
70 - (NSDictionary *)detailsForPort:(NSString *)portName;
72 - (BOOL)setInputValuesWithPropertyList:(id)propertyList;
73 - (BOOL)setInputValues:(NSDictionary *)namesAndValues;
74 - (BOOL)setInputJSON:(NSDictionary *)namesAndJSON;
75 
76 - (id)valueForOutputPort:(NSString *)portName;
77 - (GLuint)glTextureWithTarget:(GLuint)target forOutputPort:(NSString *)portName outputPixelsWide:(NSUInteger *)outputPixelsWide pixelsHigh:(NSUInteger *)outputPixelsHigh;
78 - (GLuint)glTextureFromProvider:(GLuint (^)(NSUInteger pixelsWide, NSUInteger pixelsHigh))provider forOutputPort:(NSString *)portName outputPixelsWide:(NSUInteger *)outputPixelsWide pixelsHigh:(NSUInteger *)outputPixelsHigh ioSurface:(IOSurfaceRef *)outputIOSurface;
79 @end
80 
85 + (BOOL)canOpenComposition:(NSURL *)compositionURL;
86 + (BOOL)canOpenCompositionString:(NSString *)compositionString;
87 - (id)initWithComposition:(NSURL *)compositionURL;
88 - (id)initWithCompositionString:(NSString *)compositionString name:(NSString *)name sourcePath:(NSString *)sourcePath;
89 - (NSImage *)filterNSImage:(NSImage *)image atTime:(NSTimeInterval)time;
90 - (GLuint)filterGLTexture:(GLuint)textureName target:(GLuint)target pixelsWide:(NSUInteger)pixelsWide pixelsHigh:(NSUInteger)pixelsHigh atTime:(NSTimeInterval)time outputPixelsWide:(NSUInteger *)outputPixelsWide pixelsHigh:(NSUInteger *)outputPixelsHigh;
91 - (GLuint)filterGLTexture:(GLuint)textureName target:(GLuint)target pixelsWide:(NSUInteger)pixelsWide pixelsHigh:(NSUInteger)pixelsHigh atTime:(NSTimeInterval)time withTextureProvider:(GLuint (^)(NSUInteger pixelsWide, NSUInteger pixelsHigh))provider outputPixelsWide:(NSUInteger *)outputPixelsWide pixelsHigh:(NSUInteger *)outputPixelsHigh ioSurface:(IOSurfaceRef *)outputIOSurface;
92 @end
93 
98 + (BOOL)canOpenComposition:(NSURL *)compositionURL;
99 + (BOOL)canOpenCompositionString:(NSString *)compositionString;
100 - (id)initWithComposition:(NSURL *)compositionURL;
101 - (id)initWithCompositionString:(NSString *)compositionString name:(NSString *)name sourcePath:(NSString *)sourcePath;
102 - (NSImage *)generateNSImageWithSuggestedPixelsWide:(NSUInteger)suggestedPixelsWide pixelsHigh:(NSUInteger)suggestedPixelsHigh atTime:(NSTimeInterval)time;
103 - (GLuint)generateGLTextureWithTarget:(GLuint)target suggestedPixelsWide:(NSUInteger)suggestedPixelsWide pixelsHigh:(NSUInteger)suggestedPixelsHigh atTime:(NSTimeInterval)time outputPixelsWide:(NSUInteger *)outputPixelsWide pixelsHigh:(NSUInteger *)outputPixelsHigh;
104 - (GLuint)generateGLTextureWithProvider:(GLuint (^)(NSUInteger pixelsWide, NSUInteger pixelsHigh))provider suggestedPixelsWide:(NSUInteger)pixelsWide pixelsHigh:(NSUInteger)pixelsHigh atTime:(NSTimeInterval)time outputPixelsWide:(NSUInteger *)outputPixelsWide pixelsHigh:(NSUInteger *)outputPixelsHigh ioSurface:(IOSurfaceRef *)outputIOSurface;
105 - (VuoImage)generateVuoImageWithSuggestedPixelsWide:(NSUInteger)suggestedPixelsWide pixelsHigh:(NSUInteger)suggestedPixelsHigh atTime:(NSTimeInterval)time;
106 @end
107 
108 #undef VuoRunner
109 #undef VuoCompiler
110 #undef VuoComposition
111 #undef VuoProtocol
112 
113 #endif // defined(__OBJC__) || defined(DOXYGEN)