Another option that I have done in the past with a web -> image plugin, is to alloc a brand new window manually at init, and then have a boolean input port that triggers the window to be made key and ordered front. This allowed me to get around my limitations of the setting info pane not being made available in a QC powered app, and was able to set it and fiddle with it outside of executeAtTime.

Okay. And how does your window get disposed of?

Your Plugin never receives a "-close" or "-finalize" call after the - init" phase of the QCPlugin to tell it it's shutting down.

So is it leaking a window each time it's used?


We've already been over this: - (void) stopExecution: (id<QCPlugInContext>)context; is called when QC is shutting down (at least the context the patch is being used in). Whether or not vade's closing the window is at his own peril, but leaking is not implied nor required. This is _The_ time to release any resources in use by your patch, as the patch can't possibly get reused once this method is called (the graph is getting deallocated, any parameter views are already closed, etc).

- (void) stopExecution:(id<QCPlugInContext>)context; is called exactly once (per patch instance), when the patch is going out of commission. - (void) startExecution:(id<QCPlugInContext>)context; is called exactly once (per patch instance), when the patch is added to a particular composition.

For plugin-level resources (not per-patch), there isn't an explicit cleanup method though cleanup is still possible through the use of destructors if the bundle gets unloaded -- this isn't as common as plugins usually aren't unloaded (NSBundle unloading in general wasn't supported until Leopard), and probably isn't helpful in this context.

--
[ christopher wright ]
[email protected]
http://kineme.net/

Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartzcomposer-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to