_field_pm_pt_pd[i++]=MEDFileFieldPerMeshPerTypePerDisc::NewOnRead(this,MEDFileMesh::ConvertFromMEDFileEntity(it.second),j,pd);
}
}
- /*INTERP_KERNEL::AutoPtr<char> pflName=MEDLoaderBase::buildEmptyString(MED_NAME_SIZE);
- INTERP_KERNEL::AutoPtr<char> locName=MEDLoaderBase::buildEmptyString(MED_NAME_SIZE);
- med_geometry_type mgeoti;
- med_entity_type menti(ConvertIntoMEDFileType(type,geoType,mgeoti));
- _field_pm_pt_pd.resize(nbProfiles);
- for(int i=0;i<nbProfiles;i++)
- {
- _field_pm_pt_pd[i]=MEDFileFieldPerMeshPerTypePerDisc::NewOnRead(this,type,i,pd);
- }
- if(type==ON_CELLS)
- {
- int nbProfiles2(MEDfieldnProfile(fid,nasc.getName().c_str(),getIteration(),getOrder(),MED_NODE_ELEMENT,mgeoti,pflName,locName));
- for(int i=0;i<nbProfiles2;i++)
- _field_pm_pt_pd.push_back(MEDFileFieldPerMeshPerTypePerDisc::NewOnRead(this,ON_GAUSS_NE,i,pd));
- }
- if(!_field_pm_pt_pd.empty() || type!=ON_CELLS)
- return ;
- // dark side of the force.
- {
- int nbProfiles1(MEDfieldnProfile(fid,nasc.getName().c_str(),getIteration(),getOrder(),MED_DESCENDING_FACE,mgeoti,pflName,locName));
- int nbProfiles2(MEDfieldnProfile(fid,nasc.getName().c_str(),getIteration(),getOrder(),MED_DESCENDING_EDGE,mgeoti,pflName,locName));
- if(nbProfiles1==0 && nbProfiles2==0)
- return ;// OK definitely nothing in field
- menti=nbProfiles1>=nbProfiles2?MED_DESCENDING_FACE:MED_DESCENDING_EDGE;//not enough words to describe the beauty
- nbProfiles=std::max(nbProfiles1,nbProfiles2);
- _field_pm_pt_pd.resize(nbProfiles);
- for(int i=0;i<nbProfiles;i++)
- _field_pm_pt_pd[i]=MEDFileFieldPerMeshPerTypePerDisc::NewOnRead(this,ON_CELLS,i,pd);
- }*/
}
MCAuto<MEDFileFieldPerMeshPerType> MEDFileFieldPerMeshPerType::Aggregate(int &start, const std::vector<std::pair<int,const MEDFileFieldPerMeshPerType *> >& pms, const std::vector< std::vector< std::pair<int,int> > >& dts, INTERP_KERNEL::NormalizedCellType gt, MEDFileFieldPerMesh *father, std::vector<std::pair< int, std::pair<int,int> > >& extractInfo)