Commit 8b65d830 authored by hrchilds's avatar hrchilds
Browse files

Update from June 15, 2005

git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@485 18c085ea-50e0-402c-830e-de6fd14e8384
parent 844175fc
......@@ -839,6 +839,11 @@ avtPlot::CombinedExecute(avtDataObject_p input, avtPipelineSpecification_p spec,
// Defer more decisions to the vertex normals filter, since it has more
// information.
//
// Hank Childs, Tue Jun 14 18:17:02 PDT 2005
// Always do the relevant points when we have point meshes, since the
// glypher glyphs the points in the point list, not the vertices in the
// cell list.
//
// ****************************************************************************
avtDataObject_p
......@@ -873,6 +878,8 @@ avtPlot::ReduceGeometry(avtDataObject_p curDS)
}
condenseDatasetFilter->SetInput(rv);
if (atts.GetTopologicalDimension() == 0)
condenseDatasetFilter->BypassHeuristic(true);
rv = condenseDatasetFilter->GetOutput();
//
......
......@@ -22,6 +22,7 @@
#include <vector>
class avtCondenseDatasetFilter;
class avtDatasetToDatasetFilter;
class avtSmoothPolyDataFilter;
class avtVertexNormalsFilter;
......@@ -236,7 +237,7 @@ class PLOTTER_API avtPlot
avtTheater theater;
avtBehavior_p behavior;
avtDrawer *drawer;
avtDatasetToDatasetFilter *condenseDatasetFilter;
avtCondenseDatasetFilter *condenseDatasetFilter;
avtDatasetToDatasetFilter *ghostZoneAndFacelistFilter;
avtDatasetToDatasetFilter *compactTreeFilter;
avtDatasetToDatasetFilter *currentExtentFilter;
......
......@@ -244,6 +244,9 @@ avtKullLiteFileFormat::~avtKullLiteFileFormat()
// Hank Childs, Fri Aug 27 16:54:45 PDT 2004
// Rename ghost data array.
//
// Hank Childs, Tue Jun 14 16:31:33 PDT 2005
// Add support for RZ meshes.
//
// ****************************************************************************
void
......@@ -295,6 +298,7 @@ avtKullLiteFileFormat::ReadInPrimaryMesh(int fi)
int nPoints = (meshIs3d ? m_kullmesh3d->npnts : m_kullmesh2d->npnts);
points->SetNumberOfPoints(nPoints);
bool isRZ = IsRZ();
for (i = 0; i < nPoints; i++)
{
if (meshIs3d)
......@@ -305,9 +309,14 @@ avtKullLiteFileFormat::ReadInPrimaryMesh(int fi)
}
else
{
points->SetPoint(i,m_kullmesh2d->positions[i].x,
m_kullmesh2d->positions[i].y,
0.);
if (isRZ)
points->SetPoint(i,m_kullmesh2d->positions[i].y,
m_kullmesh2d->positions[i].x,
0.);
else
points->SetPoint(i,m_kullmesh2d->positions[i].x,
m_kullmesh2d->positions[i].y,
0.);
}
}
......@@ -1321,7 +1330,9 @@ avtKullLiteFileFormat::GetMeshTagMaterial(const char *var, int dom)
int *ptr = new int[nelems];
int index = 0;
for (j = 0 ; j < tag_list->size() ; j++)
{
for (i = 0 ; i < tags->num_tags ; i++)
{
if ((*tag_list)[j] == tags->tags[i].tagname)
{
for (k = 0 ; k < tags->tags[i].size ; k++)
......@@ -1329,6 +1340,8 @@ avtKullLiteFileFormat::GetMeshTagMaterial(const char *var, int dom)
ptr[index++] = j;
}
}
}
}
avtMaterial *mat = new avtMaterial(tag_list->size(), *tag_list, nelems,
ptr, 0, NULL, NULL, NULL, NULL);
......@@ -1424,7 +1437,7 @@ avtKullLiteFileFormat::GetRealMaterial(int domain)
}
// Now we go through the materials, and deal with them accordingly.
for (i = 0; i < num_materials; ++i)
for (i = 0; i < num_materials; i++)
{
string base = m_names[i];
......@@ -1574,12 +1587,16 @@ avtKullLiteFileFormat::GetRealMaterial(int domain)
// Kathleen Bonnell, Wed Aug 25 11:21:56 PDT 2004
// Set mesh-type for node_tags to AVT_POINT_MESH.
//
// Hank Childs, Tue Jun 14 16:25:52 PDT 2005
// Add support for RZ meshes.
//
// ****************************************************************************
void
avtKullLiteFileFormat::PopulateDatabaseMetaData(avtDatabaseMetaData *md)
{
bool is3DMesh = true;
bool isRZ = false;
if (my_filenames.size() > 0)
{
m_pdbFile = PD_open((char *) my_filenames[0].c_str(), "r");
......@@ -1590,6 +1607,8 @@ avtKullLiteFileFormat::PopulateDatabaseMetaData(avtDatabaseMetaData *md)
}
is3DMesh = GetMeshDimension();
if (!is3DMesh)
isRZ = IsRZ();
Close();
}
......@@ -1608,6 +1627,11 @@ avtKullLiteFileFormat::PopulateDatabaseMetaData(avtDatabaseMetaData *md)
mesh->blockTitle = "Files";
mesh->blockNames = vFilenames;
mesh->hasSpatialExtents = false;
if (isRZ)
{
mesh->xLabel = "Z-Axis";
mesh->yLabel = "R-Axis";
}
md->Add(mesh);
if (NumberOfMaterials())
......@@ -2155,3 +2179,23 @@ avtKullLiteFileFormat::GetMeshDimension(void)
}
// ****************************************************************************
// Method: avtKullLiteFileFormat::IsRZ
//
// Purpose:
// Determines if a mesh is RZ.
//
// Returns: True if it is RZ, false otherwise.
//
// Programmer: Hank Childs
// Creation: June 14, 2005
//
// ****************************************************************************
bool
avtKullLiteFileFormat::IsRZ(void)
{
return (PD_inquire_type(m_pdbFile, "rz") ? true : false);
}
......@@ -41,6 +41,9 @@ class vtkUnstructuredGrid;
// Hank Childs, Mon Jul 26 08:59:40 PDT 2004
// Add support for mesh tags.
//
// Hank Childs, Tue Jun 14 16:31:33 PDT 2005
// Add support for IsRZ.
//
// ****************************************************************************
class avtKullLiteFileFormat : public avtSTMDFileFormat
......@@ -105,6 +108,7 @@ class avtKullLiteFileFormat : public avtSTMDFileFormat
void ReadInMaterialName(int);
bool ReadMeshFromFile(void);
bool GetMeshDimension(void);
bool IsRZ(void);
bool ClassifyAndAdd2DZone(pdb_mesh2d *, int,
vtkUnstructuredGrid *);
......
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