Commit bf9f211b authored by Will Schroeder's avatar Will Schroeder
Browse files

*** empty log message ***

parent 7820b3f4
......@@ -29,8 +29,9 @@ class vlFloatTCoords : public vlTCoords
public:
vlFloatTCoords() {};
vlTCoords *MakeObject(int sze, int d=2, int ext=1000);
int Initialize(const int sz, const int dim=2, const int ext=1000)
{return this->TC.Initialize(dim*sz,dim*ext);};
int Allocate(const int sz, const int dim=2, const int ext=1000)
{return this->TC.Allocate(dim*sz,dim*ext);};
void Initialize() {return this->TC.Initialize();};
vlFloatTCoords(const vlFloatTCoords& ftc)
{this->TC = ftc.TC;this->Dimension = ftc.Dimension;};
vlFloatTCoords(int sz, int d=2, int ext=1000):TC(d*sz,d*ext)
......
......@@ -29,8 +29,9 @@ class vlFloatVectors : public vlVectors
public:
vlFloatVectors() {};
vlVectors *MakeObject(int sze, int ext=1000);
int Initialize(const int sz, const int ext=1000)
{return this->V.Initialize(3*sz,3*ext);};
int Allocate(const int sz, const int ext=1000)
{return this->V.Allocate(3*sz,3*ext);};
void Initialize() {return this->V.Initialize();};
vlFloatVectors(const vlFloatVectors& fv) {this->V = fv.V;};
vlFloatVectors(const int sz, const int ext=1000):V(3*sz,3*ext){};
~vlFloatVectors() {};
......
......@@ -24,7 +24,7 @@ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 1993, 1994
class vlFilter : virtual public vlObject
{
public:
vlFilter() : StartMethod(0), EndMethod(0), Updating(0) {};
vlFilter() : StartMethod(NULL), EndMethod(NULL), Updating(0) {};
~vlFilter() {};
char *GetClassName() {return "vlFilter";};
void PrintSelf(ostream& os, vlIndent indent);
......
......@@ -25,6 +25,8 @@ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 1993, 1994
#define SCALE_BY_SCALAR 0
#define SCALE_BY_VECTOR 1
#define ORIENT_BY_VECTOR 0
#define ORIENT_BY_NORMAL 1
class vlGlyph3D : public vlDataSetToPolyFilter
{
......@@ -34,6 +36,8 @@ public:
char *GetClassName() {return "vlGlyph3D";};
void PrintSelf(ostream& os, vlIndent indent);
void Update();
vlSetObjectMacro(Source,vlPolyData);
vlGetObjectMacro(Source,vlPolyData);
......@@ -52,13 +56,32 @@ public:
vlSetVector2Macro(Range,float);
vlGetVectorMacro(Range,float);
vlBooleanMacro(Orient,int);
vlSetMacro(Orient,int);
vlGetMacro(Orient,int);
vlSetMacro(OrientMode,int);
vlGetMacro(OrientMode,int);
void OrientByVector() {this->SetScaleMode(ORIENT_BY_VECTOR);};
void OrientByNormal() {this->SetScaleMode(ORIENT_BY_NORMAL);};
protected:
// Usual data generation method
void Execute();
// Geometry to copy to each point
vlPolyData *Source;
// Determine whether scaling of geometry is performed
int Scaling;
// Scale by scalar value or vector magnitude
int ScaleMode;
// Scale factor to use to scale geometry
float ScaleFactor;
// Range to use to perform scalar scaling
float Range[2];
// boolean controls whether to "orient" data
int Orient;
// Orient via normal or via vector data
int OrientMode;
};
#endif
......
......@@ -39,7 +39,8 @@ public:
void Contour(float value, vlFloatScalars *cellScalars,
vlFloatPoints *points, vlCellArray *verts,
vlCellArray *lines, vlCellArray *polys, vlFloatScalars *s);
int EvaluatePosition(float x[3], int& subId, float pcoords[3],
int EvaluatePosition(float x[3], float closestPoint[3],
int& subId, float pcoords[3],
float& dist2, float weights[MAX_CELL_SIZE]);
void EvaluateLocation(int& subId, float pcoords[3], float x[3],
float weights[MAX_CELL_SIZE]);
......
......@@ -30,8 +30,9 @@ class vlIntPoints : public vlPoints
public:
vlIntPoints() {};
vlPoints *MakeObject(int sze, int ext=1000);
int Initialize(const int sz, const int ext=1000)
{return this->P.Initialize(3*sz,3*ext);};
int Allocate(const int sz, const int ext=1000)
{return this->P.Allocate(3*sz,3*ext);};
void Initialize() {return this->P.Initialize();};
vlIntPoints(const vlIntPoints& fp) {this->P = fp.P;};
vlIntPoints(const int sz, const int ext=1000):P(3*sz,3*ext){};
~vlIntPoints() {};
......
......@@ -40,7 +40,8 @@ public:
vlFloatPoints *points, vlCellArray *verts,
vlCellArray *lines, vlCellArray *polys,
vlFloatScalars *s);
int EvaluatePosition(float x[3], int& subId, float pcoords[3],
int EvaluatePosition(float x[3], float closestPoint[3],
int& subId, float pcoords[3],
float& dist2, float weights[MAX_CELL_SIZE]);
void EvaluateLocation(int& subId, float pcoords[3], float x[3],
float weights[MAX_CELL_SIZE]);
......
......@@ -29,7 +29,7 @@ struct vlLink {
class vlLinkList : public vlObject {
public:
vlLinkList():Array(0),Size(0),MaxId(-1),Extend(1000) {};
vlLinkList():Array(NULL),Size(0),MaxId(-1),Extend(1000) {};
vlLinkList(int sz, int ext=1000);
~vlLinkList();
char *GetClassName() {return "vlLinkList";};
......
......@@ -39,7 +39,8 @@ public:
void Contour(float value, vlFloatScalars *cellScalars,
vlFloatPoints *points, vlCellArray *verts,
vlCellArray *lines, vlCellArray *polys, vlFloatScalars *s);
int EvaluatePosition(float x[3], int& subId, float pcoords[3],
int EvaluatePosition(float x[3], float closestPoint[3],
int& subId, float pcoords[3],
float& dist2, float weights[MAX_CELL_SIZE]);
void EvaluateLocation(int& subId, float pcoords[3], float x[3],
float weights[MAX_CELL_SIZE]);
......
......@@ -40,9 +40,10 @@ public:
float *GetPoint(int ptId) {return this->Points->GetPoint(ptId);};
// Locate cell point is in based on global coordiate and tolerance.
// Returns cellId >= 0 if inside, < 0 otherwise.
int FindCell(float x[3], float dist2);
// Locate cell based on global coordinate x and tolerance squared. If cell
// is non-Null, then search starts from this cell and looks at
// immediate neighbors. Returns cellId >= 0 if inside, < 0 otherwise.
int FindCell(float x[3], vlCell *cell, float tol2);
// some data sets are composite objects and need to check each part for MTime
unsigned long int GetMTime();
......
......@@ -24,7 +24,7 @@ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 1993, 1994
class vlPolyFilter : public vlFilter {
public:
vlPolyFilter() : Input(0) {};
vlPolyFilter() : Input(NULL) {};
~vlPolyFilter();
char *GetClassName() {return "vlPolyFilter";};
void PrintSelf(ostream& os, vlIndent indent);
......
/*=========================================================================
/*========================================================================
Program: Visualization Library
Module: PolyLine.hh
......@@ -45,7 +45,8 @@ public:
vlFloatPoints *points, vlCellArray *verts,
vlCellArray *lines, vlCellArray *polys,
vlFloatScalars *s);
int EvaluatePosition(float x[3], int& subId, float pcoords[3],
int EvaluatePosition(float x[3], float closestPoint[3],
int& subId, float pcoords[3],
float& dist2, float weights[MAX_CELL_SIZE]);
void EvaluateLocation(int& subId, float pcoords[3], float x[3],
float weights[MAX_CELL_SIZE]);
......
......@@ -39,7 +39,8 @@ public:
void Contour(float value, vlFloatScalars *cellScalars,
vlFloatPoints *points, vlCellArray *verts,
vlCellArray *lines, vlCellArray *polys, vlFloatScalars *s);
int EvaluatePosition(float x[3], int& subId, float pcoords[3],
int EvaluatePosition(float x[3], float closestPoint[3],
int& subId, float pcoords[3],
float& dist2, float weights[MAX_CELL_SIZE]);
void EvaluateLocation(int& subId, float pcoords[3], float x[3],
float weights[MAX_CELL_SIZE]);
......
......@@ -44,7 +44,8 @@ public:
void Contour(float value, vlFloatScalars *cellScalars,
vlFloatPoints *points,vlCellArray *verts,
vlCellArray *lines, vlCellArray *polys, vlFloatScalars *s);
int EvaluatePosition(float x[3], int& subId, float pcoords[3],
int EvaluatePosition(float x[3], float closestPoint[3],
int& subId, float pcoords[3],
float& dist2, float weights[MAX_CELL_SIZE]);
void EvaluateLocation(int& subId, float pcoords[3], float x[3],
float weights[MAX_CELL_SIZE]);
......
......@@ -28,7 +28,7 @@ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 1993, 1994
class vlPointData : public vlObject
{
public:
vlPointData() : Scalars(0), Vectors(0), Normals(0), TCoords(0) {};
vlPointData() : Scalars(NULL), Vectors(NULL), Normals(NULL), TCoords(NULL) {};
void Initialize();
~vlPointData();
char *GetClassName() {return "vlPointData";};
......@@ -38,11 +38,11 @@ public:
virtual void Update() {};
// use to copy data
void CopyInitialize(vlPointData* pd, int sze=0, int ext=1000, int sFlg=1, int vFlg=1, int nFlg=1, int tFlg=1);
void CopyAllocate(vlPointData* pd, int sze=0, int ext=1000, int sFlg=1, int vFlg=1, int nFlg=1, int tFlg=1);
void CopyData(vlPointData *fromPd, int fromId, int toId);
// use to interpolate data
void InterpolateInitialize(vlPointData* pd, int sze=0, int ext=1000, int sFlg=1, int vFlg=1, int nFlg=1, int tFlg=1);
void InterpolateAllocate(vlPointData* pd, int sze=0, int ext=1000, int sFlg=1, int vFlg=1, int nFlg=1, int tFlg=1);
void InterpolatePoint(vlPointData *fromPd, int toId, vlIdList *ptIds, float *weights);
// Set point data to null values
......
......@@ -39,7 +39,8 @@ public:
void Contour(float value, vlFloatScalars *cellScalars,
vlFloatPoints *points, vlCellArray *verts,
vlCellArray *lines, vlCellArray *polys, vlFloatScalars *s);
int EvaluatePosition(float x[3], int& subId, float pcoords[3],
int EvaluatePosition(float x[3], float closestPoint[3],
int& subId, float pcoords[3],
float& dist2, float weights[MAX_CELL_SIZE]);
void EvaluateLocation(int& subId, float pcoords[3], float x[3],
float weights[MAX_CELL_SIZE]);
......
......@@ -31,8 +31,9 @@ class vlShortScalars : public vlScalars
public:
vlShortScalars() {};
vlScalars *MakeObject(int sze, int ext=1000);
int Initialize(const int sz, const int ext=1000)
{return S.Initialize(sz,ext);};
int Allocate(const int sz, const int ext=1000)
{return this->S.Allocate(sz,ext);};
void Initialize() {return this->S.Initialize();};
vlShortScalars(const vlShortScalars& ss) {this->S = ss.S;};
vlShortScalars(const int sz, const int ext=1000):S(sz,ext){};
~vlShortScalars() {};
......
......@@ -27,7 +27,7 @@ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 1993, 1994
class vlSTLReader : public vlPolySource
{
public:
vlSTLReader():Filename(0) {};
vlSTLReader():Filename(NULL) {};
~vlSTLReader() {if (this->Filename) delete [] this->Filename;};
char *GetClassName() {return "vlSTLReader";};
void PrintSelf(ostream& os, vlIndent indent);
......
......@@ -24,7 +24,7 @@ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 1993, 1994
class vlSource : virtual public vlObject
{
public:
vlSource() : StartMethod(0), EndMethod(0) {};
vlSource() : StartMethod(NULL), EndMethod(NULL) {};
~vlSource() {};
char *GetClassName() {return "vlSource";};
void PrintSelf(ostream& os, vlIndent indent);
......
......@@ -22,7 +22,7 @@ Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 1993, 1994
#define __vlStructuredDataSet_h
#include "DataSet.hh"
#include "CArray.hh"
#include "BArray.hh"
#define SINGLE_POINT 0
#define X_LINE 1
......@@ -63,7 +63,7 @@ protected:
int Dimensions[3];
int DataDescription;
int Blanking;
vlCharArray *PointVisibility;
vlBitArray *PointVisibility;
};
#endif
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