SbVec3d(3)
π SbVec3d π
okay bestie, gather round, because we're talking about SbVec3d from the Library Functions Manual β a three-dimensional vector with double precision floating point coordinates. she's precise, she's dimensional, she's lowkey the moment. β¨
β¨ NAME β¨
SbVec3d β the class that is a 3 dimensional vector with double precision floating point coordinates. that's her whole job and she eats every time π
πΈ SYNOPSIS πΈ
#include <Inventor/SbLinear.h>
π Public Member Functions
SbVec3d (void)
SbVec3d (const double v[3])
SbVec3d (double x, double y, double z)
SbVec3d (const SbVec3f &v)
SbVec3d (const SbVec3b &v)
SbVec3d (const SbVec3s &v)
SbVec3d (const SbVec3i32 &v)
SbVec3d (const SbDPPlane &p0, const SbDPPlane &p1, const SbDPPlane &p2)
SbVec3d & setValue (const double v[3])
SbVec3d & setValue (double x, double y, double z)
SbVec3d & setValue (const SbVec3d &barycentric, const SbVec3d &v0, const
SbVec3d &v1, const SbVec3d &v2)
SbVec3d & setValue (const SbVec3f &v)
SbVec3d & setValue (const SbVec3b &v)
SbVec3d & setValue (const SbVec3s &v)
SbVec3d & setValue (const SbVec3i32 &v)
const double * getValue (void) const
void getValue (double &x, double &y, double &z) const
double & operator[] (const int i)
const double & operator[] (const int i) const
SbVec3d cross (const SbVec3d &v) const
double dot (const SbVec3d &v) const
SbBool equals (const SbVec3d &v, double tolerance) const
SbVec3d getClosestAxis (void) const
double length (void) const
double sqrLength (void) const
void negate (void)
double normalize (void)
SbVec3d & operator*= (double d)
SbVec3d & operator/= (double d)
SbVec3d & operator+= (const SbVec3d &v)
SbVec3d & operator-= (const SbVec3d &v)
SbVec3d operator- (void) const
void print (FILE *fp) const
π¦ Related Symbols
(quick note bestie β these are not member symbols, okay? they're the friends of the family π«Ά)
SbVec3d operator* (const SbVec3d &v, double d)
SbVec3d operator* (double d, const SbVec3d &v)
SbVec3d operator/ (const SbVec3d &v, double d)
SbVec3d operator+ (const SbVec3d &v1, const SbVec3d &v2)
SbVec3d operator- (const SbVec3d &v1, const SbVec3d &v2)
int operator== (const SbVec3d &v1, const SbVec3d &v2)
int operator!= (const SbVec3d &v1, const SbVec3d &v2)
π Detailed Description π
so. SbVec3d is a 3 dimensional vector with double precision floating point coordinates. periodt.
this vector class gives you storage for a 3 dimensional double precision floating point vector aswell as simple floating point arithmetic operations. storage AND math? she's versatile, she contains multitudes π
See also: SbVec2s, SbVec2f, SbVec2d, SbVec3s, SbVec3f, SbVec4f, SbVec4d. the whole friend group, iconic.
Since:
- Coin 2.0
- TGS Inventor 2.6
π§ Constructor & Destructor Documentation π§
SbVec3d::SbVec3d (void ) [inline]
the default constructor does nothing. like, literally nothing. the vector coordinates will be uninitialized until you do a setValue() call. so don't come for her expecting values she never promised you π call setValue() first, bestie.
SbVec3d::SbVec3d (const double v[3]) [inline]
constructs an SbVec3d instance with initial values from v. cute, efficient, done.
SbVec3d::SbVec3d (double x, double y, double z) [inline]
constructs an SbVec3d instance with the initial vector endpoint set to <x,y,z>. she knows exactly where she's going π
SbVec3d::SbVec3d (const SbVec3f & v) [inline], [explicit]
constructs an SbVec3d instance from an SbVec3f instance. glow-up from single to double precision, we love a transformation arc β¨
SbVec3d::SbVec3d (const SbVec3b & v) [inline], [explicit]
constructs an SbVec3d instance from an SbVec3b instance.
note: \Coin 2.5
SbVec3d::SbVec3d (const SbVec3s & v) [inline], [explicit]
constructs an SbVec3d instance from an SbVec3s instance.
note: \Coin 2.5
SbVec3d::SbVec3i32 β okay no wait, it's SbVec3d::SbVec3d (const SbVec3i32 & v) [inline], [explicit]
constructs an SbVec3d instance from an SbVec3i32 instance.
note: \Coin 2.5
SbVec3d::SbVec3d (const SbDPPlane & p0, const SbDPPlane & p1, const SbDPPlane & p2)
constructs an SbVec3d instance by combining the three given planes.
warning bestie!! none of the planes should be parallel to any of the other two β otherwise a divide by zero error will occur. that's not a vibe check, that's a crash. π
π Member Function Documentation π
SbVec3d & SbVec3d::setValue (const double v[3]) [inline]
set new coordinates for the vector from v. returns reference to self (she's generous like that π«Ά).
See also: getValue().
SbVec3d & SbVec3d::setValue (double x, double y, double z) [inline]
set new coordinates for the vector. returns reference to self.
See also: getValue().
SbVec3d & SbVec3d::setValue (const SbVec3d & barycentric, const SbVec3d & v0, const SbVec3d & v1, const SbVec3d & v2)
set this vector to be the average of v0, v1 and v2. the vector components are weighted by the barycentric vector. math but make it fashion π
See also: getValue().
SbVec3d & SbVec3d::setValue (const SbVec3f & v)
sets this vector to the single precision vector v, converting the vector to a double precision vector. upgrade szn π
SbVec3d & SbVec3d::setValue (const SbVec3b & v)
sets this vector to the vector v.
note: \Coin 2.5
SbVec3d & SbVec3d::setValue (const SbVec3s & v)
sets this vector to the vector v.
note: \Coin 2.5
SbVec3d & SbVec3d::setValue (const SbVec3i32 & v)
sets this vector to the vector v.
note: \Coin 2.5
const double * SbVec3d::getValue (void ) const [inline]
returns a pointer to an array of three doubles containing the x, y and z coordinates of the vector. here's your data, bestie, take it π
See also: setValue().
void SbVec3d::getValue (double & x, double & y, double & z) const [inline]
returns the x, y and z coordinates of the vector.
See also: setValue().
double & SbVec3d::operator[] (const int i) [inline]
index operator. returns modifiable x, y or z coordinate of vector. yes you can touch her, she's editable π
See also: getValue() and setValue().
const double & SbVec3d::operator[] (const int i) const [inline]
index operator. returns x, y or z coordinate of vector. look but don't touch, this one's const π
See also: getValue() and setValue().
SbVec3d SbVec3d::cross (const SbVec3d & v) const
returns the result of taking the cross product of this vector and v.
double SbVec3d::dot (const SbVec3d & v) const [inline]
calculates and returns the result of taking the dot product of this vector and v.
SbBool SbVec3d::equals (const SbVec3d & v, double tolerance) const
compares the vector with v and returns TRUE if the distance between the vectors is smaller or equal to the square root of tolerance. yes, the square root. not the tolerance itself. read it again. i'll wait β
SbVec3d SbVec3d::getClosestAxis (void ) const
return the vector representing the principal axis closest to this vector. she finds her nearest axis, she's social like that π¦
double SbVec3d::length (void ) const
return length of vector.
double SbVec3d::sqrLength (void ) const [inline]
returns the squared length of the vector. (the name literally tells you. no cap.)
void SbVec3d::negate (void ) [inline]
negate the vector (i.e. point it in the opposite direction). full 180, main character energy π₯
double SbVec3d::normalize (void )
normalize the vector to unit length. return value is the original length of the vector before normalization. so you get the glow-up and the receipt π
if the vector is the null vector, no attempt at normalization will be done. she said "not today" and honestly, valid.
SbVec3d & SbVec3d::operator*= (double d) [inline]
multiply components of vector with value d. returns reference to self.
SbVec3d & SbVec3d::operator/= (double d) [inline]
divides components of vector with value d. returns reference to self.
SbVec3d & SbVec3d::operator+= (const SbVec3d & v) [inline]
adds this vector and vector v. returns reference to self.
SbVec3d & SbVec3d::operator-= (const SbVec3d & v) [inline]
subtracts vector v from this vector. returns reference to self.
SbVec3d SbVec3d::operator- (void ) const [inline]
non-destructive negation operator. returns a new SbVec3d instance which points in the opposite direction of this vector. she flips the vibe without changing herself, that's growth π±
See also: negate().
void SbVec3d::print (FILE * fp) const
dump the state of this object to the file stream.
heads up: this only works in debug version of library β the method does nothing in an optimized compile. so if you're printing and getting silence, it's not you, it's the build π
π Friends And Related Symbol Documentation π
SbVec3d operator* (const SbVec3d & v, double d) [related]
returns an SbVec3d instance which is the components of vector v multiplied with d.
SbVec3d operator* (double d, const SbVec3d & v) [related]
returns an SbVec3d instance which is the components of vector v multiplied with d. (yes it's the same thing with the args flipped β commutative queen π
)
SbVec3d operator/ (const SbVec3d & v, double d) [related]
returns an SbVec3d instance which is the components of vector v divided on the scalar factor d.
SbVec3d operator+ (const SbVec3d & v1, const SbVec3d & v2) [related]
returns an SbVec3d instance which is the sum of vectors v1 and v2.
SbVec3d operator- (const SbVec3d & v1, const SbVec3d & v2) [related]
returns an SbVec3d instance which is vector v2 subtracted from vector v1.
int operator== (const SbVec3d & v1, const SbVec3d & v2) [related]
returns 1 if v1 and v2 are exactly equal, 0 otherwise. exactly exactly. no tolerance, no wiggle room, she's strict π€
See also: equals().
int operator!= (const SbVec3d & v1, const SbVec3d & v2) [related]
returns 1 if v1 and v2 are not equal, 0 if they are equal.
See also: equals().
π Author π
Generated automatically by Doxygen for Coin from the source code. (not a human, just a robot doing its little thing π€β¨)
okay that's the whole page bestie, you ate it, go forth and vector π
sign-off time π«Ά this lil manual page lives under Coin, Version 3.1.3, and its whole name is SbVec3d(3) β that's the header title and the footer energy all rolled into one. love her, use her, initialize her before you read her. mwah π
π¦ where this page comes from
- fedora 43: Coin3-devel 3.1.3-40.fc43 Β· GPL-2.0-only
- fedora 43: Coin3-devel 3.1.3-40.fc43 Β· GPL-2.0-only
- fedora 44: Coin3-devel 3.1.3-42.fc44 Β· GPL-2.0-only
- fedora 44: Coin3-devel 3.1.3-42.fc44 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms