Click or drag to resize

Vector3 Structure

3 dimensional vector of doubles.

Namespace:  Karamba.Geometry
Assembly:  KarambaCommon (in KarambaCommon.dll) Version: 2.2.0.4 (2.2.0.4)
Syntax
[SerializableAttribute]
public struct Vector3 : IEquatable<Vector3>, 
	IComparable<Vector3>

The Vector3 type exposes the following members.

Constructors
  NameDescription
Public methodVector3(Vec3d)
Initializes a new instance of the Vector3 struct. transform C++-vector into C#-vector.
Public methodVector3(Point3)
Initializes a new instance of the Vector3 struct. Create vector from point.
Public methodVector3(Vector3)
Initializes a new instance of the Vector3 struct. Create vector from vector.
Public methodVector3(Double, Double, Double)
Initializes a new instance of the Vector3 struct. Create vector.
Top
Properties
  NameDescription
Public propertyIsNaN
Gets a value indicating whether this vector is NaN vector.
Public propertyIsZero
Gets a value indicating whether this vector is the zero vector.
Public propertyItem
Gets or sets a vector component at the given index.
Public propertyLength
Gets the length of vector.
Public propertyStatic memberNaN
Gets an NaN vector.
Public propertySquaredLength
Gets the squared length of vector.
Public propertyUnitized
Gets the normalized vector.
Public propertyStatic memberUnitX
Gets the x-unit vector (1, 0, 0).
Public propertyStatic memberUnitY
Gets the y-unit vector (0, 1, 0).
Public propertyStatic memberUnitZ
Gets the z-unit vector (0, 0, 1).
Public propertyX
Gets or sets the X-coordinate.
Public propertyStatic memberXAxis
Gets the value of the vector with components 1,0,0.
Public propertyY
Gets or sets the Y-coordinate.
Public propertyStatic memberYAxis
Gets the value of the vector with components 0,1,0.
Public propertyZ
Gets or sets the Z-coordinate.
Public propertyStatic memberZAxis
Gets the value of the vector with components 0,0,1.
Public propertyStatic memberZero
Gets the zero vector.
Top
Methods
  NameDescription
Public methodCompareTo
compares this to other vector based on the distance to the origin.
Public methodStatic memberCross
Get the cross product of two vectors.
Public methodStatic memberCrossProduct
Compute cross product.
Public methodStatic memberDot
Compute dot product.
Public methodStatic memberDotProduct
Compute dot product.
Public methodEquals(Object)
Indicates whether this instance and a specified object are equal.
(Overrides ValueTypeEquals(Object).)
Public methodEquals(Vector3)
check whether another vector is equal to this vector.
Public methodEquals(Vector3, Double)
check whether another vector is equal to this vector within a given tolerance.
Public methodGetHashCode
Returns the hash code for this instance.
(Overrides ValueTypeGetHashCode.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodIsTiny
Determines whether the vector is small.
Public methodMakePerpendicularTo
Makes this vector perpendicular to the given vector. Result is not unitized.
Public methodStatic membermeanSquaredLength
Gets the mean squared length of vectors in a list.
Public methodStatic memberMultiply(Vector3, Vector3)
Form the dot-product of two vectors.
Public methodStatic memberMultiply(Vector3, Double)
multiply a vector by a scalar.
Public methodStatic memberNormalize
Returns a vector with the same direction as the given vector, but with a length of 1.
Public methodReverse
reverse the direction of a vector.
Public methodRotate
Rotates vector by an angle about a given axis.
Public methodStatic memberScaleVectors
Scales the vectors in a list by a given factor and returns the new list.
Public methodToDeg
Convert angle in radians to degree.
Public methodToPoint3
Converts to Point3.
Public methodToRad
Convert angle in degree to radians.
Public methodToString
Returns the fully qualified type name of this instance.
(Overrides ValueTypeToString.)
Public methodTransform(Plane3)
Transform vector to local coordinate system of given plane.
Public methodTransform(Transform3)
Transform vector.
Public methodStatic memberTransform(Vector3, Quaternion)
Transforms a vector by the given Quaternion rotation value.
Public methodUnitize
Normalizes a vector.
Public methodStatic memberVectorAngle
Compute the angle between two vectors.

This operation is commutative.

Top
Operators
  NameDescription
Public operatorStatic memberAddition
Adds two vectors.
Public operatorStatic memberDivision
Divide vector by constant.
Public operatorStatic memberEquality
Compare vectors for equality.
Public operatorStatic memberExclusiveOr
Compute vector cross product.
Public operatorStatic memberGreaterThan
Compare vectors.
Public operatorStatic memberGreaterThanOrEqual
Compare vectors.
Public operatorStatic memberInequality
Compare vectors for inequality.
Public operatorStatic memberLessThan
Compare vectors.
Public operatorStatic memberLessThanOrEqual
Compare vectors.
Public operatorStatic memberMultiply(Double, Vector3)
Multiply vector by constant.
Public operatorStatic memberMultiply(Vector3, Vector3)
Multiply vectors (dot product).
Public operatorStatic memberMultiply(Vector3, Double)
Multiply vector by constant.
Public operatorStatic memberSubtraction
Subtracts vector b from vector a.
Public operatorStatic memberUnaryNegation
Negates a vector.
Top
Extension Methods
  NameDescription
Public Extension MethodConvert
Converts to Rhino's Vector3d.
(Defined by ToRhino.)
Public Extension MethodConvertToFebVec3dOverloaded.
Converts to Vec3d.
(Defined by ToFeb.)
Public Extension MethodConvertToFebVec3d(Boolean)Overloaded.
Converts to Vec3d.
(Defined by ToFeb.)
Top
See Also