Hi Aras, I'm working with your Graphics Demos example project. First of all, thanks for the great example! Really helps me a lot. I was able to run it on a Mac, but couldn't get it to work on an iPhone. What changes are required to make it work on an iPhone? Thanks, Matan

Matan Rubin

If you mean the native C++ plugin example project on bitbucket (https://bitbucket.org/Unity-Technologies/graphicsdemos/src/tip/NativeRenderingPlugin/), then short answer is, "I don't know".

I have never done a native code Unity plugin for iOS. I do know that iOS has a slightly different build pipeline, i.e. the way people do "plugins" is typically by having them as C++ or Objective C source files, which are packaged up into the final Xcode project that Unity builds. Which is then compiled in Xcode, and so the plugin is linked together with the Unity engine static library and your script code to produce the final executable.

So my guess would be that the plugin sources need to be added to the final Xcode project, or the Unity project itself and somehow marked up as "hey this is plugin source for iOS". Maybe the documentation helps? https://docs.unity3d.com/Manual/PluginsForIOS.html

View more

Ask @aras_pr:

About Aras Pranckevičius:

Graphics programmer and code plumber at Unity

Kaunas, Lithuania


#graphics #programming