| 1 | /*!\file ModelProcessorx | 
|---|
| 2 | * \brief: create datasets using input binary file and a set of requested analyses | 
|---|
| 3 | */ | 
|---|
| 4 |  | 
|---|
| 5 | #ifdef HAVE_CONFIG_H | 
|---|
| 6 | #include "config.h" | 
|---|
| 7 | #else | 
|---|
| 8 | #error "Cannot compile with HAVE_CONFIG_H symbol! run configure first!" | 
|---|
| 9 | #endif | 
|---|
| 10 |  | 
|---|
| 11 | #include "../../objects/objects.h" | 
|---|
| 12 | #include "../../shared/shared.h" | 
|---|
| 13 | #include "../../Container/Container.h" | 
|---|
| 14 | #include "../../EnumDefinitions/EnumDefinitions.h" | 
|---|
| 15 | #include "../../include/include.h" | 
|---|
| 16 | #include "../../modules/modules.h" | 
|---|
| 17 |  | 
|---|
| 18 | void ModelProcessorx(Elements** pelements, Nodes** pnodes, Vertices** pvertices, Materials** pmaterials, Constraints** pconstraints, Loads** ploads, Parameters** pparameters, ConstDataHandle IOMODEL,const int solution_type,const int nummodels,const int* analysis_type_list){ | 
|---|
| 19 |  | 
|---|
| 20 | int i; | 
|---|
| 21 | int analysis_type; | 
|---|
| 22 |  | 
|---|
| 23 | /*output: */ | 
|---|
| 24 | Elements* elements=NULL; | 
|---|
| 25 | Nodes* nodes=NULL; | 
|---|
| 26 | Vertices* vertices=NULL; | 
|---|
| 27 | Materials* materials=NULL; | 
|---|
| 28 | Constraints* constraints=NULL; | 
|---|
| 29 | Loads* loads=NULL; | 
|---|
| 30 | Parameters* parameters=NULL; | 
|---|
| 31 |  | 
|---|
| 32 |  | 
|---|
| 33 | /*intermediary: */ | 
|---|
| 34 | IoModel* iomodel=NULL; | 
|---|
| 35 |  | 
|---|
| 36 | _printf_("   fill model with matlab workspace data\n"); | 
|---|
| 37 | iomodel = new IoModel(IOMODEL); | 
|---|
| 38 | SetVerbosityLevel(iomodel->verbose); | 
|---|
| 39 |  | 
|---|
| 40 | for(i=0;i<nummodels;i++){ | 
|---|
| 41 |  | 
|---|
| 42 | analysis_type=analysis_type_list[i]; | 
|---|
| 43 |  | 
|---|
| 44 | ISSMPRINTF(VerboseMProcessor(),"   create datasets for analysis %s\n",EnumToString(analysis_type)); | 
|---|
| 45 | CreateDataSets(&elements,&nodes,&vertices,&materials,&constraints,&loads,¶meters,iomodel,IOMODEL,solution_type,analysis_type,nummodels,i); | 
|---|
| 46 | } | 
|---|
| 47 |  | 
|---|
| 48 | /*Free ressources:*/ | 
|---|
| 49 | delete iomodel; | 
|---|
| 50 |  | 
|---|
| 51 | /*Assign output pointers:*/ | 
|---|
| 52 | *pelements=elements; | 
|---|
| 53 | *pnodes=nodes; | 
|---|
| 54 | *pvertices=vertices; | 
|---|
| 55 | *pmaterials=materials; | 
|---|
| 56 | *pconstraints=constraints; | 
|---|
| 57 | *ploads=loads; | 
|---|
| 58 | *pparameters=parameters; | 
|---|
| 59 |  | 
|---|
| 60 | } | 
|---|