Re: How do I return a 2d array in a system routine? [message #62554] |
Mon, 15 September 2008 10:46 |
Karl[1]
Messages: 79 Registered: October 2005
|
Member |
|
|
On Sep 15, 4:25 am, "hotplainr...@gmail.com" <hotplainr...@gmail.com>
wrote:
> I have been using cublas_sgemm.pro to call a C function
> IDL_CUBLAS_SGEMM() which is LINKIMAGE'd into IDL.
>
> Now, I'd like to reduce it to IDL_CUBLAS_SGEMM only. How do I create
> an IDL_VPTR and IDL_VARIABLE to return the result which is a 2D array.
>
> I find it hard to understand IDL's documentation in returning
> variables e.g. usage of IDL_MakeTempArray() in the Example: A Complete
> Numerical Routine Example (FZ_ROOTS2)
>
> char *IDL_MakeTempArray(int type, int n_dim, IDL_MEMINT dim[],
> int init, IDL_VPTR *var)
>
> How do I create IDL_MEMINT?
>
> Excuse my Bush-like IQ
>
> Zaki
IDL_MEMINT should be defined in idl_export.h
It is an integer that is big enough in size to contain a number
representing the largest possible memory allocation. On most 32-bit
architectures, this is an int. On most 64-bit architectures, this in
an int64.
|
|
|