Class Solid
A Solid is a IGeoObject implementation that represents a solid body.
Its main data is a collection of oriented faces. The normal vector on any point of the face
points to the outside of the body. Solids have one set of faces that represent the outer hull
and any number of cavities that reside totally inside the outer hull. All cavyties are disjoint.
Inheritance
System.Object
Solid
Implements
System.IComparable
System.ICloneable
System.Runtime.Serialization.ISerializable
System.Runtime.Serialization.IDeserializationCallback
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Assembly: CADability.dll
Syntax
[Serializable]
public class Solid : IGeoObjectImpl, IGeoObject, ILayer, IStyle, IOctTreeInsertable, IComparable, IFeedBack, ICloneable, ISerializable, IColorDef, IGetSubShapes, IGeoObjectOwner, IDeserializationCallback, IJsonSerialize, IJsonSerializeDone, IExportStep
Constructors
|
Improve this Doc
View Source
Solid()
Declaration
|
Improve this Doc
View Source
Solid(SerializationInfo, StreamingContext)
Declaration
protected Solid(SerializationInfo info, StreamingContext context)
Parameters
| Type |
Name |
Description |
| System.Runtime.Serialization.SerializationInfo |
info |
|
| System.Runtime.Serialization.StreamingContext |
context |
|
Fields
|
Improve this Doc
View Source
Constructed
Declaration
public static Solid.ConstructedDelegate Constructed
Field Value
|
Improve this Doc
View Source
Constructor
Declaration
public static Solid.ConstructionDelegate Constructor
Field Value
|
Improve this Doc
View Source
OnPaintTo3D
Declaration
public static Solid.PaintTo3DDelegate OnPaintTo3D
Field Value
Properties
|
Improve this Doc
View Source
ColorDef
Declaration
public ColorDef ColorDef { get; set; }
Property Value
|
Improve this Doc
View Source
Description
Declaration
public override string Description { get; }
Property Value
| Type |
Description |
| System.String |
|
Overrides
|
Improve this Doc
View Source
Edges
Returns all the edges of this Shell. Each egde is unique in the array
but may belong to two different faces.
Declaration
public Edge[] Edges { get; }
Property Value
|
Improve this Doc
View Source
Layer
Declaration
public override Layer Layer { get; set; }
Property Value
Overrides
|
Improve this Doc
View Source
Name
Declaration
public string Name { get; set; }
Property Value
| Type |
Description |
| System.String |
|
|
Improve this Doc
View Source
NameOrEmpty
Declaration
public string NameOrEmpty { get; }
Property Value
| Type |
Description |
| System.String |
|
|
Improve this Doc
View Source
OwnedItems
Declaration
public override IGeoObject[] OwnedItems { get; }
Property Value
Overrides
|
Improve this Doc
View Source
PreferredStyle
Declaration
public override Style.EDefaultFor PreferredStyle { get; }
Property Value
Overrides
|
Improve this Doc
View Source
Shells
Returns a list of all shells that bound this solid. In most cases there is only a single shell.
If there is more than one shell the shell with index 0 is the outer hull and all subsequent shells
describe cavyties that reside totally inside the outer hull.
Declaration
public Shell[] Shells { get; }
Property Value
Methods
|
Improve this Doc
View Source
Clone()
Declaration
public override IGeoObject Clone()
Returns
Overrides
|
Improve this Doc
View Source
Construct()
Declaration
public static Solid Construct()
Returns
|
Improve this Doc
View Source
CopyGeometry(IGeoObject)
Declaration
public override void CopyGeometry(IGeoObject ToCopyFrom)
Parameters
Overrides
|
Improve this Doc
View Source
Decompose()
Declaration
public override GeoObjectList Decompose()
Returns
Overrides
|
Improve this Doc
View Source
FindSnapPoint(SnapPointFinder)
Declaration
public override void FindSnapPoint(SnapPointFinder spf)
Parameters
Overrides
|
Improve this Doc
View Source
FreeCachedMemory()
Declaration
public void FreeCachedMemory()
|
Improve this Doc
View Source
GetBoundingCube()
Declaration
public override BoundingCube GetBoundingCube()
Returns
Overrides
|
Improve this Doc
View Source
GetExtent(Projection, ExtentPrecision)
Declaration
public override BoundingRect GetExtent(Projection projection, ExtentPrecision extentPrecision)
Parameters
Returns
Overrides
|
Improve this Doc
View Source
GetExtent(Double)
Declaration
public override BoundingCube GetExtent(double precision)
Parameters
| Type |
Name |
Description |
| System.Double |
precision |
|
Returns
Overrides
|
Improve this Doc
View Source
GetPlaneIntersection(PlaneSurface)
Returns the curves that result from a planar intersection of this shell with the provided plane.
The curves are properly clipped.
Declaration
public ICurve[] GetPlaneIntersection(PlaneSurface pl)
Parameters
| Type |
Name |
Description |
| PlaneSurface |
pl |
The plane to intersect with
|
Returns
| Type |
Description |
| ICurve[] |
Array of intersection curves
|
|
Improve this Doc
View Source
GetQuadTreeItem(Projection, ExtentPrecision)
Declaration
public override IQuadTreeInsertableZ GetQuadTreeItem(Projection projection, ExtentPrecision extentPrecision)
Parameters
Returns
Overrides
|
Improve this Doc
View Source
GetShowProperties(IFrame)
Declaration
public override IShowProperty GetShowProperties(IFrame Frame)
Parameters
| Type |
Name |
Description |
| IFrame |
Frame |
|
Returns
Overrides
|
Improve this Doc
View Source
HitTest(ref BoundingCube, Double)
Declaration
public override bool HitTest(ref BoundingCube cube, double precision)
Parameters
| Type |
Name |
Description |
| BoundingCube |
cube |
|
| System.Double |
precision |
|
Returns
| Type |
Description |
| System.Boolean |
|
Overrides
|
Improve this Doc
View Source
HitTest(Projection, BoundingRect, Boolean)
Declaration
public override bool HitTest(Projection projection, BoundingRect rect, bool onlyInside)
Parameters
Returns
| Type |
Description |
| System.Boolean |
|
Overrides
|
Improve this Doc
View Source
HitTest(Projection.PickArea, Boolean)
Declaration
public override bool HitTest(Projection.PickArea area, bool onlyInside)
Parameters
Returns
| Type |
Description |
| System.Boolean |
|
Overrides
|
Improve this Doc
View Source
Intersect(Solid, Solid)
Returns the intersection of two solids, i.e. those parts that are common to both solids. If the
solids are disjunct, an empty array is returned. There may be more than one solid body as a restult.
Declaration
public static Solid[] Intersect(Solid solid1, Solid solid2)
Parameters
| Type |
Name |
Description |
| Solid |
solid1 |
first solid
|
| Solid |
solid2 |
second solid
|
Returns
| Type |
Description |
| Solid[] |
array of common parts
|
|
Improve this Doc
View Source
MakeSolid(Shell)
Declaration
public static Solid MakeSolid(Shell sh)
Parameters
| Type |
Name |
Description |
| Shell |
sh |
|
Returns
|
Improve this Doc
View Source
Modify(ModOp)
Declaration
public override void Modify(ModOp m)
Parameters
| Type |
Name |
Description |
| ModOp |
m |
|
Overrides
|
Improve this Doc
View Source
PaintTo3D(IPaintTo3D)
Declaration
public override void PaintTo3D(IPaintTo3D paintTo3D)
Parameters
Overrides
|
Improve this Doc
View Source
PaintTo3DList(IPaintTo3D, ICategorizedDislayLists)
Declaration
public override void PaintTo3DList(IPaintTo3D paintTo3D, ICategorizedDislayLists lists)
Parameters
Overrides
|
Improve this Doc
View Source
Position(GeoPoint, GeoVector, Double)
Declaration
public override double Position(GeoPoint fromHere, GeoVector direction, double precision)
Parameters
Returns
| Type |
Description |
| System.Double |
|
Overrides
|
Improve this Doc
View Source
PrepareDisplayList(Double)
Declaration
public override void PrepareDisplayList(double precision)
Parameters
| Type |
Name |
Description |
| System.Double |
precision |
|
Overrides
|
Improve this Doc
View Source
RemoveShell(Shell)
Declaration
protected void RemoveShell(Shell sh)
Parameters
| Type |
Name |
Description |
| Shell |
sh |
|
|
Improve this Doc
View Source
SetFaces(Shell, Face[])
Declaration
public void SetFaces(Shell sh, Face[] faces)
Parameters
|
Improve this Doc
View Source
SetShell(Shell)
Declaration
public void SetShell(Shell sh)
Parameters
| Type |
Name |
Description |
| Shell |
sh |
|
|
Improve this Doc
View Source
SplitByPlane(Plane)
Declaration
public Solid[] SplitByPlane(Plane pln)
Parameters
| Type |
Name |
Description |
| Plane |
pln |
|
Returns
|
Improve this Doc
View Source
Subtract(Solid, Solid)
Returns the difference of two solids. The second solid is removed from the first solid. If the
solids are disjunct, (a clone of the) the first solid is returned. If the second solid contains the
first solid, an empty array is returned.
Declaration
public static Solid[] Subtract(Solid first, Solid second)
Parameters
| Type |
Name |
Description |
| Solid |
first |
first solid
|
| Solid |
second |
second solid
|
Returns
| Type |
Description |
| Solid[] |
the difference
|
|
Improve this Doc
View Source
Unite(Solid, Solid)
Unites the two solids and returns the union. If the solids are disjunct, null is returned.
Declaration
public static Solid Unite(Solid solid1, Solid solid2)
Parameters
| Type |
Name |
Description |
| Solid |
solid1 |
first solid
|
| Solid |
solid2 |
second solid
|
Returns
| Type |
Description |
| Solid |
union or null
|
|
Improve this Doc
View Source
Volume(Double)
Returns the volume of this solid. the calculation is based on a triangulation with at least the provided precision.
Declaration
public double Volume(double precision)
Parameters
| Type |
Name |
Description |
| System.Double |
precision |
The precision of the triangulation
|
Returns
| Type |
Description |
| System.Double |
|
Explicit Interface Implementations
|
Improve this Doc
View Source
IColorDef.SetTopLevel(ColorDef)
Declaration
void IColorDef.SetTopLevel(ColorDef newValue)
Parameters
|
Improve this Doc
View Source
IColorDef.SetTopLevel(ColorDef, Boolean)
Declaration
void IColorDef.SetTopLevel(ColorDef newValue, bool overwriteChildNullColor)
Parameters
| Type |
Name |
Description |
| ColorDef |
newValue |
|
| System.Boolean |
overwriteChildNullColor |
|
|
Improve this Doc
View Source
IGeoObjectOwner.Add(IGeoObject)
Declaration
void IGeoObjectOwner.Add(IGeoObject toAdd)
Parameters
|
Improve this Doc
View Source
IGeoObjectOwner.Remove(IGeoObject)
Declaration
void IGeoObjectOwner.Remove(IGeoObject toRemove)
Parameters
|
Improve this Doc
View Source
IExportStep.Export(ExportStep, Boolean)
Declaration
int IExportStep.Export(ExportStep export, bool topLevel)
Parameters
| Type |
Name |
Description |
| ExportStep |
export |
|
| System.Boolean |
topLevel |
|
Returns
| Type |
Description |
| System.Int32 |
|
|
Improve this Doc
View Source
IJsonSerialize.GetObjectData(IJsonWriteData)
Declaration
void IJsonSerialize.GetObjectData(IJsonWriteData data)
Parameters
|
Improve this Doc
View Source
IJsonSerialize.SetObjectData(IJsonReadData)
Declaration
void IJsonSerialize.SetObjectData(IJsonReadData data)
Parameters
|
Improve this Doc
View Source
IJsonSerializeDone.SerializationDone()
Declaration
void IJsonSerializeDone.SerializationDone()
|
Improve this Doc
View Source
IDeserializationCallback.OnDeserialization(Object)
Declaration
void IDeserializationCallback.OnDeserialization(object sender)
Parameters
| Type |
Name |
Description |
| System.Object |
sender |
|
|
Improve this Doc
View Source
ISerializable.GetObjectData(SerializationInfo, StreamingContext)
Declaration
void ISerializable.GetObjectData(SerializationInfo info, StreamingContext context)
Parameters
| Type |
Name |
Description |
| System.Runtime.Serialization.SerializationInfo |
info |
|
| System.Runtime.Serialization.StreamingContext |
context |
|
Implements
System.IComparable
System.ICloneable
System.Runtime.Serialization.ISerializable
System.Runtime.Serialization.IDeserializationCallback