-// Copyright (C) 2007-2015 CEA/DEN, EDF R&D
+// Copyright (C) 2007-2016 CEA/DEN, EDF R&D
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
using namespace std;
-#include "MEDCouplingAutoRefCountObjectPtr.hxx"
+#include "MCAuto.hxx"
#include "MEDLoader.hxx"
#include "MEDLoaderBase.hxx"
#include "MEDCouplingFieldDouble.hxx"
using namespace MEDCoupling;
-typedef MEDCouplingAutoRefCountObjectPtr<MEDCouplingUMesh> MUMesh;
-typedef MEDCouplingAutoRefCountObjectPtr<MEDCouplingFieldDouble> MFDouble;
-typedef MEDCouplingAutoRefCountObjectPtr<DataArrayDouble> DADouble;
+typedef MCAuto<MEDCouplingUMesh> MUMesh;
+typedef MCAuto<MEDCouplingFieldDouble> MFDouble;
+typedef MCAuto<DataArrayDouble> DADouble;
//void ParaMEDMEMTest::testOverlapDEC_LMEC_seq()
//{
// DataArrayDouble * dad = DataArrayDouble::New(); dad->alloc(src_mesh->getNumberOfCells(),1);
// dad->fillWithValue(1.0);
// srcField->setArray(dad);
-// srcField->setNature(ConservativeVolumic);
+// srcField->setNature(IntensiveMaximum);
//
// MEDCouplingRemapper remap;
// remap.setOrientation(2); // always consider surface intersections as absolute areas.
// DataArrayDouble * dad = DataArrayDouble::New(); dad->alloc(src_mesh->getNumberOfCells(),1);
// dad->fillWithValue(1.0);
// srcField->setArray(dad);
-// srcField->setNature(ConservativeVolumic);
+// srcField->setNature(IntensiveMaximum);
//
// ComponentTopology comptopo;
// parameshS = new ParaMESH(src_mesh,*dec.getGroup(),"source mesh");
// parafieldS = new ParaFIELD(ON_CELLS,ONE_TIME,parameshS,comptopo);
-// parafieldS->getField()->setNature(ConservativeVolumic);//IntegralGlobConstraint
+// parafieldS->getField()->setNature(IntensiveMaximum);//ExtensiveConservation
// parafieldS->getField()->setArray(dad);
//
// // **** TARGET
// parameshT=new ParaMESH(tgt_mesh,*dec.getGroup(),"target mesh");
// parafieldT=new ParaFIELD(ON_CELLS,ONE_TIME,parameshT,comptopo);
-// parafieldT->getField()->setNature(ConservativeVolumic);//IntegralGlobConstraint
+// parafieldT->getField()->setNature(IntensiveMaximum);//ExtensiveConservation
// parafieldT->getField()->getArray()->fillWithValue(1.0e300);
//// valsT[0]=7.;
// }
if(rank==0)
{
const double tr1[] = {1.5, 0.0};
- MEDCouplingUMesh *meshS_1 = static_cast<MEDCouplingUMesh*>(meshS_0->deepCpy());
+ MEDCouplingUMesh *meshS_1 = static_cast<MEDCouplingUMesh*>(meshS_0->deepCopy());
meshS_1->translate(tr1);
const double tr2[] = {3.0, 0.0};
- MEDCouplingUMesh *meshS_2 = static_cast<MEDCouplingUMesh*>(meshS_0->deepCpy());
+ MEDCouplingUMesh *meshS_2 = static_cast<MEDCouplingUMesh*>(meshS_0->deepCopy());
meshS_2->translate(tr2);
std::vector<const MEDCouplingUMesh*> vec;
//
const double tr3[] = {0.0, -1.5};
- MEDCouplingUMesh *meshT_3 = static_cast<MEDCouplingUMesh*>(meshT_0->deepCpy());
+ MEDCouplingUMesh *meshT_3 = static_cast<MEDCouplingUMesh*>(meshT_0->deepCopy());
meshT_3->translate(tr3);
vec.clear();
vec.push_back(meshT_0);vec.push_back(meshT_3);
if(rank==1)
{
const double tr3[] = {0.0, -1.5};
- MEDCouplingUMesh *meshS_3 = static_cast<MEDCouplingUMesh*>(meshS_0->deepCpy());
+ MEDCouplingUMesh *meshS_3 = static_cast<MEDCouplingUMesh*>(meshS_0->deepCopy());
meshS_3->translate(tr3);
const double tr4[] = {1.5, -1.5};
- MEDCouplingUMesh *meshS_4 = static_cast<MEDCouplingUMesh*>(meshS_0->deepCpy());
+ MEDCouplingUMesh *meshS_4 = static_cast<MEDCouplingUMesh*>(meshS_0->deepCopy());
meshS_4->translate(tr4);
std::vector<const MEDCouplingUMesh*> vec;
//
const double tr5[] = {1.5, 0.0};
- MEDCouplingUMesh *meshT_1 = static_cast<MEDCouplingUMesh*>(meshT_0->deepCpy());
+ MEDCouplingUMesh *meshT_1 = static_cast<MEDCouplingUMesh*>(meshT_0->deepCopy());
meshT_1->translate(tr5);
const double tr6[] = {3.0, 0.0};
- MEDCouplingUMesh *meshT_2 = static_cast<MEDCouplingUMesh*>(meshT_0->deepCpy());
+ MEDCouplingUMesh *meshT_2 = static_cast<MEDCouplingUMesh*>(meshT_0->deepCopy());
meshT_2->translate(tr6);
const double tr7[] = {1.5, -1.5};
- MEDCouplingUMesh *meshT_4 = static_cast<MEDCouplingUMesh*>(meshT_0->deepCpy());
+ MEDCouplingUMesh *meshT_4 = static_cast<MEDCouplingUMesh*>(meshT_0->deepCopy());
meshT_4->translate(tr7);
vec.clear();
OverlapDEC dec(procs);
MEDCouplingFieldDouble * mcfieldS=0, *mcfieldT=0;
- prepareData1(rank, ConservativeVolumic, mcfieldS, mcfieldT);
+ prepareData1(rank, IntensiveMaximum, mcfieldS, mcfieldT);
// See comment in the caller:
dec.setBoundingBoxAdjustmentAbs(bbAdj);
ParaMESH* parameshS=0, *parameshT=0;
ParaFIELD* parafieldS=0, *parafieldT=0;
- prepareData2(rank, grp, ConservativeVolumic, meshS, meshT, parameshS, parameshT, parafieldS, parafieldT);
+ prepareData2(rank, grp, IntensiveMaximum, meshS, meshT, parameshS, parameshT, parafieldS, parafieldT);
dec.attachSourceLocalField(parafieldS);
dec.attachTargetLocalField(parafieldT);
ParaFIELD* parafieldS=0, *parafieldT=0;
// As before, except than one of the source cell is removed, and that the field now has 2 components
- prepareData2(rank, grp, ConservativeVolumic, meshS, meshT, parameshS, parameshT, parafieldS, parafieldT,
+ prepareData2(rank, grp, IntensiveMaximum, meshS, meshT, parameshS, parameshT, parafieldS, parafieldT,
true, 2);
// if (rank == 1)
// {