Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Sharing a context between cocoa and c++ and working with images



Hello all,

I would like to lay a Cocoa GUI over a C++ library that uses OpenGL to do image processing.

I was wondering if it is possible to use the OpenGL context that is created in an NSOpenGLView to provide
access to OpenGL for a c++ based backend? I have been using GLUT to create my context and then
running the c++ code and would like to use cocoa instead of GLUT. Is this possible? If so, I would
appreciate any ideas as to the best way to do this.


Additionally, I have been wondering how to deal with passing the image data between the cocoa code and the
c++ code. I would like to use OSX to open input images and then pass the pixel data as pointers
to the c++ code. So the question is: What the best way to load images in OSX, if the main purpose is to just
determine the extents of the images and then get a pointer to the pixel data. I've looked at NSImage, CIImage,
CGImage and googled a little, but I've not got far. I would appreciate it if someone could point me in the right
direction. Thanks.


Brian



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Mac-opengl mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/mac-opengl/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.