michael ferraro wrote:
> I need to eliminate any copies of a PixMaps used
> by  a Quicktime Movie that I am texture mapping
> with OpenGL.  I have built an extension in "C" but
> I am a bit unclear as to how to "circumvent" the the
> copy done by Py_BuildValue.
> 
> I was wondering if any one has any experience
> or advice on how to approach this. Is the Buffer
> Object/API the right way to go? or is there
> another approach

What form is the data in in your c code? A pointer to simple C array?

If so, the buffer object could work, or you could build a NumPy array. I 
think PyOpenGL can work with them natively. If you want to got hat 
route, the situation is pretty confusing as there are now three (count 
'em three!) implementations, Numeric, numarray, and the new SciPy.base. 
I'd go with whatever PyOpenGL supports, or, if you have the option, and 
can tolerate beta code, Scipy.base. With any luck it will be the next 
generation NumPy.

http://numeric.scipy.org/

SciPy.base has also introduced  a new "array protocol/interface", which 
I think has been back ported to both Numeric and numarray:

http://numeric.scipy.org/array_interface.html

This was designed with just this kind of use in mind.

-Chris



-- 
Christopher Barker, Ph.D.
Oceanographer
                                                
NOAA/OR&R/HAZMAT         (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

[EMAIL PROTECTED]
_______________________________________________
Pythonmac-SIG maillist  -  Pythonmac-SIG@python.org
http://mail.python.org/mailman/listinfo/pythonmac-sig

Reply via email to