8 #error "Cannot compile with HAVE_CONFIG_H symbol! run configure first!"
19 string=xNew<char>(strlen(stringin)+1); xMemCpy<char>(
string,stringin,strlen(stringin)+1);
35 void FetchData(
double** pvector,
double* vectorin,
int nods){
38 vector=xNew<IssmPDouble>(nods); xMemCpy<IssmPDouble>(vector,vectorin,nods);
44 void FetchData(
double** pvector,
int* pnods,
double* vectorin,
int nods){
47 vector=xNew<IssmPDouble>(nods); xMemCpy<IssmPDouble>(vector,vectorin,nods);
54 void FetchData(
double **pmatrix,
int* pM,
int* pN,
int* matrixin,
int M,
int N){
55 double* outmatrix=NULL;
56 int outmatrix_rows, outmatrix_cols;
64 else if (pmatrix && matrixin){
67 outmatrix=xNew<IssmPDouble>(M*N);
68 for(
int i=0;i<M*N;i++){outmatrix[i]=(
IssmPDouble)matrixin[i];}
73 if (pM){*pM=outmatrix_rows;}
74 if (pN){*pN=outmatrix_cols;}
78 void FetchData(
double **pmatrix,
int* pM,
int* pN,
double* matrixin,
int M,
int N){
79 double* outmatrix=NULL;
80 int outmatrix_rows, outmatrix_cols;
88 else if (pmatrix && matrixin){
91 outmatrix=xNew<IssmPDouble>(M*N); xMemCpy<IssmPDouble>(outmatrix,matrixin,M*N);
96 if (pM){*pM=outmatrix_rows;}
97 if (pN){*pN=outmatrix_cols;}
101 void FetchData(
int **pmatrix,
int* pM,
int* pN,
int* matrixin,
int M,
int N){
103 int outmatrix_rows, outmatrix_cols;
105 if(M == 0 || N == 0){
111 else if (pmatrix && matrixin){
114 outmatrix=xNew<int>(M*N); xMemCpy<int>(outmatrix,matrixin,M*N);
119 if (pM){*pM=outmatrix_rows;}
120 if (pN){*pN=outmatrix_cols;}
126 int numcontours, index, test1, test2;
127 char *contourname = NULL;
137 contouri->
x=xNew<IssmPDouble>(nods); xMemCpy<IssmPDouble>(contouri->
x,x,nods);
138 contouri->
y=xNew<IssmPDouble>(nods); xMemCpy<IssmPDouble>(contouri->
y,y,nods);
146 void FetchData(
BamgGeom** pbamggeom,
int* VerticesSize,
double*
Vertices,
int* EdgesSize,
double* Edges,
int* CornersSize,
double* Corners,
int* RequiredVerticesSize,
double* RequiredVertices,
int* RequiredEdgesSize,
double* RequiredEdges,
int* CrackedEdgesSize,
double* CrackedEdges,
int* SubDomainsSize,
double* SubDomains){
165 void FetchData(
BamgMesh** pbamgmesh,
int* VerticesSize,
double*
Vertices,
int* EdgesSize,
double* Edges,
int* TrianglesSize,
double* Triangles,
int* CrackedEdgesSize,
double* CrackedEdges,
int* VerticesOnGeomEdgeSize,
double* VerticesOnGeomEdge,
int* VerticesOnGeomVertexSize,
double* VerticesOnGeomVertex,
int* EdgesOnGeomEdgeSize,
double* EdgesOnGeomEdge,
int* IssmSegmentsSize,
double* IssmSegments){
185 void FetchData(
BamgOpts** pbamgopts,
double anisomax,
double coeff,
double cutoff,
double errg,
double gradation,
int Hessiantype,
int maxnbv,
double maxsubdiv,
int Metrictype,
int nbjacobi,
int nbsmooth,
double omega,
double power,
int verbose,
int Crack,
int KeepVertices,
int splitcorners,
double hmin,
double hmax,
int* hminVerticesSize,
double* hminVertices,
int* hmaxVerticesSize,
double* hmaxVertices,
int hVerticesLength,
double* hVertices,
int* metricSize,
double* metric,
int* fieldSize,
double* field,
int* errSize,
double* err){
191 bamgopts->
coeff = coeff;
192 bamgopts->
cutoff = cutoff;
193 bamgopts->
errg = errg;
196 bamgopts->
maxnbv = maxnbv;
201 bamgopts->
omega = omega;
202 bamgopts->
power = power;
206 bamgopts->
Crack = Crack;
211 bamgopts->
hmin = hmin;
212 bamgopts->
hmax = hmax;
236 odouble->
name=xNew<char>(strlen(optionname)+1);
237 memcpy(odouble->
name,optionname,(strlen(optionname)+1)*
sizeof(
char));
238 odouble->
value=optionvalue;