Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Mockup & CodeGen, iPhone & iPad
($9.99)

Make your own iPhone apps
and run them live!
(free)

Manu
($0.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 10-15-2008, 12:13 PM   #1 (permalink)
skooby
New Member
 
Join Date: Oct 2008
Posts: 1
Default Platform Independent layer between C++ and Objective C

I have my platform independent layer that I have done most of my coding in and want to port that to the iphone to offer a multi-platform environment. The difficulty I am having is sharing some of the objects between Objective C and C++.

For instance I have an abstracted platform independent layer like :
void VideoServices:: DrawPoly (...)
{
ExternDrawPoly_OPENGLES();
}

Which I would like to call the Objective C stuff for the lower implementation.

So in my ExternDrawPoly_OPENGLES() I call drawPoly() which is located in my .mm EAGLView.mm area.

Inside of my ExternDrawPoly(...) in EAGLView.mm I want to reference the EAGLView implementation object but it gives me a warning and then it crashes when the code is being run.

I imagine that my difficulty is getting a pointer to the EAGLView object, but not quiet sure how to get it.

Any help would be appreciated.
skooby is offline   Reply With Quote
 

» Advertisements
» Stats
Members: 158,801
Threads: 89,205
Posts: 380,608
Top Poster: BrianSlick (7,129)
Welcome to our newest member, ronward10
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 01:02 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.