Changeset 25813
- Timestamp:
- 12/02/20 20:40:03 (4 years ago)
- Location:
- issm/trunk-jpl/src/c
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/main/esmfbinders.cpp
r25811 r25813 171 171 if(rc!=ESMF_SUCCESS) _error_("could not create EMSC_Mesh"); 172 172 173 /*Add nodes (which are ISSM Vertices)*/ 174 173 175 /*Some specific code here for the binding: */ 174 176 _error_("not coded yet, will depend on what FISOC provides"); -
issm/trunk-jpl/src/c/modules/VertexCoordinatesx/VertexCoordinatesx.cpp
r25812 r25813 36 36 IssmDouble* y=vy->ToMPISerial(); 37 37 IssmDouble* z=vz->ToMPISerial(); 38 IssmDouble* rank = NULL; 39 if(prank) rank = vrank->ToMPISerial(); 38 int* rank = NULL; 39 if(prank){ 40 /*Need to convert from IssmDouble to int*/ 41 IssmDouble* drank = vrank->ToMPISerial(); 42 rank = xNew<int>(numberofvertices); 43 for(int i=0;i<numberofvertices;i++) rank[i] = reCast<int>(drank[i]); 44 xDelete<IssmDouble>(drank); 45 delete vrank; 46 } 40 47 41 48 /*Free ressources: */ … … 43 50 delete vy; 44 51 delete vz; 45 delete vrank;46 52 47 53 /*output: */ … … 53 59 else xDelete<IssmDouble>(z); 54 60 if(prank) *prank=rank; 55 else xDelete<IssmDouble>(rank);56 61 }
Note:
See TracChangeset
for help on using the changeset viewer.