Question

I am writing my own Quartz Composer plugin and I would like to load GLSL shaders, textures, etc. from my QC plugin's bundle. The problem is that it appears that I am getting my loading application's (the QC runtime app) bundle instead. I tried iterating through all of my bundles but this didn't seem to work either.

Is there any easy way to access my QC bundle directly?

Was it helpful?

Solution

[NSBundle mainBundle] gives you the application bundle, not the plugin bundle.

From within a plugin's class, you could do this to get the plugin's bundle:

NSBundle *thisBundle = [NSBundle bundleForClass:[self class]];
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top