// VISU OBJECT : interactive object for VISU entities implementation
//
// Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
-// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
//
//
// File: VISU_PipeLine.cxx
#include "VISU_VectorsPL.hxx"
#include "VISU_PipeLineUtils.hxx"
-#include "SALOME_TransformFilter.h"
-#include "SALOME_Transform.h"
+#include "VTKViewer_TransformFilter.h"
+#include "VTKViewer_Transform.h"
#include <vtkGlyph3D.h>
#include <vtkConeSource.h>
myLineSource = vtkLineSource::New();
myCenters = vtkCellCenters::New();
- myTransformFilter = SALOME_TransformFilter::New();
+ myTransformFilter = VTKViewer_TransformFilter::New();
+ myIsShrinkable = false;
}
VISU_VectorsPL::~VISU_VectorsPL(){
}
-void VISU_VectorsPL::SetTransform(SALOME_Transform* theTransform){
+void VISU_VectorsPL::SetTransform(VTKViewer_Transform* theTransform){
myFieldTransform->SetSpaceTransform(theTransform);
myTransformFilter->SetTransform(theTransform);
myTransformFilter->Modified();
}
-SALOME_Transform* VISU_VectorsPL::GetTransform(){
+VTKViewer_Transform* VISU_VectorsPL::GetTransform(){
return myFieldTransform->GetSpaceTransform();
}
-void VISU_VectorsPL::SetScale(float theScale) {
+void VISU_VectorsPL::SetScale(float theScale) {
if(myScaleFactor == theScale) return;
myScaleFactor = theScale;
myGlyph->SetScaleFactor(myScaleFactor);
Modified();
}
-float VISU_VectorsPL::GetScale() {
+float VISU_VectorsPL::GetScale() {
return myGlyph->GetScaleFactor();
}
VISU_ScalarMapPL::THook* VISU_VectorsPL::DoHook(){
- VISU::ToCellCenters(myTransformFilter,myCenters,myInput,myFieldTransform);
+ VISU::ToCellCenters(myTransformFilter,myCenters,GetInput2(),myFieldTransform);
myGlyph->SetInput(myTransformFilter->GetOutput());
myGlyph->SetVectorModeToUseVector();
myGlyph->SetScaleModeToScaleByVector();
myConeSource->SetResolution(7);
myConeSource->SetHeight(1.0);
myConeSource->SetRadius(.1);
-
+
switch (myPosGlyph) {
case TAIL:
myConeSource->SetCenter(0.5, 0.0, 0.0);