vvopensource
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Properties Macros Groups Pages
Instance Methods | Properties
ISFGLScene Class Reference

Subclass of GLShaderScene- loads and renders ISF files. More...

#import <ISFGLScene.h>

Inherits GLShaderScene.

Instance Methods

(id) - initWithSharedContext:
 Init an instance of GLScene using the passed shared context.
 
(id) - initWithSharedContext:pixelFormat:sized:
 Init an instance of GLScene using the passed shared context and pixel format. The GLScene will automatically be configured to render at the passed size.
 
(void) - useFile:
 Loads the ISF .fs file at the passed path.
 
(void) - setBuffer:forInputImageKey:
 if an ISF file has an input at the specified key, retains the buffer to be used at that input on the next rendering pass More...
 
(void) - setFilterInputImageBuffer:
 convenience method- if the ISF file is an image filter (which has an explicitly-named image input), this applies the passed buffer to the filter input
 
(VVBuffer *) - bufferForInputImageKey:
 retrieves the current buffer being used at the passed key
 
(void) - setValue:forInputKey:
 applies the passed value to the input with the passed key More...
 
(void) - setNSObjectVal:forInputKey:
 applies the passed value to the input with the passed key More...
 
(NSMutableArray *) - inputsOfType:
 returns an array with all the inputs matching the passed type More...
 
(ISFAttrib *) - attribForInputWithKey:
 returns a ptr to the ISFAttrib instance used by this scene which describes the input at the passed key
 
(VVBuffer *) - allocAndRenderToBufferSized:
 allocates and renders into a buffer/GL texture of the passed size, then returns the buffer
 
(void) - renderToBuffer:sized:renderTime:passDict:
 lower-level rendering method- you have to provide your own buffer, explicitly state the size at which you want to render this scene, give it a render time, and supply an optional dictionary in which the various render passes will be stored More...
 
- Instance Methods inherited from GLScene
(id) - initWithSharedContext:sized:
 Init an instance of GLScene using the passed shared context. The GLScene will automatically be configured to render at the passed size.
 
(id) - initWithSharedContext:pixelFormat:
 Init an instance of GLScene using the passed shared context and pixel format.
 
(VVBuffer *) - allocAndRenderABuffer
 Allocate a VVBuffer of the appropriate size, renders into this buffer, and then return it. Probably the "main" rendering method.
 
(void) - renderInMSAAFBO:colorRB:depthRB:fbo:colorTex:depthTex:target:
 This is the low-level rendering method- if you want to fool around with MSAA or build a leaner interface, you'll probably want to use this. More...
 
(void) - setClearNSColor:
 Set the clear color from the passed NSColor.
 
(void) - setClearColor:
 Set the clear color from the passed array of GLfloats.
 
(void) - setClearColors::::
 Set the clear color from the passed color values.
 

Properties

NSString * filePath
 returns the path of the currently-loaded ISF file
 
NSString * fileName
 returns the name of the currently-loaded ISF file
 
NSString * fileDescription
 returns a string with the description (pulled from the JSON blob) of the ISF file
 
NSString * fileCredits
 returns a string with the credits (pulled from the JSON blob) of the ISF file
 
NSMutableArray * categoryNames
 returns an array with the category names (as NSStrings) of this ISF file. pulled from the JSON blob.
 
MutLockArrayinputs
 returns a MutLockArray (from VVBasics) of ISFAttrib instances, one for each of the inputs
 
MutLockArrayimageInputs
 returns a MutLockArray (from VVBasics) of all the image-type (ISFAT_Image) ISFAttrib instances, one for each input in the currently loaded ISF file
 
- Properties inherited from GLShaderScene
NSString * vertexShaderString
 Set/get the vertex shader string.
 
NSString * fragmentShaderString
 Set/get the fragment shader string.
 
GLenum program
 the (GL) name of the program after the frag shaders have been compiled and linked
 
GLenum vertexShader
 the (GL) name of the vertex shader after it's been compiled
 
GLenum fragmentShader
 the (GL) name of the fragment shader after it's been compiled
 
- Properties inherited from GLScene
NSSize size
 Set the size at which this scene should render.
 
id renderTarget
 Every time this scene renders, the "renderSelector" is called on "renderTarget".
 
SEL renderSelector
 Every time this scene renders, the "renderSelector" is called on "renderTarget". You put your drawing code in the "renderSelector".
 

Additional Inherited Members

- Class Methods inherited from GLScene
(NSMutableArray *) + gpuVendorArray
 Returns an array of the GPUs currently accessible by the renderer accessible being used with this process.
 
(BOOL) + integratedGPUFlag
 Returns a YES if you're using an integrated GPU.
 
(BOOL) + nvidiaGPUFlag
 Returns a YES if you're using an NVIDIA GPU.
 
(GLuint) + glDisplayMaskForAllScreens
 Returns a GL display mask that encompassess all your screens.
 
(NSOpenGLPixelFormat *) + defaultPixelFormat
 Returns a default NSOpenGLPixelFormat instance. If you don't explicitly set a pixel format when creating your instances of GLScene (and its subclasses), this is the pixel format that will be used.
 

Detailed Description

Subclass of GLShaderScene- loads and renders ISF files.

Method Documentation

- (NSMutableArray *) inputsOfType: (ISFAttribValType t

returns an array with all the inputs matching the passed type

Parameters
tthe type of attributes you want returned
- (void) renderToBuffer: (VVBuffer *)  b
sized: (NSSize)  s
renderTime: (double)  t
passDict: (NSMutableDictionary *)  d 

lower-level rendering method- you have to provide your own buffer, explicitly state the size at which you want to render this scene, give it a render time, and supply an optional dictionary in which the various render passes will be stored

Parameters
bthe buffer to render into. it's your responsibility to make sure that thsi is the appropriate type of buffer (should be a texture)
sthe size at which you want the scene to render
tthe time at which you want the scene to render, in seconds
da mutable dictionary, into which the output of the various render passes will be stored
- (void) setBuffer: (VVBuffer *)  b
forInputImageKey: (NSString *)  k 

if an ISF file has an input at the specified key, retains the buffer to be used at that input on the next rendering pass

Parameters
bthe VVBuffer instance you want to send to the ISF file
kan NSString with the name of the image input you want to pass the VVBuffer to
- (void) setNSObjectVal: (id)  n
forInputKey: (NSString *)  k 

applies the passed value to the input with the passed key

Parameters
nthe value you want to pass, as an NSObject of some sort. if it's a color, pass NSColor- if it's a point, pass an NSValue created from an NSPoint- if it's an image, pass a VVBuffer- else, pass an NSNumber.
kthe key of the input you want to pass the value to.
- (void) setValue: (ISFAttribVal n
forInputKey: (NSString *)  k 

applies the passed value to the input with the passed key

Parameters
nthe value you want to pass, as an ISFAttribVal union
kthe key of the input you want to pass the value to

The documentation for this class was generated from the following files: