Commit edfb9b52 authored by whitlocb's avatar whitlocb
Browse files

I made the Cylinder operator clip datasets instead of cut them so it keeps the

interior cells in the cylinder.



git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@14755 18c085ea-50e0-402c-830e-de6fd14e8384
parent ae9b3eb6
......@@ -78,6 +78,7 @@ enhancements and bug-fixes that were added to this release.</p>
<ul>
<li>The coordinate transformation option in the Transform operator now correctly fixes up "wrap-arounds" over angles for polygonal data as well. (It previously only worked with volumetric data.)</li>
<li>The Transform operator now correctly handles the case where rectilinear meshes are scaled with a negative scaling factor.</li>
<li>The Cylinder operator was changed so it clips the plot, leaving the interior of the cylinder intact. If you need to calculate results on the cylinder surface, you can apply an ExternalSurface operator to achieve the operator's former behavior.</li>
</ul>
<a name="Expression_changes"></a>
......
......@@ -42,12 +42,13 @@
#include <avtCylinderFilter.h>
#include <vtkVisItCutter.h>
#include <vtkVisItClipper.h>
#include <vtkCylinder.h>
#include <vtkImplicitBoolean.h>
#include <vtkMath.h>
#include <vtkPlane.h>
#include <vtkPolyData.h>
#include <vtkUnstructuredGrid.h>
#include <vtkTransform.h>
......@@ -228,19 +229,23 @@ avtCylinderFilter::Equivalent(const AttributeGroup *a)
// Use vtkVisItCutter instead of vtkCutter since it has logic to handle
// CellData correctly.
//
// Brad Whitlock, Fri May 6 13:41:40 PDT 2011
// Do clipping instead of cutting so we can leave the dataset interior.
//
// ****************************************************************************
vtkDataSet *
avtCylinderFilter::ExecuteData(vtkDataSet *in_ds, int, std::string)
{
vtkVisItCutter *cutter = vtkVisItCutter::New();
cutter->SetCutFunction(cylinderSlice);
cutter->SetInput(in_ds);
vtkDataSet *rv = cutter->GetOutput();
vtkVisItClipper *clipper = vtkVisItClipper::New();
clipper->SetInsideOut(true);
clipper->SetClipFunction(cylinderSlice);
clipper->SetInput(in_ds);
vtkDataSet *rv = clipper->GetOutput();
rv->Update();
ManageMemory(rv);
cutter->Delete();
clipper->Delete();
return rv;
}
......@@ -260,6 +265,9 @@ avtCylinderFilter::ExecuteData(vtkDataSet *in_ds, int, std::string)
// Kathleen Bonnell, Thu Mar 2 14:26:06 PST 2006
// Set ZonesSplit.
//
// Brad Whitlock, Fri May 6 13:41:20 PDT 2011
// Do not reduce the topological dimension anymore.
//
// ****************************************************************************
void
......@@ -269,7 +277,6 @@ avtCylinderFilter::UpdateDataObjectInfo(void)
avtDataAttributes &outAtts = GetOutput()->GetInfo().GetAttributes();
avtDataValidity &outValidity = GetOutput()->GetInfo().GetValidity();
outAtts.SetTopologicalDimension(inAtts.GetTopologicalDimension()-1);
outValidity.InvalidateZones();
outValidity.ZonesSplit();
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment