Changeset 13214


Ignore:
Timestamp:
08/31/12 10:47:36 (13 years ago)
Author:
Mathieu Morlighem
Message:

CHG: preparing mex module conversion to python

Location:
issm/trunk-jpl/src/modules
Files:
34 edited

Legend:

Unmodified
Added
Removed
  • issm/trunk-jpl/src/modules/AverageFilter/AverageFilter.h

    r13213 r13214  
    2929#define __FUNCT__  "AverageFilter"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define IMAGEIN prhs[0]
     
    3636/* serial output macros: */
    3737#define IMAGEOUT &plhs[0]
     38#endif
    3839
    3940/* serial arg counts: */
  • issm/trunk-jpl/src/modules/BamgConvertMesh/BamgConvertMesh.h

    r13213 r13214  
    2929#define __FUNCT__  "BamgConvertMesh"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define INDEXHANDLE prhs[0]
     
    3838#define BAMGMESHOUT    (mxArray**)&plhs[0]
    3939#define BAMGGEOMOUT    (mxArray**)&plhs[1]
     40#endif
    4041
    4142/* serial arg counts: */
  • issm/trunk-jpl/src/modules/BamgMesher/BamgMesher.h

    r13213 r13214  
    2828#undef __FUNCT__
    2929#define __FUNCT__  "BamgMesher"
    30    
     30
     31#ifdef _HAVE_MATLAB_MODULES_
    3132/* serial input macros: */
    3233#define BAMGMESHIN  (mxArray*)prhs[0]
     
    3738#define BAMGMESHOUT    (mxArray**)&plhs[0]
    3839#define BAMGGEOMOUT    (mxArray**)&plhs[1]
     40#endif
    3941
    4042/* serial arg counts: */
     
    4547
    4648#endif  /* _BAMG_MESHER_H_ */
    47 
  • issm/trunk-jpl/src/modules/BamgTriangulate/BamgTriangulate.h

    r13213 r13214  
    2929#define __FUNCT__  "BamgTriangulate"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define XHANDLE prhs[0]
     
    3636/* serial output macros: */
    3737#define INDEX (mxArray**)&plhs[0]
     38#endif
    3839
    3940/* serial arg counts: */
  • issm/trunk-jpl/src/modules/Chaco/Chaco.h

    r13213 r13214  
    1717#endif
    1818
    19 /* local prototypes: */
    20 void ChacoUsage(void);
    21 
    2219/*headers*/
    2320#include <stdio.h>
     
    2926#include "../../c/shared/shared.h"
    3027#include "../../c/issm-binding.h"
    31    
     28
     29/* local prototypes: */
     30void ChacoUsage(void);
     31
     32#undef __FUNCT__
     33#define __FUNCT__  "Chaco"
     34
     35#ifdef _HAVE_MATLAB_MODULES_
    3236/* serial input macros: */
    3337#define A_IN (mxArray*)prhs[0]
     
    4347/* serial output macros: */
    4448#define ASSGN_OUT (mxArray**)&plhs[0]
     49#endif
    4550
    4651/* serial arg counts: */
     
    5055#define NRHS  9
    5156
    52 #undef __FUNCT__
    53 #define __FUNCT__  "Chaco"
    54 
    5557#endif  /* _CHACO_H */
  • issm/trunk-jpl/src/modules/ContourToMesh/ContourToMesh.h

    r13213 r13214  
    2828#include "../../c/EnumDefinitions/EnumDefinitions.h"
    2929
     30#undef __FUNCT__
     31#define __FUNCT__ "ContourToMesh"
     32
    3033#ifdef _HAVE_MATLAB_MODULES_
    3134/* serial input macros: */
     
    5457#endif
    5558
    56 #undef __FUNCT__
    57 #define __FUNCT__ "ContourToMesh"
    58 
    5959/* serial arg counts: */
    6060#undef NLHS
  • issm/trunk-jpl/src/modules/ContourToNodes/ContourToNodes.h

    r13213 r13214  
    2929#define __FUNCT__ "ContourToNodes"
    3030
    31 
    32 #ifndef ALL
    33 #define ALL 0
    34 #endif
    35 
     31#ifdef _HAVE_MATLAB_MODULES_
    3632/* input macros: */
    3733#define XHANDLE prhs[0]
     
    4238/* serial output macros: */
    4339#define FLAGS (mxArray**)&plhs[0]
     40#endif
    4441
    4542/* serial arg counts: */
     
    4946#define NRHS 4
    5047
    51 
    5248#endif  /* _CONTOURTONODES_H */
    5349
  • issm/trunk-jpl/src/modules/ElementConnectivity/ElementConnectivity.h

    r13213 r13214  
    2828#include "../../c/EnumDefinitions/EnumDefinitions.h"
    2929
     30#undef __FUNCT__
     31#define __FUNCT__  "ElementConnectivity"
     32
    3033#ifdef _HAVE_MATLAB_MODULES_
    3134/* serial input macros: */
     
    4649#endif
    4750
    48 #undef __FUNCT__
    49 #define __FUNCT__  "ElementConnectivity"
    50 
    5151/* serial arg counts: */
    5252#undef NLHS
  • issm/trunk-jpl/src/modules/EnumToString/EnumToString.cpp

    r13034 r13214  
    2929}
    3030
    31 void EnumToStringUsage(void)
    32 {
     31void EnumToStringUsage(void){
    3332        _pprintLine_("");
    3433        _pprintLine_("   usage: " << __FUNCT__ << "string = EnumToString(enum);");
  • issm/trunk-jpl/src/modules/EnumToString/EnumToString.h

    r13213 r13214  
    2323#include "../../c/shared/shared.h"
    2424#include "../../c/issm-binding.h"
    25    
     25
     26#undef __FUNCT__
     27#define __FUNCT__  "EnumToString"
     28 
    2629#ifdef _HAVE_MATLAB_MODULES_
    2730/* serial input macros: */
     
    4447#define NRHS  1
    4548
    46 #undef __FUNCT__
    47 #define __FUNCT__  "EnumToString"
    48 
    4949/* local prototypes: */
    5050void EnumToStringUsage(void);
  • issm/trunk-jpl/src/modules/Exp2Kml/Exp2Kml.h

    r13213 r13214  
    2929#define __FUNCT__  "Exp2Kml"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define EXP_IN    prhs[0]
     
    3737/* serial output macros: */
    3838#define RET_OUT    (mxArray**)&plhs[0]
     39#endif
    3940
    4041/* serial arg counts: */
  • issm/trunk-jpl/src/modules/HoleFiller/HoleFiller.h

    r13213 r13214  
    2929#define __FUNCT__  "HoleFiller"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define IMAGEIN prhs[0]
     
    3636/* serial output macros: */
    3737#define IMAGEOUT &plhs[0]
     38#endif
    3839
    3940/* serial arg counts: */
  • issm/trunk-jpl/src/modules/InternalFront/InternalFront.h

    r13213 r13214  
    2828#define __FUNCT__  "InternalFront"
    2929
     30#ifdef _HAVE_MATLAB_MODULES_
    3031/* serial input macros: */
    3132#define MODEL (mxArray*)prhs[0]
     
    3334/* serial output macros: */
    3435#define FRONT (mxArray**)&plhs[0]
     36#endif
    3537
    3638/* serial arg counts: */
  • issm/trunk-jpl/src/modules/InterpFromGridToMesh/InterpFromGridToMesh.h

    r13213 r13214  
    2929#define __FUNCT__  "InterpFromGridToMesh"
    3030
    31 #undef CLEANUP
    32 #define CLEANUP InterpFromGridToMeshLocalCleanup();
    33 
    34 
     31#ifdef _HAVE_MATLAB_MODULES_
    3532/* serial input macros: */
    3633#define XHANDLE prhs[0]
     
    4441/* serial output macros: */
    4542#define DATAMESH (mxArray**)&plhs[0]
     43#endif
    4644
    4745/* serial arg counts: */
  • issm/trunk-jpl/src/modules/InterpFromMesh2d/InterpFromMesh2d.h

    r13213 r13214  
    2929#define __FUNCT__  "InterpFromMesh2d"
    3030
    31 #undef CLEANUP
    32 #define CLEANUP InterpFromMesh2dLocalCleanup();
    33 
     31#ifdef _HAVE_MATLAB_MODULES_
    3432/* serial input macros: */
    3533#define INDEXHANDLE prhs[0]
     
    4442/* serial output macros: */
    4543#define DATAPRIME (mxArray**)&plhs[0]
     44#endif
    4645
    4746/* serial arg counts: */
  • issm/trunk-jpl/src/modules/InterpFromMeshToGrid/InterpFromMeshToGrid.h

    r13213 r13214  
    2929#define __FUNCT__  "InterpFromMeshToGrid"
    3030
     31#ifdef _HAVE_MATLAB_MODULES_
    3132/* serial input macros: */
    3233#define INDEX (mxArray*)prhs[0]
     
    4647#define YM (mxArray**)&plhs[1]
    4748#define GRIDDATA (mxArray**)&plhs[2]
     49#endif
    4850
    4951/* serial arg counts: */
  • issm/trunk-jpl/src/modules/InterpFromMeshToMesh3d/InterpFromMeshToMesh3d.h

    r13213 r13214  
    2929#define __FUNCT__  "InterpFromMeshToMesh3d"
    3030
    31 #undef CLEANUP
    32 #define CLEANUP InterpFromMeshToMesh3dLocalCleanup();
    33 
    34 
     31#ifdef _HAVE_MATLAB_MODULES_
    3532/* serial input macros: */
    3633#define INDEXHANDLE prhs[0]
     
    4643/* serial output macros: */
    4744#define DATAPRIME (mxArray**)&plhs[0]
     45#endif
    4846
    4947/* serial arg counts: */
  • issm/trunk-jpl/src/modules/KMLFileRead/KMLFileRead.h

    r13213 r13214  
    2929#define __FUNCT__  "KMLFileRead"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define FILENAME      prhs[0]
     
    3535/* serial output macros: */
    3636#define ERRORFLAG (mxArray**)&plhs[0]
     37#endif
    3738
    3839/* serial arg counts: */
  • issm/trunk-jpl/src/modules/KMLMeshWrite/KMLMeshWrite.h

    r13213 r13214  
    2929#define __FUNCT__  "KMLMeshWrite"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define NAME          prhs[0]
     
    4444/* serial output macros: */
    4545#define ERRORFLAG (mxArray**)&plhs[0]
     46#endif
    4647
    4748/* serial arg counts: */
  • issm/trunk-jpl/src/modules/KMLOverlay/KMLOverlay.h

    r13213 r13214  
    2929#define __FUNCT__  "KMLOverlay"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define FILENAME      prhs[0]
     
    3535/* serial output macros: */
    3636#define ERRORFLAG (mxArray**)&plhs[0]
     37#endif
    3738
    3839/* serial arg counts: */
  • issm/trunk-jpl/src/modules/Kml2Exp/Kml2Exp.h

    r13213 r13214  
    2929#define __FUNCT__  "Kml2Exp"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define KML_IN    prhs[0]
     
    3737/* serial output macros: */
    3838#define RET_OUT    (mxArray**)&plhs[0]
     39#endif
    3940
    4041/* serial arg counts: */
     
    4546
    4647#endif
    47 
  • issm/trunk-jpl/src/modules/Kriging/Kriging.h

    r13213 r13214  
    2727#undef __FUNCT__
    2828#define __FUNCT__  "Kriging"
    29    
     29
     30#ifdef _HAVE_MATLAB_MODULES_
    3031/* serial input macros: */
    3132#define X            (mxArray *)prhs[0]
     
    3839#define PREDICTIONS (mxArray**)&plhs[0]
    3940#define ERROR       (mxArray**)&plhs[1]
     41#endif
    4042
    4143/* serial arg counts: */
  • issm/trunk-jpl/src/modules/Ll2xy/Ll2xy.h

    r13213 r13214  
    2929#define __FUNCT__  "Ll2xy"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define LAT_IN    prhs[0]
     
    3838#define X_OUT    (mxArray**)&plhs[0]
    3939#define Y_OUT    (mxArray**)&plhs[1]
     40#endif
    4041
    4142/* serial arg counts: */
     
    4647
    4748#endif
    48 
  • issm/trunk-jpl/src/modules/MeshPartition/MeshPartition.h

    r13213 r13214  
    3232#define __FUNCT__  "MeshPartition"
    3333
     34#ifdef _HAVE_MATLAB_MODULES_
    3435/* serial input macros: */
    3536#define MODEL (mxArray*)prhs[0]
     
    3940#define ELEMENTPARTITIONING (mxArray**)&plhs[0]
    4041#define NODEPARTITIONING (mxArray**)&plhs[1]
     42#endif
    4143
    4244/* serial arg counts: */
  • issm/trunk-jpl/src/modules/MeshProfileIntersection/MeshProfileIntersection.h

    r13213 r13214  
    2929#define __FUNCT__ "MeshProfileIntersection"
    3030
     31#ifdef _HAVE_MATLAB_MODULES_
    3132/* input macros: */
    3233#define INDEX prhs[0]
     
    3738/* serial output macros: */
    3839#define SEGMENTS (mxArray**)&plhs[0]
     40#endif
    3941
    4042/* serial arg counts: */
  • issm/trunk-jpl/src/modules/PointCloudFindNeighbors/PointCloudFindNeighbors.h

    r13213 r13214  
    2929#define __FUNCT__ "PointCloudFindNeighbors"
    3030
    31 
    32 #ifndef ALL
    33 #define ALL 0
    34 #endif
    35 
     31#ifdef _HAVE_MATLAB_MODULES_
    3632/* input macros: */
    3733#define XHANDLE prhs[0]
     
    4238/* serial output macros: */
    4339#define FLAGS (mxArray**)&plhs[0]
     40#endif
    4441
    4542/* serial arg counts: */
     
    4946#define NRHS 4
    5047
    51 
    5248#endif  /* _POINTCLOUDFINDNEIGHBORS_H */
    53 
  • issm/trunk-jpl/src/modules/PropagateFlagsFromConnectivity/PropagateFlagsFromConnectivity.h

    r13213 r13214  
    2929#define __FUNCT__  "PropagateFlagsFromConnectivity"
    3030
     31#ifdef _HAVE_MATLAB_MODULES_
    3132/* serial input macros: */
    3233#define CONNECTIVITY (mxArray*)prhs[0]
     
    3738/* serial output macros: */
    3839#define POOLOUT (mxArray**)&plhs[0]
     40#endif
    3941
    4042/* serial arg counts: */
     
    4446#define NRHS  4
    4547
    46 
    4748#endif  /* _PROPAGATEFLAGSFROMCONNECTIVITY_H */
    48 
    49 
  • issm/trunk-jpl/src/modules/Scotch/Scotch.h

    r13213 r13214  
    55#ifndef _SCOTCH_H
    66#define _SCOTCH_H
    7 
    8 #ifdef HAVE_CONFIG_H
    9         #include <config.h>
    10 #else
    11         #error "Cannot compile with HAVE_CONFIG_H symbol! run configure first!"
    12 #endif
    13 
    14 /*For python modules: needs to come before header files inclusion*/
    15 #ifdef _HAVE_PYTHON_
    16 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
    17 #endif
    187
    198/* local prototypes: */
     
    3524/*  Scotch structures and prototypes  */
    3625#ifdef MATLAB
    37                 #include "mat.h"
    38                 #include "mex.h"
    39                 #include "matrix.h"
     26#include "mat.h"
     27#include "mex.h"
     28#include "matrix.h"
    4029
    41                 #define printf mexPrintf
    42                 #define fprintf(file,...) (file == stdout || file == stderr ? mexPrintf(__VA_ARGS__) : fprintf(file,__VA_ARGS__))
    43                 #define malloc mxMalloc
    44                 #define calloc mxCalloc
    45                 #define realloc mxRealloc
    46                 #define free mxFree
    47                 #define exit(status) mexErrMsgTxt("exit=" #status)
     30#define printf mexPrintf
     31#define fprintf(file,...) (file == stdout || file == stderr ? mexPrintf(__VA_ARGS__) : fprintf(file,__VA_ARGS__))
     32#define malloc mxMalloc
     33#define calloc mxCalloc
     34#define realloc mxRealloc
     35#define free mxFree
     36#define exit(status) mexErrMsgTxt("exit=" #status)
    4837#endif
    4938
    50 
    5139#endif  /* _SCOTCH_H */
  • issm/trunk-jpl/src/modules/Shp2Kml/Shp2Kml.h

    r13213 r13214  
    2929#define __FUNCT__  "Shp2Kml"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define SHP_IN    prhs[0]
     
    3737/* serial output macros: */
    3838#define RET_OUT    (mxArray**)&plhs[0]
     39#endif
    3940
    4041/* serial arg counts: */
  • issm/trunk-jpl/src/modules/StringToEnum/StringToEnum.h

    r13213 r13214  
    2323#include "../../c/shared/shared.h"
    2424#include "../../c/issm-binding.h"
     25
     26#undef __FUNCT__
     27#define __FUNCT__  "StringToEnum"
    2528   
    2629#ifdef _HAVE_MATLAB_MODULES_
     
    4447#define NRHS  1
    4548
    46 #undef __FUNCT__
    47 #define __FUNCT__  "StringToEnum"
    48 
    4949/* local prototypes: */
    5050void StringToEnumUsage(void);
  • issm/trunk-jpl/src/modules/TriMesh/TriMesh.h

    r13213 r13214  
    2828#include "../../c/EnumDefinitions/EnumDefinitions.h"
    2929
     30#undef __FUNCT__
     31#define __FUNCT__  "TriMesh"
     32
    3033#ifdef _HAVE_MATLAB_MODULES_
    3134/* serial input macros: */
     
    5457#endif
    5558
    56 #undef __FUNCT__
    57 #define __FUNCT__  "TriMesh"
    58 
    5959/* serial arg counts: */
    6060#undef NLHS
  • issm/trunk-jpl/src/modules/TriMeshProcessRifts/TriMeshProcessRifts.h

    r13213 r13214  
    55#ifndef _TRIMESH_PROCESSRIFTS_H_
    66#define _TRIMESH_PROCESSRIFTS_H_
    7 
    8 #ifdef HAVE_CONFIG_H
    9         #include <config.h>
    10 #else
    11         #error "Cannot compile with HAVE_CONFIG_H symbol! run configure first!"
    12 #endif
    13 
    14 /*For python modules: needs to come before header files inclusion*/
    15 #ifdef _HAVE_PYTHON_
    16 #define PY_ARRAY_UNIQUE_SYMBOL PythonIOSymbol
    17 #endif
    187
    198#include "mex.h"
  • issm/trunk-jpl/src/modules/TriaSearch/TriaSearch.h

    r13213 r13214  
    2828#define __FUNCT__  "TriaSearch"
    2929
    30 
     30#ifdef _HAVE_MATLAB_MODULES_
    3131/* serial input macros: */
    3232#define INDEXHANDLE prhs[0]
     
    3838/* serial output macros: */
    3939#define TRIA (mxArray**)&plhs[0]
     40#endif
    4041
    4142/* serial arg counts: */
    4243#undef NLHS
    4344#define NLHS  1
    44 
    4545#undef NRHS
    4646#define NRHS  5
  • issm/trunk-jpl/src/modules/Xy2ll/Xy2ll.h

    r13213 r13214  
    2929#define __FUNCT__  "Xy2ll"
    3030
    31 
     31#ifdef _HAVE_MATLAB_MODULES_
    3232/* serial input macros: */
    3333#define X_IN      prhs[0]
     
    3838#define LAT_OUT    (mxArray**)&plhs[0]
    3939#define LON_OUT    (mxArray**)&plhs[1]
     40#endif
    4041
    4142/* serial arg counts: */
     
    4647
    4748#endif
    48 
Note: See TracChangeset for help on using the changeset viewer.