ShiVa3D
iOS Plugin
ShiVa Plugin DevelopmentiOS Plugin
by eragon » 04 Nov 2011, 10:46
Hi all,
How to include an objective c header into shiva plugin xcode project?
I have created a method in objective C, and would like to call it inside my
C++ file. I've change the C++ file to .mm file, change the objc compiler into
cpp.objcpp, but then when I try to build it, it give me the following error,
"Statement-expressions are allowed only inside functions".
Does it mean that, this is not possible?
Thanks in advance.
How to include an objective c header into shiva plugin xcode project?
I have created a method in objective C, and would like to call it inside my
C++ file. I've change the C++ file to .mm file, change the objc compiler into
cpp.objcpp, but then when I try to build it, it give me the following error,
"Statement-expressions are allowed only inside functions".
Does it mean that, this is not possible?
Thanks in advance.
- eragon
- Fresh Boarder

- Posts: 9
Re: iOS Plugin
by NiCoX » 04 Nov 2011, 11:22
Hi,
You need to create a "proxy" between C++ and ObjC. Here is a sample:
You need to create a "proxy" between C++ and ObjC. Here is a sample:
- Code: Select all
http://developer.stonetrip.com/Download/Misc/com.stonetrip.nativemessagebox.7z
-

NiCoX - Platinum Boarder

- Posts: 5626
- Location: France
Re: iOS Plugin
by eragon » 04 Nov 2011, 11:47
Thanks for the reference
Helps a lot, I see how
you link them together.
But, just to make sure, we no need to include "NativeFunctions_iOS.mm" into
our plugin project right ?
Thanks in advance.
Edit: It seem like I fixed the issues
Thanks for reply
you link them together.
But, just to make sure, we no need to include "NativeFunctions_iOS.mm" into
our plugin project right ?
Thanks in advance.
Edit: It seem like I fixed the issues
- eragon
- Fresh Boarder

- Posts: 9
3 posts
• Page 1 of 1