SbXfBox3f(3)
π SbXfBox3f β the manual page, bestie edition π
okay so bestie, welcome to the SbXfBox3f page from the Coin manual. The SbXfBox3f class is a 3 dimensional box with floating point coordinates and an attached transformation. yes she's a box AND she has a whole transformation matrix attached to her. main character behavior fr fr. π
β¨ SYNOPSIS β¨
#include <Inheritor/SbXfBox3f.h>
wait no, let me not do that to you, the actual line is:
#include <Inventor/SbXfBox3f.h>
She Inherits SbBox3f. π
πΈ Public Member Functions πΈ
SbXfBox3f(void)SbXfBox3f(const SbVec3f &boxmin, const SbVec3f &boxmax)SbXfBox3f(const SbBox3f &box)~SbXfBox3f()void setTransform(const SbMatrix &m)const SbMatrix & getTransform(void) constconst SbMatrix & getInverse(void) constSbVec3f getCenter(void) constvoid extendBy(const SbVec3f &pt)void extendBy(const SbBox3f &bb)void extendBy(const SbXfBox3f &bb)SbBool intersect(const SbVec3f &pt) constSbBool intersect(const SbBox3f &bb) constSbBool intersect(const SbXfBox3f &bb) constvoid getSpan(const SbVec3f &direction, float &dMin, float &dMax) constSbBox3f project(void) constvoid transform(const SbMatrix &m)float getVolume(void) constvoid print(FILE *file) const
π¦ Public Member Functions inherited from SbBox3f π¦
she got all this from her mom, no cap:
SbBox3f(void)SbBox3f(float xmin, float ymin, float zmin, float xmax, float ymax, float zmax)SbBox3f(const SbVec3f &minpoint, const SbVec3f &maxpoint)SbBox3f(const SbBox3d &box)SbBox3f(const SbBox3s &box)SbBox3f(const SbBox3i32 &box)SbBox3f & setBounds(float xmin, float ymin, float zmin, float xmax, float ymax, float zmax)SbBox3f & setBounds(const SbVec3f &minpoint, const SbVec3f &maxpoint)SbBox3f & setBounds(const SbBox3d &box)SbBox3f & setBounds(const SbBox3s &box)SbBox3f & setBounds(const SbBox3i32 &box)void getBounds(float &xmin, float &ymin, float &zmin, float &xmax, float &ymax, float &zmax) constvoid getBounds(SbVec3f &minpoint, SbVec3f &maxpoint) constconst SbVec3f & getMin(void) constSbVec3f & getMin(void)const SbVec3f & getMax(void) constSbVec3f & getMax(void)void extendBy(const SbVec3f &pt)void extendBy(const SbBox3f &box)void transform(const SbMatrix &matrix)void makeEmpty(void)SbBool isEmpty(void) constSbBool hasVolume(void) constfloat getVolume(void) constSbBool intersect(const SbVec3f &pt) constSbBool intersect(const SbBox3f &box) constSbVec3f getClosestPoint(const SbVec3f &point) constSbBool outside(const SbMatrix &mvp, int &cullbits) constSbVec3f getCenter(void) constvoid getOrigin(float &originX, float &originY, float &originZ) constvoid getSize(float &sizeX, float &sizeY, float &sizeZ) constSbVec3f getSize(void) constvoid getSpan(const SbVec3f &dir, float &dmin, float &dmax) constvoid print(FILE *file) const
π Additional Inherited Members π
Related Symbols inherited from SbBox3f:
int operator==(const SbBox3f &b1, const SbBox3f &b2)int operator!=(const SbBox3f &b1, const SbBox3f &b2)
π Detailed Description π
The SbXfBox3f class is a 3 dimensional box with floating point coordinates and an attached transformation. periodt.
This box class is used by many other classes in Coin for data exchange. It provides storage for two box corners with floating point coordinates, and for a floating point 4x4 transformation matrix. so she's holding the corners AND the matrix, she's booked and busy. π
See also: SbBox2s, SbBox2f, SbBox2d, SbBox3s, SbBox3f, SbBox3d, SbMatrix.
π Constructor & Destructor Documentation π
SbXfBox3f::SbXfBox3f(void)
The default constructor makes an empty box and an identity matrix. fresh out the box, literally. β¨
SbXfBox3f::SbXfBox3f(const SbVec3f & boxmin, const SbVec3f & boxmax)
Constructs a box with the given corners.
The coordinates of min should be less than the coordinates of max if you want to make a valid box. lowkey important bestie, don't come for me when your box is invalid π
SbXfBox3f::SbXfBox3f(const SbBox3f & box)
Constructs a box from the given SbBox3f.
The transformation is set to the identity matrix. she gets adopted and immediately gets an identity glow-up π
SbXfBox3f::~SbXfBox3f()
Default destructor does nothing. she just... leaves. no drama, no cleanup. iconic. π
β Member Function Documentation β
void SbXfBox3f::setTransform(const SbMatrix & m)
Sets the transformation to the given SbMatrix. glow-up: applied. β¨
const SbMatrix & SbXfBox3f::getTransform(void) const
Returns the current transformation matrix.
const SbMatrix & SbXfBox3f::getInverse(void) const
Returns the inverse of the current transformation matrix. the un-glow-up π
SbVec3f SbXfBox3f::getCenter(void) const
Return the transformed center point of the box. not the regular center, the transformed one, okay? she went through the matrix.
void SbXfBox3f::extendBy(const SbVec3f & pt)
Extend the boundaries of the box by the given point, i.e. make the point fit inside the box if it isn't already so. she's making room, she's accommodating, she's a hostess π«Ά
The point is assumed to be in transformed space.
void SbXfBox3f::extendBy(const SbBox3f & bb)
Extend the boundaries of the box by the given bb parameter. The given box is assumed to be in transformed space.
The two given boxes will be combined in such a way so that the resultant bounding box always has the smallest possible volume. To accomplish this, the transformation on this SbXfBox3f will sometimes be flattened before it is combined with bb. she'll flatten herself for the optimal result, that's dedication fr fr.
void SbXfBox3f::extendBy(const SbXfBox3f & bb)
Extend the boundaries of the box by the given bb parameter.
The given box is assumed to be in transformed space.
Note: is not guaranteed to give an optimal result if used for bounding box calculation since the transformation matrix might change. See documentation inSoGetBoundingBoxActionfor more details. so like, it might be mid, just saying π go readSoGetBoundingBoxActionif you need the tea.
SbBool SbXfBox3f::intersect(const SbVec3f & pt) const
Check if the given point lies within the boundaries of this box.
The point is assumed to be in transformed space.
SbBool SbXfBox3f::intersect(const SbBox3f & bb) const
Check if the given box lies entirely or partially within the boundaries of this box.
The given box is assumed to be in transformed space.
SbBool SbXfBox3f::intersect(const SbXfBox3f & xfbb) const
Check if two transformed boxes intersect. do they vibe? do they overlap? we find out π
This function is an extension for Coin, and it is not available in the original SGI Open Inventor v2.1 API. so if you're on the old-school SGI build, she doesn't exist, sorry bestie π«Ά
Since: Coin 2.0
void SbXfBox3f::getSpan(const SbVec3f & direction, float & dMin, float & dMax) const
Find the span of the box in the given direction (i.e. how much room in the given direction the box needs). The distance is returned as the minimum and maximum distance from origo to the closest and furthest plane defined by the direction vector and each of the box' corners. The difference between these values gives the span. so like, dMax minus dMin, that's the span, math is mathing β¨
SbBox3f SbXfBox3f::project(void) const
Project the SbXfBox3f into a SbBox3f. she's shedding the transformation layer, going back to basics.
This gives the same resulting SbBox3f as doing a SbBox3f::transform() with this transformation matrix as parameter. same result, different route, iykyk π¦
void SbXfBox3f::transform(const SbMatrix & m)
Overridden from SbBox3f, as the transformations are to be kept separate from the box in the SbXfBox3f class. she's not merging her identity with the matrix, she's keeping it separate. boundaries, bestie. π
float SbXfBox3f::getVolume(void) const
Return box volume. Overridden from parent class to take into account the possibility of scaling in the transformation matrix. so the volume can get scaled and she accounts for it, she's thorough like that.
void SbXfBox3f::print(FILE * fp) const
Dump the state of this object to the fp file stream.
Only works in debug version of library, method does nothing in an optimized build. so in release mode she's silent. a mystery. an enigma. π
π Author π
Generated automatically by Doxygen for Coin from the source code. yes she was auto-generated, and she still ate. π€β¨
and that's the whole page bestie!! Version <b>4.0.10</b>, dated <b>Thu Jun 25 2026 00:00:00</b> β that's the footer, we're not copying it, we're shouting it out. go build something cute with your transformed boxes πππ¦πΈ
π¦ where this page comes from
- fedora 43: Coin4-devel 4.0.10-1.fc43 Β· BSD-3-Clause AND GPL-3.0-or-later
- fedora 43: Coin4-devel 4.0.10-1.fc43 Β· BSD-3-Clause AND GPL-3.0-or-later
- fedora 44: Coin4-devel 4.0.10-1.fc44 Β· BSD-3-Clause AND GPL-3.0-or-later
- fedora 44: Coin4-devel 4.0.10-1.fc44 Β· BSD-3-Clause AND GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms