[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problems with IDL call_external to C shared object

Mark Rivers wrote:
> I've done a lot of this, and it's not that hard, don't give up!
> Here are some tricks:
> - All arrays which need to be passed between IDL and C must be allocated in
> IDL, as J.D. Smith said.  This includes both arrays being passed from IDL to
> C and from C back to IDL.  Sometimes this requires an initial call to the C
> code to return the array sizes which IDL will allocate, if the array sizes
> are not known to IDL beforehand.

Alternatively, you can use the LINKIMAGE or DLM interface where the C
can create any IDL variable required. Albeit at the expense of a greater
learning curve.

Nigel Wade, System Administrator, Space Plasma Physics Group,
            University of Leicester, Leicester, LE1 7RH, UK 
E-mail :    nmw@ion.le.ac.uk 
Phone :     +44 (0)116 2523568, Fax : +44 (0)116 2523555