Getting double* from NumPy array?
Ted Drain
ted.drain at jpl.nasa.gov
Mon Jun 26 16:23:50 EDT 2000
I have some existing C/C++ code that can accept a double array ( int len,
and double* ptr) to do some processing. I want to allow users to create
arrays in python using NumPy and then provide an interface to pass these
arrays to my C/C++ code.
Assuming a 1-dimensional NumPy array, is there an easy way to extract a
pointer to a double and length from the python object? The C/C++ isn't
going to change the object so I'd prefer not to make a copy of it.
Thanks
Ted
--
Ted Drain Jet Propulsion Laboratory Ted.Drain at jpl.nasa.gov
More information about the Python-list
mailing list