Click or drag to resize
SbLine Structure
Directed line in 3D.

Represents a directed line in 3D. This is a basic Open Inventor datatype that is used for representing a 3D line. It is used as input and output by a variety of Open Inventor classes.

Namespace: OIV.Inventor
Assembly: OIV.Inventor.SbLinear (in OIV.Inventor.SbLinear.dll) Version: 2025.2.2.Release.6302728a59ca92a379363e9f70e77ea11c06379f
Syntax
public struct SbLine

The SbLine type exposes the following members.

Constructors
  NameDescription
Public methodSbLine
Constructor. To struct a line from a position and direction, use
SbLine(p0, p0 + dir)
. The line is directed from p0 to p1.
Top
Methods
  NameDescription
Public methodEquals (Inherited from ValueType.)
Public methodGetClosestPoint
Returns the closest point on the line to the given point.
Public methodGetClosestPoints
Finds the two closest points between this line and line2, and loads them into ptOnThis and ptOnLine2.
Public methodGetDirection Obsolete.
Use direction property instead.
Public methodGetDirection(SbVec3f)
Gets the direction of the line.
Public methodGetHashCode (Inherited from ValueType.)
Public methodGetPosition Obsolete.
Use position property instead.
Public methodGetPosition(SbVec3f)
Gets the position of the line.
Public methodGetType (Inherited from Object.)
Public methodSetPosDir(SbVec3f, SbVec3f)
Sets line using a position and a direction vector.
Public methodSetPosDir(SbVec3f, SbVec3f)
Sets line using a position and a direction vector.
Public methodSetValue(SbVec3f, SbVec3f)
Sets line to pass through points p0 and p1.
Public methodSetValue(SbVec3f, SbVec3f)
Sets line to pass through points p0 and p1.
Public methodToString
Converts this SbLine structure to a human readable string.
(Overrides ValueTypeToString.)
Top
Properties
  NameDescription
Public propertyDirection
Gets or sets a vector indicating the direction of line. When setting the direction, the vector value is automatically normalized.
Public propertyPosition
Gets or sets a vector indicating indicating the position of line origin point.
Top
See Also