C# Class Revit.SDK.Samples.CS.PointCloudEngine.PointCloudAccessBase

The base class for all IPointCloudAccess implementations in this sample.
Datei anzeigen Open project: AMEE/revit Class Usage Examples

Public Methods

Method Description
SerializeObjectData ( System.Xml.Linq.XElement rootElement ) : void

Saves the contents of the point cloud into an XML element.

Protected Methods

Method Description
AddCell ( XYZ lowerLeft, XYZ upperRight, int color ) : void

Adds a new cell to the point cloud.

AddCell ( XYZ lowerLeft, XYZ upperRight, int color, bool randomize ) : void

Adds a new cell to the point cloud.

GetOutline ( ) : Outline

Gets the outline calculated from all cells in the point cloud.

GetScale ( ) : double

Gets the scale stored for this point cloud.

PointCloudAccessBase ( ) : System

Constructs a new instance of the base class.

ReadSomePoints ( PointCloudFilter rFilter, IntPtr buffer, int nBufferSize, int startIndex ) : int

The internal implementation for point cloud read requests from Revit.

Both IPointCloudAccess.ReadPoints() and IPointSetIterator.ReadPoints() are served by this method.

SetupFrom ( System.Xml.Linq.XElement rootElement ) : void

Sets up a point cloud from an XML root element.

Private Methods

Method Description
AddCellToOutline ( PointCloudCellStorage storage ) : void

Adds a cell to the stored outline of the point cloud. If the cell boundaries extend beyond the current outline, the outline is adjusted.

Method Details

AddCell() protected method

Adds a new cell to the point cloud.
protected AddCell ( XYZ lowerLeft, XYZ upperRight, int color ) : void
lowerLeft XYZ The lower left point.
upperRight XYZ The upper right point.
color int The color.
return void

AddCell() protected method

Adds a new cell to the point cloud.
protected AddCell ( XYZ lowerLeft, XYZ upperRight, int color, bool randomize ) : void
lowerLeft XYZ The lower left point.
upperRight XYZ The upper right point.
color int The color.
randomize bool True to randomize point number and location, false for a regular arrangement of points.
return void

GetOutline() protected method

Gets the outline calculated from all cells in the point cloud.
protected GetOutline ( ) : Outline
return Outline

GetScale() protected method

Gets the scale stored for this point cloud.
protected GetScale ( ) : double
return double

PointCloudAccessBase() protected method

Constructs a new instance of the base class.
protected PointCloudAccessBase ( ) : System
return System

ReadSomePoints() protected method

The internal implementation for point cloud read requests from Revit.
Both IPointCloudAccess.ReadPoints() and IPointSetIterator.ReadPoints() are served by this method.
protected ReadSomePoints ( PointCloudFilter rFilter, IntPtr buffer, int nBufferSize, int startIndex ) : int
rFilter PointCloudFilter The point cloud filter.
buffer System.IntPtr The point cloud buffer.
nBufferSize int The maximum number of points in the buffer.
startIndex int The start index for points. Pass 0 if called from IPointCloudAccess.ReadPoints() or if this is the first /// call to IPointSetIterator.ReadPoints(). Pass the previous cumulative number of read points for second and successive calls to /// IPointSetIterator.ReadPoints().
return int

SerializeObjectData() public method

Saves the contents of the point cloud into an XML element.
public SerializeObjectData ( System.Xml.Linq.XElement rootElement ) : void
rootElement System.Xml.Linq.XElement The XML element in which to save the point cloud properties.
return void

SetupFrom() protected method

Sets up a point cloud from an XML root element.
protected SetupFrom ( System.Xml.Linq.XElement rootElement ) : void
rootElement System.Xml.Linq.XElement The root element.
return void