Pyrex and numarray

Simon Burton simonb at NOTTHISBIT.webone.com.au
Tue Jan 20 18:25:24 EST 2004


On Tue, 20 Jan 2004 13:48:42 +0100, Marco Bubke wrote:

> thx
> 
> but I need to extract the array to a float*.
> 
> I do NA_OFFSETDATA(NA_InputArray(odata, tFloat64, C_ARRAY)) but this isn't
> working because Pyrex says he can't storage it. There is a unknown size. I
> only need the pointer tp a C array of floats. Thats all.
> 
> ragards
> 
> Marco

Use a variable?

cdef float* data
array = NA_InputArray( array, natype, C_ARRAY )
data = <float *>NA_OFFSETDATA(array)

Simon.




More information about the Python-list mailing list