Commit eb506fbd authored by Ken Martin's avatar Ken Martin
Browse files

ENH: cleaned up comments

parent d12c27da
......@@ -41,6 +41,7 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
// .NAME vtk3DSImporter - imports 3D Studio files.
// .SECTION Description
// vtk3DSImporter imports 3D Studio files into vtk.
// .SECTION See Also
// vtkImporter
......
......@@ -69,23 +69,23 @@ class vtkRenderer;
class VTK_EXPORT vtkActor : public vtkProp
{
public:
vtkActor();
~vtkActor();
const char *GetClassName() {return "vtkActor";};
void PrintSelf(ostream& os, vtkIndent indent);
// Description:
// Creates an actor with the following defaults: origin(0,0,0)
// position=(0,0,0) scale=(1,1,1) visibility=1 pickable=1 dragable=1
// orientation=(0,0,0). No user defined matrix and no texture map.
vtkActor();
~vtkActor();
static vtkActor *New();
const char *GetClassName() {return "vtkActor";};
void PrintSelf(ostream& os, vtkIndent indent);
// Description:
// This causes the actor to be rendered. It in turn will render the
// actor's property, texture map and then mapper. If a property
// hasn't been assigned, then the actor will create one
// automatically. Note that a side effect of this method is that the
// This causes the actor to be rendered. It in turn will render the actor's
// property, texture map and then mapper. If a property hasn't been
// assigned, then the actor will create one automatically. Note that a side
// effect of this method is that the
virtual void Render(vtkRenderer *ren);
virtual void Render(vtkRenderer *, vtkMapper *) {};
// Description:
......@@ -93,22 +93,26 @@ class VTK_EXPORT vtkActor : public vtkProp
vtkActor &operator=(const vtkActor& actor);
// Description:
// Set/Get the property object that controls this
// actors surface properties. This should be an instance of a
// vtkProperty object. Every actor must have a property associated
// with it. If one isn't specified, then one will be generated
// automatically. Multiple actors can share one property object.
// Set/Get the property object that controls this actors surface
// properties. This should be an instance of a vtkProperty object. Every
// actor must have a property associated with it. If one isn't specified,
// then one will be generated automatically. Multiple actors can share one
// property object.
void SetProperty(vtkProperty *lut);
vtkProperty *GetProperty();
// Description:
// Set/Get the property object that controls this actors backface surface
// properties. This should be an instance of a vtkProperty object. If one
// isn't specified, then the front face properties will be used. Multiple
// actors can share one property object.
void SetBackfaceProperty(vtkProperty *lut);
vtkProperty *GetBackfaceProperty();
// Description:
// Set/Get the texture object to control rendering
// texture maps. This will be a vtkTexture object. An actor does
// not need to have an associated texture map and multiple actors
// can share one texture.
// Set/Get the texture object to control rendering texture maps. This will
// be a vtkTexture object. An actor does not need to have an associated
// texture map and multiple actors can share one texture.
vtkSetObjectMacro(Texture,vtkTexture);
vtkGetObjectMacro(Texture,vtkTexture);
......@@ -130,9 +134,8 @@ class VTK_EXPORT vtkActor : public vtkProp
vtkGetVectorMacro(Scale,float,3);
// Description:
// Get the matrix from the position, origin, scale and orientation
// This matrix is cached, so multiple GetMatrix() calls will be
// efficient.
// Get the matrix from the position, origin, scale and orientation This
// matrix is cached, so multiple GetMatrix() calls will be efficient.
void GetMatrix(vtkMatrix4x4 *m);
// Description:
......@@ -171,7 +174,10 @@ class VTK_EXPORT vtkActor : public vtkProp
// necessary.
virtual void Update();
unsigned long int GetMTime();//overload superclasses' implementation
// Description:
// Get the actors mtime plus consider its properties, texture and
// usermatrix if set.
unsigned long int GetMTime();
// Description:
// The renderer may use the allocated rendering time to determine
......
......@@ -59,44 +59,48 @@ class VTK_EXPORT vtkActorCollection : public vtkCollection
static vtkActorCollection *New() {return new vtkActorCollection;};
const char *GetClassName() {return "vtkActorCollection";};
// Description:
// Add an actor to the list.
void AddItem(vtkActor *a);
// Description:
// Remove an actor from the list.
void RemoveItem(vtkActor *a);
// Description:
// Determine whether a particular actor is present. Returns its position
// in the list.
int IsItemPresent(vtkActor *a);
// Description:
// Get the next actor in the list.
vtkActor *GetNextItem();
// Description:
// Get the last actor in the list.
vtkActor *GetLastItem();
};
// Description:
// Add an actor to the list.
inline void vtkActorCollection::AddItem(vtkActor *a)
{
this->vtkCollection::AddItem((vtkObject *)a);
}
// Description:
// Remove an actor from the list.
inline void vtkActorCollection::RemoveItem(vtkActor *a)
{
this->vtkCollection::RemoveItem((vtkObject *)a);
}
// Description:
// Determine whether a particular actor is present. Returns its position
// in the list.
inline int vtkActorCollection::IsItemPresent(vtkActor *a)
{
return this->vtkCollection::IsItemPresent((vtkObject *)a);
}
// Description:
// Get the next actor in the list.
inline vtkActor *vtkActorCollection::GetNextItem()
{
return (vtkActor *)(this->GetNextItemAsObject());
}
// Description:
// Get the last actor in the list.
inline vtkActor *vtkActorCollection::GetLastItem()
{
if ( this->Bottom == NULL )
......
......@@ -46,6 +46,7 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
// only if all datasets have the point attributes available. (For example,
// if one dataset has scalars but another does not, scalars will not be
// appended.)
// .SECTION See Also
// vtkAppendPolyData
......@@ -73,7 +74,9 @@ public:
// Remove a dataset from the list of data to append.
void RemoveInput(vtkDataSet *in);
void RemoveInput(vtkDataSet& in) {this->RemoveInput(&in);}
// Description:
// Return the list of inputs to this filter.
vtkDataSetCollection *GetInputList() {return this->InputList;}
// filter interface
......
......@@ -46,6 +46,7 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
// and appended only if all datasets have the point attributes available.
// (For example, if one dataset has scalars but another does not, scalars
// will not be appended.)
// .SECTION See Also
// vtkAppendFilter
......@@ -68,17 +69,20 @@ public:
// Description:
// Add a dataset to the list of data to append.
void AddInput(vtkPolyData *);
void AddInput(vtkPolyData& in) {this->AddInput(&in);};
// Description:
// Remove a dataset from the list of data to append.
void RemoveInput(vtkPolyData *);
void RemoveInput(vtkPolyData& in) {this->RemoveInput(&in);};
// Description
// Return the list of inputs to this filter.
vtkPolyDataCollection *GetInput() {return this->InputList;};
// filter interface
// Description:
// Override the default Update method since this filter has multiple
// inputs.
void Update();
// Description:
......
......@@ -56,10 +56,11 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
// list of actors. This is because they are automatically renderered
// during the hierarchical traversal process.
//
// Since a vtkAssembly object is a derived class of vtkActor, it has properties
// and possibly a mapper. During the rendering process, if a mapper is associated
// with the assembly, it is rendered with these properties. Otherwise, the
// properties have no effect (i.e., on the children of the assembly).
// Since a vtkAssembly object is a derived class of vtkActor, it has
// properties and possibly a mapper. During the rendering process, if a
// mapper is associated with the assembly, it is rendered with these
// properties. Otherwise, the properties have no effect (i.e., on the
// children of the assembly).
// .SECTION Caveats
// Collections of assemblies are slower to render than an equivalent list
......@@ -85,15 +86,12 @@ class vtkAssemblyPaths;
class VTK_EXPORT vtkAssembly : public vtkActor
{
public:
// Description:
// Construct object with no children.
vtkAssembly();
~vtkAssembly();
static vtkAssembly *New() {return new vtkAssembly;};
const char *GetClassName() {return "vtkAssembly";};
void PrintSelf(ostream& os, vtkIndent indent);
// Description:
// Add a part to the list of parts.
void AddPart(vtkActor *);
......@@ -102,6 +100,8 @@ public:
// Remove a part from the list of parts,
void RemovePart(vtkActor *);
// Description:
// Return the parts of this asembly.
vtkActorCollection *GetParts();
// Description:
......@@ -128,14 +128,22 @@ public:
vtkActor *GetNextPart();
int GetNumberOfParts();
// Description:
// Build assembly paths from this current assembly. Paths consist of
// an ordered sequence of actors, with transformations properly concatenated.
void BuildPaths(vtkAssemblyPaths *paths, vtkActorCollection *path);
void ApplyProperties(); //recursive application of properties
// Description:
// Recursively apply properties to parts.
void ApplyProperties();
// Description:
// Get the bounds for the assembly as (Xmin,Xmax,Ymin,Ymax,Zmin,Zmax).
float *GetBounds();
// Description:
// Override default GetMTime method to also consider all of the
// assembly's parts.
unsigned long int GetMTime();
// Description:
......
......@@ -60,36 +60,39 @@ class VTK_EXPORT vtkAssemblyPaths : public vtkCollection
static vtkAssemblyPaths *New() {return new vtkAssemblyPaths;};
const char *GetClassName() {return "vtkAssemblyPaths";};
// Description:
// Add a path to the list.
void AddItem(vtkActorCollection *a);
// Description:
// Remove a path from the list.
void RemoveItem(vtkActorCollection *a);
// Description:
// Determine whether a particular path is present. Returns its position
// in the list.
int IsItemPresent(vtkActorCollection *a);
// Description:
// Get the next path in the list.
vtkActorCollection *GetNextItem();
};
// Description:
// Add a path to the list.
inline void vtkAssemblyPaths::AddItem(vtkActorCollection *a)
{
this->vtkCollection::AddItem((vtkObject *)a);
}
// Description:
// Remove a path from the list.
inline void vtkAssemblyPaths::RemoveItem(vtkActorCollection *a)
{
this->vtkCollection::RemoveItem((vtkObject *)a);
}
// Description:
// Determine whether a particular path is present. Returns its position
// in the list.
inline int vtkAssemblyPaths::IsItemPresent(vtkActorCollection *a)
{
return this->vtkCollection::IsItemPresent((vtkObject *)a);
}
// Description:
// Get the next path in the list.
inline vtkActorCollection *vtkAssemblyPaths::GetNextItem()
{
return (vtkActorCollection *)(this->GetNextItemAsObject());
......
......@@ -40,11 +40,10 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
=========================================================================*/
// .NAME vtkAxes - create an x-y-z axes
// .SECTION Description
// vtkAxes creates three lines that form an x-y-z axes. The origin of the
// axes is user specified (0,0,0 is default), and the size is specified
// with a scale factor. Three scalar values are generated for the three
// lines and can be used (via color map) to indicate a particular
// coordinate axis.
// vtkAxes creates three lines that form an x-y-z axes. The origin of the
// axes is user specified (0,0,0 is default), and the size is specified with
// a scale factor. Three scalar values are generated for the three lines and
// can be used (via color map) to indicate a particular coordinate axis.
#ifndef __vtkAxes_h
#define __vtkAxes_h
......@@ -54,11 +53,7 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
class VTK_EXPORT vtkAxes : public vtkPolyDataSource
{
public:
// Description:
// Construct with origin=(0,0,0) and scale factor=1.
vtkAxes();
static vtkAxes *New() {return new vtkAxes;};
const char *GetClassName() {return "vtkAxes";};
void PrintSelf(ostream& os, vtkIndent indent);
......
......@@ -82,23 +82,25 @@ public:
// Description:
// Turn on/off the reading of the displacement file.
vtkSetMacro(ReadDisplacement,int)
vtkGetMacro(ReadDisplacement,int)
vtkBooleanMacro(ReadDisplacement,int)
vtkSetMacro(ReadDisplacement,int);
vtkGetMacro(ReadDisplacement,int);
vtkBooleanMacro(ReadDisplacement,int);
// Description:
// Turn on/off the reading of the scalar file.
vtkSetMacro(ReadScalar,int)
vtkGetMacro(ReadScalar,int)
vtkBooleanMacro(ReadScalar,int)
vtkSetMacro(ReadScalar,int);
vtkGetMacro(ReadScalar,int);
vtkBooleanMacro(ReadScalar,int);
// Description:
// Turn on/off the reading of the texture coordinate file.
// Specify name of geometry FileName.
vtkSetMacro(ReadTexture,int)
vtkGetMacro(ReadTexture,int)
vtkBooleanMacro(ReadTexture,int)
vtkSetMacro(ReadTexture,int);
vtkGetMacro(ReadTexture,int);
vtkBooleanMacro(ReadTexture,int);
// Description:
// Set/Get the part number to be read.
vtkSetClampMacro(PartNumber,int,1,VTK_LARGE_INTEGER);
vtkGetMacro(PartNumber,int);
......
......@@ -59,12 +59,7 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
class VTK_EXPORT vtkBYUWriter : public vtkPolyDataWriter
{
public:
// Description:
// Create object so that it writes displacement, scalar, and texture files
// (if data is available).
vtkBYUWriter();
~vtkBYUWriter();
static vtkBYUWriter *New() {return new vtkBYUWriter;};
const char *GetClassName() {return "vtkBYUWriter";};
......
......@@ -39,6 +39,7 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
=========================================================================*/
// .NAME vtkBooleanTexture - generate 2D texture map based on combinations of inside, outside, and on region boundary
// .SECTION Description
// vtkBooleanTexture is a filter to generate a 2D texture map based on
// combinations of inside, outside, and on region boundary. The "region" is
......@@ -59,6 +60,7 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
// and/or opacity use the value 255. A minimum value of 0 results in
// a black region (for intensity) and a fully transparent region (for
// transparency).
// .SECTION See Also
// vtkImplicitTextureCoords vtkThresholdTextureCoords
......
/*=========================================================================
Program: Visualization Toolkit
Module: BrownPts.h
Module: vtkBrownianPoints.h
Language: C++
Date: 9/14/94
Version: 1.1
Date: $Date$
Version: $Revision$
Copyright (c) 1993-1998 Ken Martin, Will Schroeder, Bill Lorensen.
......
......@@ -58,10 +58,10 @@ class vtkRenderer;
class VTK_EXPORT vtkCamera : public vtkObject
{
public:
vtkCamera();
~vtkCamera();
void PrintSelf(ostream& os, vtkIndent indent);
const char *GetClassName() {return "vtkCamera";};
// Description:
// Construct camera instance with its focal point at the origin,
......@@ -69,8 +69,6 @@ class VTK_EXPORT vtkCamera : public vtkObject
// view angle is 30 degrees, and the clipping range is (.1,1000).
static vtkCamera *New();
const char *GetClassName() {return "vtkCamera";};
// Description:
// Set/Get the position of the camera in world coordinates.
void SetPosition(float x, float y, float z);
......@@ -144,6 +142,10 @@ class VTK_EXPORT vtkCamera : public vtkObject
vtkSetMacro(FocalDisk,float);
vtkGetMacro(FocalDisk,float);
// Description:
// Set/Get whether this is the left eye's render or the right eye's.
// This is normally only used in stereo rendering and is handled
// automatically.
vtkSetMacro(LeftEye,int);
vtkGetMacro(LeftEye,int);
......@@ -152,14 +154,12 @@ class VTK_EXPORT vtkCamera : public vtkObject
// to adjust the back clipping plane to be equal to the front clipping plane
// plus the thickness.
void SetThickness(float);
vtkGetMacro(Thickness,float);
// Description:
// Set the distance of the focal point from the camera. The focal point is
// modified accordingly. This should be positive.
void SetDistance(float);
vtkGetMacro(Distance,float);
// Description:
......@@ -175,16 +175,15 @@ class VTK_EXPORT vtkCamera : public vtkObject
this->ViewingRaysModified();
}
}
vtkGetMacro(ParallelProjection,int);
vtkBooleanMacro(ParallelProjection,int);
void SetViewPlaneNormal(float a[3]);
// Description:
// Set the direction that the camera points.
// Set/Get the direction that the camera points.
// Adjusts position to be consistent with the view plane normal.
void SetViewPlaneNormal(float x, float y, float z);
void SetViewPlaneNormal(float a[3]);
vtkGetVectorMacro(ViewPlaneNormal,float,3);
// Description:
// Compute the view plane normal from the position and focal point.
......@@ -220,8 +219,6 @@ class VTK_EXPORT vtkCamera : public vtkObject
vtkMatrix4x4 &GetCompositePerspectiveTransform(float aspect,
float nearz, float farz);
vtkGetVectorMacro(ViewPlaneNormal,float,3);
// Description:
// Set the roll angle of the camera about the view plane normal.
void SetRoll(float);
......@@ -230,7 +227,6 @@ class VTK_EXPORT vtkCamera : public vtkObject
// Rotate the camera around the view plane normal.
void Roll(float);
// Description:
// Returns the roll of the camera.
float GetRoll();
......@@ -281,8 +277,14 @@ class VTK_EXPORT vtkCamera : public vtkObject
// Returns the WXYZ orientation of the camera.
float *GetOrientationWXYZ();
unsigned long int GetViewingRaysMTime();
void ViewingRaysModified();
// Description:
// Return the MTime that concerns recomputing the view rays of the camera.
unsigned long GetViewingRaysMTime();
// Description:
// Mark that something has changed which requires the view rays
// to be recomputed.
void ViewingRaysModified();
// Description:
// Get the plane equations that bound the view frustum.
......
......@@ -40,9 +40,11 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
=========================================================================*/
// .NAME vtkCardinalSpline - computes an interpolating spline using a
// a Cardinal basis.
// .SECTION Description
// vtkCardinalSpline is a concrete implementation of vtkSpline using a
// Cardinal basis.
// .SECTION See Also
// vtkSpline vtkKochanekSpline
......@@ -55,21 +57,15 @@ MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS.
class VTK_EXPORT vtkCardinalSpline : public vtkSpline
{
public:
// Description:
// Construct a Cardinal Spline.
vtkCardinalSpline();
static vtkCardinalSpline *New() {return new vtkCardinalSpline;};
const char *GetClassName() {return "vtkCardinalSpline";};
void PrintSelf(ostream& os, vtkIndent indent);
// Description
// Compute Cardinal Splines for each dependent variable
// Description
// Compute Cardinal Splines for each dependent variable
void Compute ();
// Description:
// Evaluate a 1D cardinal spline.
float Evaluate (float t);
......
......@@ -75,59 +75,45 @@ class VTK_EXPORT vtkCastToConcrete : public vtkDataSetFilter
{
public:
// Description:
// Construct object.
vtkCastToConcrete();
~vtkCastToConcrete();
static vtkCastToConcrete *New() {return new vtkCastToConcrete;};
const char *GetClassName() {return "vtkCastToConcrete";};
// filter interface (special pass-thru)
// Description:
// Special method just passes Update through pipeline.
// Description:
// Special method just passes Update through pipeline.
void Update();
// Description:
// Get the output of this filter. If output is NULL then input hasn't been set
// which is necessary for abstract objects.
// Description:
// Get the output of this filter. If output is NULL then input hasn't been
// set which is necessary for abstract objects.
vtkDataSet *GetOutput();
// Description:
// Get the output of this filter as type vtkPolyData. Performs run-time
// checking on type. Returns NULL if wrong type.
// Description:
// Get the output of this filter as type vtkPolyData. Performs run-time
// checking on type. Returns NULL if wrong type.
vtkPolyData *GetPolyDataOutput();
// Description:
// Get the output of this filter as type vtkStructuredPoints. Performs run-time
// checking on type. Returns NULL if wrong type.
// Description:
// Get the output of this filter as type vtkStructuredPoints. Performs
// run-time checking on type. Returns NULL if wrong type.
vtkStructuredPoints *GetStructuredPointsOutput();
// Description:
// Get the output of this filter as type vtkStructuredGrid. Performs run-time
// checking on type. Returns NULL if wrong type.
// Description:
// Get the output of this filter as type vtkStructuredGrid. Performs
// run-time checking on type. Returns NULL if wrong type.
vtkStructuredGrid *GetStructuredGridOutput();
// Description:
// Get the output of this filter as type vtkUnstructuredGrid. Performs run-time
// checking on type. Returns NULL if wrong type.
// Description:
// Get the output of this filter as type vtkUnstructuredGrid. Performs
// run-time checking on type. Returns NULL if wrong type.