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

Re: passing structures to CALL_EXTERNAL

Jeremy Kepner (jvkepner@muse.Princeton.EDU) writes:

>   I would like to pass an IDL structure to a function written
> in C via CALL_EXTERNAL.  Does anybody know how to do this.

I like to think of CALL_EXTERNAL as LINKIMAGE-LITE. It is
a greatly simplified interface to something that can be
quite a complex operation. As a simplified interface, there
are some things you can't do that you can do in, for example,
LINKIMAGE. One of these things is you can't pass structures

Now, having said that, I know of people who HAVE passed
structures using CALL_EXTERNAL. But these people knew
*exactly* what they were doing. But for most of us, if
we knew exactly what we were doing, we would know enough
to be using LINKIMAGE in the first place. 



P.S. I've known plenty of people who weren't too proud
to deconstruct their structure on one side and reconstruct
it on the other, but we all do what we have to do. :-)

David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155