In the same forum I mentioned a mix programming topic. This is sorted out. In the next step I would like to call a function in the C program. In oder to do so I need passing a Fortran user defined type as struct to the C subroutine. Only the standard types is explained in the documentaion under Win32 Platform → Mixed language programming. Or at least fill the components of the struct.
A very simple example will help me to sort this out. Especially the how to handle the pointers :!:
For the sake of completeness I provide the C header-file with the struct definition: struct triangulateio { REAL pointlist; / In / out */ REAL pointattributelist; / In / out */ int pointmarkerlist; / In / out / int numberofpoints; / In / out / int numberofpointattributes; / In / out */
int *trianglelist; /* In / out */
REAL *triangleattributelist; /* In / out */
REAL *trianglearealist; /* In only */
int *neighborlist; /* Out only */
int numberoftriangles; /* In / out */
int numberofcorners; /* In / out */
int numberoftriangleattributes; /* In / out */
int *segmentlist; /* In / out */
int *segmentmarkerlist; /* In / out */
int numberofsegments; /* In / out */
REAL *holelist; /* In / pointer to array copied out */
int numberofholes; /* In / copied out */
REAL *regionlist; /* In / pointer to array copied out */
int numberofregions; /* In / copied out */
int *edgelist; /* Out only */
int *edgemarkerlist; /* Not used with Voronoi diagram; out only */
REAL *normlist; /* Used only with Voronoi diagram; out only */
int numberofedges; /* Out only */
};
#ifdef ANSI_DECLARATORS
void triangulate(char *, struct triangulateio *, struct triangulateio *,
struct triangulateio *);
void trifree(VOID *memptr);
#else /* not ANSI_DECLARATORS */
void triangulate();
void trifree();
#endif /* not ANSI_DECLARATORS */