X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSMDS%2FSMDS_UnstructuredGrid.cxx;h=5a541c8fe34592ef811bb354b7cefcf46526eb25;hb=250c4f224450a7cbff5f30412f61ccfcc77c0e29;hp=1eb5c445d60e5e13ed1af797359a7f258ceb53d5;hpb=f5016d85b7b4b88623723027a1585c6414c4dc66;p=modules%2Fsmesh.git diff --git a/src/SMDS/SMDS_UnstructuredGrid.cxx b/src/SMDS/SMDS_UnstructuredGrid.cxx index 1eb5c445d..5a541c8fe 100644 --- a/src/SMDS/SMDS_UnstructuredGrid.cxx +++ b/src/SMDS/SMDS_UnstructuredGrid.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2010-2012 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2010-2013 CEA/DEN, EDF R&D, OPEN CASCADE // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -17,7 +17,6 @@ // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // -#define CHRONODEF #include "SMDS_UnstructuredGrid.hxx" #include "SMDS_Mesh.hxx" #include "SMDS_MeshInfo.hxx" @@ -44,14 +43,14 @@ SMDS_CellLinks* SMDS_CellLinks::New() return new SMDS_CellLinks(); } -vtkCellLinks::Link* SMDS_CellLinks::ResizeL(vtkIdType sz) +void SMDS_CellLinks::ResizeForPoint(vtkIdType vtkID) { - return vtkCellLinks::Resize(sz); -} - -vtkIdType SMDS_CellLinks::GetLinksSize() -{ - return this->Size; + if ( vtkID > this->MaxId ) + { + this->MaxId = vtkID; + if ( vtkID >= this->Size ) + vtkCellLinks::Resize( vtkID+SMDS_Mesh::chunkSize ); + } } SMDS_CellLinks::SMDS_CellLinks() : @@ -88,7 +87,8 @@ unsigned long SMDS_UnstructuredGrid::GetMTime() MESSAGE("vtkUnstructuredGrid::GetMTime: " << mtime); return mtime; } - +// OUV_PORTING_VTK6: seems to be useless +/* void SMDS_UnstructuredGrid::Update() { MESSAGE("SMDS_UnstructuredGrid::Update"); @@ -100,7 +100,7 @@ void SMDS_UnstructuredGrid::UpdateInformation() MESSAGE("SMDS_UnstructuredGrid::UpdateInformation"); return vtkUnstructuredGrid::UpdateInformation(); } - +*/ vtkPoints* SMDS_UnstructuredGrid::GetPoints() { // TODO erreur incomprehensible de la macro vtk GetPoints apparue avec la version paraview de fin aout 2010 @@ -154,7 +154,7 @@ void SMDS_UnstructuredGrid::setSMDS_mesh(SMDS_Mesh *mesh) void SMDS_UnstructuredGrid::compactGrid(std::vector& idNodesOldToNew, int newNodeSize, std::vector& idCellsOldToNew, int newCellSize) { - MESSAGE("------------------------- SMDS_UnstructuredGrid::compactGrid " << newNodeSize << " " << newCellSize);CHRONO(1); + MESSAGE("------------------------- SMDS_UnstructuredGrid::compactGrid " << newNodeSize << " " << newCellSize);//CHRONO(1); int alreadyCopied = 0; // --- if newNodeSize, create a new compacted vtkPoints