Commit 2a68cc15 authored by whitlocb's avatar whitlocb

I made some enhancements that make is possible to create simulations that...

I made some enhancements that make is possible to create simulations that statically link the libsim runtime (and plugins, etc) instead of loading it at runtime.
 


git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@16526 18c085ea-50e0-402c-830e-de6fd14e8384
parent 12d16ea8
......@@ -140,8 +140,8 @@ enhancements and bug-fixes that were added to this release.</p>
<li>VisIt was ported to an enhanced version of VTK 5.8.0.</li>
<li>There is now an "aprun" option for launching parallel jobs.</li>
<li>Queries can now have custom widgets added to the QueryWindow, allowing more useful controls of options.</li>
<li></li>
<li></li>
<li>VisIt's static build has been fixed.</li>
<li>Simulations that link to libsim can now also link in the rest of VisIt's libraries statically when VisIt has been built statically <i>(pass -DVISIT_STATIC:BOOL=ON to cmake)</i>. This means that the usual loading of the simulation runtime library is not done and all symbols are resolved at link time. This change makes it possible to deploy libsim-instrumented simulations on platforms that lack shared libraries.</li>
<li></li>
<li></li>
</ul>
......
#ifndef DECLARE_DATA_CALLBACKS_H
#define DECLARE_DATA_CALLBACKS_H
#define NO_ARGS(A)
#define CB_ARGS(A) cb
#define FUNC_ARGS(A) cb_##A
#define NO_ARGS(A) (*)
#define CB_ARGS(A) (*cb)
#define DECLARE_DATA_CALLBACKS(DECL, ARG) \
#define DECLARE_DATA_CALLBACKS(DECL) \
/* Read callbacks */ \
DECL(ActivateTimestep, int (*ARG(ActivateTimestep))(void *)) \
DECL(GetMetaData, visit_handle (*ARG(GetMetaData))(void *)) \
DECL(GetMesh, visit_handle (*ARG(GetMesh))(int, const char *, void *)) \
DECL(GetMaterial, visit_handle (*ARG(GetMaterial))(int, const char *, void *)) \
DECL(GetSpecies, visit_handle (*ARG(GetSpecies))(int, const char *, void *)) \
DECL(GetVariable, visit_handle (*ARG(GetVariable))(int, const char *, void *)) \
DECL(GetMixedVariable, visit_handle (*ARG(GetMixedVariable))(int, const char *, void *)) \
DECL(GetCurve, visit_handle (*ARG(GetCurve))(const char *, void *)) \
DECL(GetDomainList, visit_handle (*ARG(GetDomainList))(const char *, void *)) \
DECL(GetDomainBoundaries, visit_handle (*ARG(GetDomainBoundaries))(const char *, void *)) \
DECL(GetDomainNesting, visit_handle (*ARG(GetDomainNesting))(const char *, void *)) \
DECL(ActivateTimestep, int, (void *)) \
DECL(GetMetaData, visit_handle, (void *)) \
DECL(GetMesh, visit_handle, (int, const char *, void *)) \
DECL(GetMaterial, visit_handle, (int, const char *, void *)) \
DECL(GetSpecies, visit_handle, (int, const char *, void *)) \
DECL(GetVariable, visit_handle, (int, const char *, void *)) \
DECL(GetMixedVariable, visit_handle, (int, const char *, void *)) \
DECL(GetCurve, visit_handle, (const char *, void *)) \
DECL(GetDomainList, visit_handle, (const char *, void *)) \
DECL(GetDomainBoundaries, visit_handle, (const char *, void *)) \
DECL(GetDomainNesting, visit_handle, (const char *, void *)) \
/* Write callbacks */ \
DECL(WriteBegin, int (*ARG(WriteBegin))(const char *, void *)) \
DECL(WriteEnd, int (*ARG(WriteEnd))(const char *, void *)) \
DECL(WriteMesh, int (*ARG(WriteMesh))(const char *, int, int, visit_handle, visit_handle, void *)) \
DECL(WriteVariable, int (*ARG(WriteVariable))(const char *, const char *, int, visit_handle, visit_handle, void *))
DECL(WriteBegin, int, (const char *, void *)) \
DECL(WriteEnd, int, (const char *, void *)) \
DECL(WriteMesh, int, (const char *, int, int, visit_handle, visit_handle, void *)) \
DECL(WriteVariable, int, (const char *, const char *, int, visit_handle, visit_handle, void *))
#endif
......@@ -51,7 +51,9 @@
#include <shlobj.h>
#include <shlwapi.h>
#else
#ifndef VISIT_STATIC
#include <dlfcn.h>
#endif
#include <netdb.h>
#include <unistd.h>
#include <netinet/in.h>
......@@ -131,11 +133,11 @@ typedef struct
void (*debug_logs)(int,const char *);
} control_callback_t;
#define STRUCT_MEMBER(F,T) void (*set_##F)(T, void*);
#define STRUCT_MEMBER(F, FR, FA) void (*set_##F)(FR (*) FA, void*);
typedef struct
{
DECLARE_DATA_CALLBACKS(STRUCT_MEMBER, NO_ARGS)
DECLARE_DATA_CALLBACKS(STRUCT_MEMBER)
} data_callback_t;
typedef struct
......@@ -157,15 +159,17 @@ static visit_callback_t *callbacks = NULL;
#ifdef _WIN32
#define VISIT_SOCKET SOCKET
#define VISIT_INVALID_SOCKET INVALID_SOCKET
#ifndef VISIT_STATIC
static HMODULE dl_handle;
#endif
static SOCKET listenSocket = VISIT_INVALID_SOCKET;
static SOCKET engineSocket = VISIT_INVALID_SOCKET;
#else
#define VISIT_SOCKET int
#define VISIT_INVALID_SOCKET -1
#ifndef VISIT_STATIC
static void *dl_handle = NULL;
#endif
static int listenSocket = VISIT_INVALID_SOCKET;
static int engineSocket = VISIT_INVALID_SOCKET;
#endif
......@@ -1370,8 +1374,11 @@ static void RemoveSimFile(void)
* Brad Whitlock, Thu Nov 25 23:26:23 PST 2010
* Ported to Windows.
*
* Brad Whitlock, Mon Oct 24 09:45:42 PDT 2011
* Wrap it with VISIT_STATIC since we don't use them in that case.
*
*******************************************************************************/
#ifndef VISIT_STATIC
void *
visit_get_runtime_function(const char *name)
{
......@@ -1390,6 +1397,7 @@ visit_get_runtime_function(const char *name)
LIBSIM_API_LEAVE1(visit_get_runtime_function, "func=%p", (void*)f);
return f;
}
#endif
/*******************************************************************************
*
......@@ -1400,9 +1408,11 @@ visit_get_runtime_function(const char *name)
* Author: Brad Whitlock
*
* Modifications:
* Brad Whitlock, Mon Oct 24 09:44:38 PDT 2011
* Wrap it all with VISIT_STATIC since we don't use them in that case.
*
*******************************************************************************/
#ifndef VISIT_STATIC
#ifdef _WIN32
static int LoadVisItLibrary_Windows(void)
{
......@@ -1518,6 +1528,7 @@ static int LoadVisItLibrary_UNIX(void)
return (dl_handle != NULL) ? VISIT_OKAY : VISIT_ERROR;
}
#endif
#endif
/*******************************************************************************
*
......@@ -1528,11 +1539,14 @@ static int LoadVisItLibrary_UNIX(void)
* Author: Brad Whitlock
*
* Modifications:
* Brad Whitlock, Mon Oct 24 09:47:15 PDT 2011
* Do nothing if we're building statically.
*
*******************************************************************************/
static void CloseVisItLibrary(void)
{
#ifndef VISIT_STATIC
#ifdef _WIN32
if(dl_handle != NULL)
{
......@@ -1543,6 +1557,7 @@ static void CloseVisItLibrary(void)
/* Call dlclose(dl_handle) ???*/
dl_handle = NULL;
#endif
#endif
}
/*******************************************************************************
......@@ -1571,10 +1586,39 @@ static void CloseVisItLibrary(void)
* I moved the code to load libraries into helper functions to separate out
* some Windows-only logic.
*
* Brad Whitlock, Mon Oct 24 09:43:36 PDT 2011
* Add case for static builds where we just access the function that we want
* instead of opening it dynamically.
*
*******************************************************************************/
static int LoadVisItLibrary(void)
{
#ifdef VISIT_STATIC
/* Static */
#define CONTROL_DLSYM(N, FR, FA) \
extern FR simv2_##N FA; \
callbacks->control.N = simv2_##N;
#define DATA_DLSYM(N, FR, FA) \
extern void simv2_set_##N(FR (*) FA, void *); \
callbacks->data.set_##N = simv2_set_##N;
LIBSIM_API_ENTER(LoadVisItLibrary);
#else
/* Dynamic */
#define SAFE_DLSYM(D, NAME, SIMV2NAME, FR, FA) \
callbacks->D.NAME = (FR (*) FA)visit_get_runtime_function(#SIMV2NAME); \
if (!callbacks->D.NAME) \
{ \
CloseVisItLibrary();\
LIBSIM_API_LEAVE2(LoadVisItLibrary, "%s: return %d", lastError, FALSE); \
return FALSE; \
}
#define CONTROL_DLSYM(N, FR, FA) SAFE_DLSYM(control, N, simv2_##N, FR, FA)
#define DATA_DLSYM(N, FR, FA) SAFE_DLSYM(data, set_##N, simv2_set_##N, void, (FR (*) FA, void*))
int status = VISIT_ERROR;
LIBSIM_API_ENTER(LoadVisItLibrary);
......@@ -1584,53 +1628,35 @@ static int LoadVisItLibrary(void)
#else
status = LoadVisItLibrary_UNIX();
#endif
if (status == VISIT_ERROR)
{
LIBSIM_API_LEAVE2(LoadVisItLibrary, "%s: return %d", lastError, FALSE);
return FALSE;
}
#endif /* VISIT_STATIC */
callbacks = (visit_callback_t *)malloc(sizeof(visit_callback_t));
memset(callbacks, 0, sizeof(visit_callback_t));
#define SAFE_DLSYM(D,F,T,N,DECORATE) \
callbacks->D.F = (DECORATE(T))visit_get_runtime_function(N); \
if (!callbacks->D.F) \
{ \
CloseVisItLibrary();\
LIBSIM_API_LEAVE2(LoadVisItLibrary, "%s: return %d", lastError, FALSE); \
return FALSE; \
}
#define NO_DECORATE(A) A
#define SET_DECORATE(A) void (*)(A,void*)
#define QUOTED(A) #A
#define CONTROL_DLSYM(F,T) SAFE_DLSYM(control,F,T,QUOTED(simv2_##F),NO_DECORATE)
#define DATA_DLSYM(F,T) SAFE_DLSYM(data,set_##F,T,QUOTED(simv2_set_##F),SET_DECORATE)
/* Get the control functions fom the library. */
CONTROL_DLSYM(get_engine, void *(*)(void));
CONTROL_DLSYM(get_descriptor, int (*)(void *));
CONTROL_DLSYM(process_input, int (*)(void *));
CONTROL_DLSYM(initialize, int (*)(void *, int, char **));
CONTROL_DLSYM(connect_viewer, int (*)(void *, int, char **));
CONTROL_DLSYM(time_step_changed, void (*)(void *));
CONTROL_DLSYM(execute_command, void (*)(void *,const char*));
CONTROL_DLSYM(disconnect, void (*)());
CONTROL_DLSYM(set_slave_process_callback, void (*)(void (*)()));
CONTROL_DLSYM(set_command_callback, void (*)(void*,void (*)(const char*,const char*,void*),void*));
CONTROL_DLSYM(save_window, int (*)(void*,const char *,int,int,int));
CONTROL_DLSYM(debug_logs, void (*)(int,const char *));
/* Get the data functions from the library. */
DECLARE_DATA_CALLBACKS(DATA_DLSYM, NO_ARGS)
#ifdef VISIT_QUERIES_VIA_LIBSIM
/* Load the VisIt query functions.*/
LoadVisItQueries();
#endif
LIBSIM_API_LEAVE1(LoadVisItLibrary, "return %d", TRUE);
return TRUE;
CONTROL_DLSYM(get_engine, void *, (void));
CONTROL_DLSYM(get_descriptor, int, (void *));
CONTROL_DLSYM(process_input, int, (void *));
CONTROL_DLSYM(initialize, int, (void *, int, char **));
CONTROL_DLSYM(connect_viewer, int, (void *, int, char **));
CONTROL_DLSYM(time_step_changed, void, (void *));
CONTROL_DLSYM(execute_command, void, (void *,const char*));
CONTROL_DLSYM(disconnect, void, ());
CONTROL_DLSYM(set_slave_process_callback, void, (void (*)()));
CONTROL_DLSYM(set_command_callback, void, (void*,void (*)(const char*,const char*,void*),void*));
CONTROL_DLSYM(save_window, int, (void*,const char *,int,int,int));
CONTROL_DLSYM(debug_logs, void, (int,const char *));
/* Get the data functions from the library. */
DECLARE_DATA_CALLBACKS(DATA_DLSYM)
LIBSIM_API_LEAVE1(LoadVisItLibrary, "return %d", TRUE);
return TRUE;
}
/*******************************************************************************
......@@ -3133,8 +3159,8 @@ void VisItCloseTraceFile(void)
*
******************************************************************************/
#define VISIT_SET_CALLBACK_BODY(F, T) \
int VisItSet##F(T, void *cbdata) \
#define VISIT_SET_CALLBACK_BODY(F, FR, FA) \
int VisItSet##F(FR (*cb) FA, void *cbdata) \
{ \
int retval = VISIT_ERROR; \
LIBSIM_API_ENTER(VisIt##F);\
......@@ -3150,7 +3176,7 @@ int VisItSet##F(T, void *cbdata) \
return retval;\
}
DECLARE_DATA_CALLBACKS(VISIT_SET_CALLBACK_BODY, CB_ARGS)
DECLARE_DATA_CALLBACKS(VISIT_SET_CALLBACK_BODY)
/******************************************************************************
*
......
......@@ -2,14 +2,36 @@
#define VISIT_DYNAMIC_H
#include "SimV2Tracing.h"
#define VISIT_DYNAMIC_EXECUTE(FUNC, FUNCTYPE, FUNCVAR, EXEC_CB) \
#ifdef VISIT_STATIC
/* Statically linked case */
#define VISIT_DYNAMIC_EXECUTE(FUNC, FR, FA, INVOKEARGS) \
int retval = VISIT_ERROR; \
extern FR sim2_##FUNC FA; \
LIBSIM_API_ENTER(VisIt_##FUNC);\
{\
FUNCVAR = (FUNCTYPE)visit_get_runtime_function("simv2_"#FUNC);\
retval = simv2_##FUNC INVOKEARGS; \
if(retval == VISIT_ERROR) \
{ \
LIBSIM_MESSAGE("simv2_" #FUNC " returned VISIT_ERROR"); \
} \
else \
{ \
LIBSIM_MESSAGE("simv2_" #FUNC " returned VISIT_OKAY"); \
} \
}\
LIBSIM_API_LEAVE(VisIt_##FUNC); \
return retval;
#else
/* Dynamic runtime case */
#define VISIT_DYNAMIC_EXECUTE(FUNC, FR, FA, INVOKEARGS) \
int retval = VISIT_ERROR; \
LIBSIM_API_ENTER(VisIt_##FUNC);\
{\
FR (*cb) FA = (FR (*) FA)visit_get_runtime_function("simv2_"#FUNC);\
if(cb != NULL)\
{ \
retval = EXEC_CB;\
retval = (*cb) INVOKEARGS;\
if(retval == VISIT_ERROR) \
{ \
LIBSIM_MESSAGE("simv2_" #FUNC " returned VISIT_ERROR"); \
......@@ -24,5 +46,6 @@
return retval;
void *visit_get_runtime_function(const char *name);
#endif
#endif
......@@ -44,18 +44,16 @@ int
VisIt_CSGMesh_alloc(visit_handle *obj)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_alloc,
int (*)(visit_handle*),
int (*cb)(visit_handle*),
(*cb)(obj))
int, (visit_handle*),
(obj))
}
int
VisIt_CSGMesh_free(visit_handle obj)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_free,
int (*)(visit_handle),
int (*cb)(visit_handle),
(*cb)(obj));
int, (visit_handle),
(obj));
}
int
......@@ -63,45 +61,40 @@ VisIt_CSGMesh_setRegions(visit_handle obj, visit_handle boolops, visit_handle le
visit_handle rightids)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_setRegions,
int (*)(visit_handle,visit_handle,visit_handle,visit_handle),
int (*cb)(visit_handle,visit_handle,visit_handle,visit_handle),
(*cb)(obj,boolops,leftids,rightids));
int, (visit_handle,visit_handle,visit_handle,visit_handle),
(obj,boolops,leftids,rightids));
}
int
VisIt_CSGMesh_setZonelist(visit_handle obj, visit_handle zl)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_setZonelist,
int (*)(visit_handle,visit_handle),
int (*cb)(visit_handle,visit_handle),
(*cb)(obj,zl));
int, (visit_handle,visit_handle),
(obj,zl));
}
int
VisIt_CSGMesh_setBoundaryTypes(visit_handle obj, visit_handle boundaryTypes)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_setBoundaryTypes,
int (*)(visit_handle,visit_handle),
int (*cb)(visit_handle,visit_handle),
(*cb)(obj,boundaryTypes));
int, (visit_handle,visit_handle),
(obj,boundaryTypes));
}
int
VisIt_CSGMesh_setBoundaryCoeffs(visit_handle obj, visit_handle boundaryCoeffs)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_setBoundaryCoeffs,
int (*)(visit_handle,visit_handle),
int (*cb)(visit_handle,visit_handle),
(*cb)(obj,boundaryCoeffs));
int, (visit_handle,visit_handle),
(obj,boundaryCoeffs));
}
int
VisIt_CSGMesh_setExtents(visit_handle obj, double min[3], double max[3])
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_setExtents,
int (*)(visit_handle,double[3], double[3]),
int (*cb)(visit_handle,double[3], double[3]),
(*cb)(obj,min,max));
int, (visit_handle,double[3], double[3]),
(obj,min,max));
}
int
......@@ -109,45 +102,40 @@ VisIt_CSGMesh_getRegions(visit_handle obj, visit_handle *boolops, visit_handle *
visit_handle *rightids)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_getRegions,
int (*)(visit_handle,visit_handle*,visit_handle*,visit_handle*),
int (*cb)(visit_handle,visit_handle*,visit_handle*,visit_handle*),
(*cb)(obj,boolops,leftids,rightids));
int, (visit_handle,visit_handle*,visit_handle*,visit_handle*),
(obj,boolops,leftids,rightids));
}
int
VisIt_CSGMesh_getZonelist(visit_handle obj, visit_handle *zl)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_getZonelist,
int (*)(visit_handle,visit_handle*),
int (*cb)(visit_handle,visit_handle*),
(*cb)(obj,zl));
int, (visit_handle,visit_handle*),
(obj,zl));
}
int
VisIt_CSGMesh_getBoundaryTypes(visit_handle obj, visit_handle *boundaryTypes)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_getBoundaryTypes,
int (*)(visit_handle,visit_handle*),
int (*cb)(visit_handle,visit_handle*),
(*cb)(obj,boundaryTypes));
int, (visit_handle,visit_handle*),
(obj,boundaryTypes));
}
int
VisIt_CSGMesh_getBoundaryCoeffs(visit_handle obj, visit_handle *boundaryCoeffs)
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_getBoundaryCoeffs,
int (*)(visit_handle,visit_handle*),
int (*cb)(visit_handle,visit_handle*),
(*cb)(obj,boundaryCoeffs));
int, (visit_handle,visit_handle*),
(obj,boundaryCoeffs));
}
int
VisIt_CSGMesh_getExtents(visit_handle obj, double min[3], double max[3])
{
VISIT_DYNAMIC_EXECUTE(CSGMesh_getExtents,
int (*)(visit_handle,double[3], double[3]),
int (*cb)(visit_handle,double[3], double[3]),
(*cb)(obj,min,max));
int, (visit_handle,double[3], double[3]),
(obj,min,max));
}
/************************** Fortran callable routines *************************/
......
......@@ -44,36 +44,32 @@ int
VisIt_CommandMetaData_alloc(visit_handle *obj)
{
VISIT_DYNAMIC_EXECUTE(CommandMetaData_alloc,
int (*)(visit_handle*),
int (*cb)(visit_handle*),
(*cb)(obj))
int, (visit_handle*),
(obj))
}
int
VisIt_CommandMetaData_free(visit_handle obj)
{
VISIT_DYNAMIC_EXECUTE(CommandMetaData_free,
int (*)(visit_handle),
int (*cb)(visit_handle),
(*cb)(obj));
int, (visit_handle),
(obj));
}
int
VisIt_CommandMetaData_setName(visit_handle h, const char *val)
{
VISIT_DYNAMIC_EXECUTE(CommandMetaData_setName,
int (*)(visit_handle, const char *),
int (*cb)(visit_handle, const char *),
(*cb)(h, val));
int, (visit_handle, const char *),
(h, val));
}
int
VisIt_CommandMetaData_getName(visit_handle h, char **val)
{
VISIT_DYNAMIC_EXECUTE(CommandMetaData_getName,
int (*)(visit_handle, char **),
int (*cb)(visit_handle, char **),
(*cb)(h, val));
int, (visit_handle, char **),
(h, val));
}
......
......@@ -44,27 +44,24 @@ int
VisIt_CurveData_alloc(visit_handle *obj)
{
VISIT_DYNAMIC_EXECUTE(CurveData_alloc,
int (*)(visit_handle*),
int (*cb)(visit_handle*),
(*cb)(obj))
int, (visit_handle*),
(obj))
}
int
VisIt_CurveData_free(visit_handle obj)
{
VISIT_DYNAMIC_EXECUTE(CurveData_free,
int (*)(visit_handle),
int (*cb)(visit_handle),
(*cb)(obj));
int, (visit_handle),
(obj));
}
int
VisIt_CurveData_setCoordsXY(visit_handle obj, visit_handle x, visit_handle y)
{
VISIT_DYNAMIC_EXECUTE(CurveData_setCoordsXY,
int (*)(visit_handle,visit_handle,visit_handle),
int (*cb)(visit_handle,visit_handle,visit_handle),
(*cb)(obj,x,y));
int, (visit_handle,visit_handle,visit_handle),
(obj,x,y));
}
/************************** Fortran callable routines *************************/
......
......@@ -44,108 +44,96 @@ int
VisIt_CurveMetaData_alloc(visit_handle *obj)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_alloc,
int (*)(visit_handle*),
int (*cb)(visit_handle*),
(*cb)(obj))
int, (visit_handle*),
(obj))
}
int
VisIt_CurveMetaData_free(visit_handle obj)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_free,
int (*)(visit_handle),
int (*cb)(visit_handle),
(*cb)(obj));
int, (visit_handle),
(obj));
}
int
VisIt_CurveMetaData_setName(visit_handle h, const char *val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_setName,
int (*)(visit_handle, const char *),
int (*cb)(visit_handle, const char *),
(*cb)(h, val));
int, (visit_handle, const char *),
(h, val));
}
int
VisIt_CurveMetaData_getName(visit_handle h, char **val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_getName,
int (*)(visit_handle, char **),
int (*cb)(visit_handle, char **),
(*cb)(h, val));
int, (visit_handle, char **),
(h, val));
}
int
VisIt_CurveMetaData_setXUnits(visit_handle h, const char *val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_setXUnits,
int (*)(visit_handle, const char *),
int (*cb)(visit_handle, const char *),
(*cb)(h, val));
int, (visit_handle, const char *),
(h, val));
}
int
VisIt_CurveMetaData_getXUnits(visit_handle h, char **val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_getXUnits,
int (*)(visit_handle, char **),
int (*cb)(visit_handle, char **),
(*cb)(h, val));
int, (visit_handle, char **),
(h, val));
}
int
VisIt_CurveMetaData_setYUnits(visit_handle h, const char *val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_setYUnits,
int (*)(visit_handle, const char *),
int (*cb)(visit_handle, const char *),
(*cb)(h, val));
int, (visit_handle, const char *),
(h, val));
}
int
VisIt_CurveMetaData_getYUnits(visit_handle h, char **val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_getYUnits,
int (*)(visit_handle, char **),
int (*cb)(visit_handle, char **),
(*cb)(h, val));
int, (visit_handle, char **),
(h, val));
}
int
VisIt_CurveMetaData_setXLabel(visit_handle h, const char *val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_setXLabel,
int (*)(visit_handle, const char *),
int (*cb)(visit_handle, const char *),
(*cb)(h, val));
int, (visit_handle, const char *),
(h, val));
}
int
VisIt_CurveMetaData_getXLabel(visit_handle h, char **val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_getXLabel,
int (*)(visit_handle, char **),
int (*cb)(visit_handle, char **),
(*cb)(h, val));
int, (visit_handle, char **),
(h, val));
}
int
VisIt_CurveMetaData_setYLabel(visit_handle h, const char *val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_setYLabel,
int (*)(visit_handle, const char *),
int (*cb)(visit_handle, const char *),
(*cb)(h, val));
int, (visit_handle, const char *),
(h, val));
}
int
VisIt_CurveMetaData_getYLabel(visit_handle h, char **val)
{
VISIT_DYNAMIC_EXECUTE(CurveMetaData_getYLabel,
int (*)(visit_handle, char **),
int (*cb)(visit_handle, char **),
(*cb)(h, val));
int, (visit_handle, char **),
(h, val));
}
......
......@@ -44,81 +44,72 @@ int
VisIt_CurvilinearMesh_alloc(visit_handle *obj)
{
VISIT_DYNAMIC_EXECUTE(CurvilinearMesh_alloc,
int (*)(visit_handle*),
int (*cb)(visit_handle*),
(*cb)(obj))
int, (visit_handle*),
(obj))
}
int
VisIt_CurvilinearMesh_free(visit_handle obj)
{
VISIT_DYNAMIC_EXECUTE(CurvilinearMesh_free,
int (*)(visit_handle),
int (*cb)(visit_handle),
(*cb)(obj));
int, (visit_handle),
(obj));
}
int
VisIt_CurvilinearMesh_setCoordsXY(visit_handle obj, int dims[2], visit_handle x, visit_handle y)
{
VISIT_DYNAMIC_EXECUTE(CurvilinearMesh_setCoordsXY,
int (*)(visit_handle,int[2],visit_handle,visit_handle),
int (*cb)(visit_handle,int[2],visit_handle,visit_handle),
(*cb)(obj,dims,x,y));
int, (visit_handle,int[2],visit_handle,visit_handle),
(obj,dims,x,y));
}