Point3f
Represents the three coordinates of a point in three-dimensional space, using Single-precision floating point numbers.
Namespace: Rhino.Geometry
Assembly: RhinoCommon (in RhinoCommon.dll)
Syntax
[SerializableAttribute]public struct Point3f : IEquatable<Point3f>, IComparable<Point3f>, IComparable, IEpsilonFComparable<Point3f>, IFormattable
The Point3f type exposes the following members.
Constructors
Name
Description
Public Method
Point3f
Initializes a new two-dimensional vector from two components.
Properties
Name
Description
Public Property
IsValid
Each coordinate of the point must pass the
IsValidSingle(Single)
test.Public Property
Static Member
Origin
Gets the value of a point at location 0,0,0.
Public Property
Static Member
Unset
Gets the value of a point at location RhinoMath.UnsetValue,RhinoMath.UnsetValue,RhinoMath.UnsetValue.
Public Property
X
Gets or sets the X (first) component of the vector.
Public Property
Y
Gets or sets the Y (second) component of the vector.
Public Property
Z
Gets or sets the Z (third) component of the vector.
Methods
Name
Description
Public Method
CompareTo
Compares this Point3f with another Point3f.
Component evaluation priority is first X, then Y, then Z.
Public Method
Code Example
DistanceTo
Computes the distance between two points.
Public Method
DistanceToSquared
Computes the squared distance between two points.
Public Method
EpsilonEquals
Check that all values in other are within epsilon of the values in this
Public Method
Equals(Object)
Determines whether the specified System.Object is a Point3f and has the same values as the present point.
(Overrides ValueType.Equals(Object).)
Public Method
Equals(Point3f)
Determines whether the specified Point3f has the same values as the present point.
Public Method
GetHashCode
Computes a hash code for the present point.
(Overrides ValueType.GetHashCode..)
Public Method
GetType
Gets the Type of the current instance.
(Inherited from Object.)
Public Method
Static Member
Subtract
Subtracts a point from another point.
(Provided for languages that do not support operator overloading. You can use the - operator otherwise)
Public Method
ToString.
Constructs the string representation for the current point.
(Overrides ValueType.ToString..)
Public Method
ToString(String, IFormatProvider)
Formats the value of the current instance using the specified format.
Public Method
Transform
Transforms the present point in place. The transformation matrix acts on the left of the point. i.e.,
result = transformation*point
Operators
Name
Description
Public Operator
Static Member
Addition
Adds a point to another point.
Public Operator
Static Member
Equality
Determines whether two points have equal values.
Public Operator
Static Member
.(Point3d to Point3f)
Converts a double-precision point in a single-precision point. Needs explicit casting to help retain precision.
Public Operator
Static Member
.(Point3f to Vector3f)
Converts a single-precision point in a single-precision vector. Needs explicit casting to help retain precision.
Public Operator
Static Member
GreaterThan
Determines whether the first specified point comes after (has superior sorting value than) the second point.
Coordinates evaluation priority is first X, then Y, then Z.
Public Operator
Static Member
GreaterThanOrEqual
Determines whether the first specified point comes after (has superior sorting value than) the second point, or it is equal to it.
Coordinates evaluation priority is first X, then Y, then Z.
Public Operator
Static Member
Inequality
Determines whether two points have different values.
Public Operator
Static Member
LessThan
Determines whether the first specified point comes before (has inferior sorting value than) the second point.
Coordinates evaluation priority is first X, then Y, then Z.
Public Operator
Static Member
LessThanOrEqual
Determines whether the first specified point comes before (has inferior sorting value than) the second point, or it is equal to it.
Coordinates evaluation priority is first X, then Y, then Z.
Public Operator
Static Member
Multiply(Point3f, Single)
Multiplies a point by a factor.
Public Operator
Static Member
Multiply(Single, Point3f)
Multiplies a point by a factor.
Public Operator
Static Member
Subtraction
Subtracts a point from another point.