/[escript]/trunk/finley/src/Mesh_addPoints.cpp
ViewVC logotype

Diff of /trunk/finley/src/Mesh_addPoints.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 4491 by caltinay, Fri May 31 07:09:03 2013 UTC revision 4492 by caltinay, Tue Jul 2 01:44:11 2013 UTC
# Line 43  void Finley_Mesh_addPoints(Finley_Mesh* Line 43  void Finley_Mesh_addPoints(Finley_Mesh*
43  {  {
44      Esys_MPIInfo *mpi_info = Esys_MPIInfo_getReference(mesh->MPIInfo);      Esys_MPIInfo *mpi_info = Esys_MPIInfo_getReference(mesh->MPIInfo);
45      ElementFile *oldPoints=mesh->Points;      ElementFile *oldPoints=mesh->Points;
46      Finley_ReferenceElementSet *refPoints=NULL;      ReferenceElementSet *refPoints=NULL;
47      dim_t numOldPoints;      dim_t numOldPoints;
48      if (oldPoints == NULL) {      if (oldPoints == NULL) {
49          refPoints=Finley_ReferenceElementSet_alloc(Finley_Point1,          refPoints=ReferenceElementSet_alloc(Point1,
50                          mesh->integrationOrder, mesh->reducedIntegrationOrder);                          mesh->integrationOrder, mesh->reducedIntegrationOrder);
51          numOldPoints=0;          numOldPoints=0;
52      } else {      } else {
53          refPoints=Finley_ReferenceElementSet_reference(oldPoints->referenceElementSet);          refPoints=ReferenceElementSet_reference(oldPoints->referenceElementSet);
54          numOldPoints=mesh->Points->numElements;          numOldPoints=mesh->Points->numElements;
55      }      }
56      ElementFile *newPoints=new ElementFile(refPoints, mpi_info);      ElementFile *newPoints=new ElementFile(refPoints, mpi_info);
# Line 249  void Finley_Mesh_addPoints(Finley_Mesh* Line 249  void Finley_Mesh_addPoints(Finley_Mesh*
249      // all done, clean up      // all done, clean up
250      delete[] node_id_p;      delete[] node_id_p;
251      delete[] point_index_p;      delete[] point_index_p;
252      Finley_ReferenceElementSet_dealloc(refPoints);      ReferenceElementSet_dealloc(refPoints);
253      Esys_MPIInfo_free(mpi_info);      Esys_MPIInfo_free(mpi_info);
254      if (Finley_noError()) {      if (Finley_noError()) {
255          delete oldPoints;          delete oldPoints;

Legend:
Removed from v.4491  
changed lines
  Added in v.4492

  ViewVC Help
Powered by ViewVC 1.1.26