|
minimc 0.5.1
|
A sphere. What else has to be said? More...
#include <CSGSurface.hpp>


Public Member Functions | |
| Sphere (const pugi::xml_node &sphere_node) noexcept | |
Constructs a Sphere from a sphere node of an XML document. More... | |
| Real | Distance (const Point &origin, const Direction &direction) const noexcept override |
| Returns the distance from a given origin Point to the Sphere along a given Direction using the line-sphere intersection algorithm More... | |
| bool | Contains (const Point &p) const noexcept override |
| Implements CSGSurface method. More... | |
Public Member Functions inherited from CSGSurface | |
| virtual | ~CSGSurface () noexcept |
| Virtual destructor (C++ Core Guidelines C.127) | |
| virtual bool | Contains (const Point &p) const noexcept=0 |
| Returns true if Point is in the "negative" side of the (open) surface. A point on the surface or outside is considered to be on the "positive" side. More... | |
| virtual Real | Distance (const Point &origin, const Direction &direction) const noexcept=0 |
| Return the distance from a given origin Point to the CSGSurface along a given Direction. More... | |
Additional Inherited Members | |
Static Public Member Functions inherited from CSGSurface | |
| static std::unique_ptr< const CSGSurface > | Create (const pugi::xml_node &root, const std::string &name) |
| Factory method to create new CSGSurface from an XML document. More... | |
Public Attributes inherited from CSGSurface | |
| const std::string | name |
| Unique, user-defined identifier (C++ Core Guidelines C.131) | |
Protected Member Functions inherited from CSGSurface | |
| CSGSurface (const pugi::xml_node &surface_node) noexcept | |
| Constructs a CSGSurface from a surface node of an XML document. More... | |
Static Protected Member Functions inherited from CSGSurface | |
| static Real | SolveQuadratic (Real a, Real b, Real c) noexcept |
| Specialized form of quadratic equation solver. More... | |
A sphere. What else has to be said?
|
noexcept |
Constructs a Sphere from a sphere node of an XML document.
| sphere_node | The requested sphere node in the XML document |
|
overridevirtualnoexcept |
Implements CSGSurface method.
Implements CSGSurface.
|
overridevirtualnoexcept |
Returns the distance from a given origin Point to the Sphere along a given Direction using the line-sphere intersection algorithm
| origin | Starting point from where distance will be calculated. |
| direction | Unit vector. Must be normalized to unity. |
Implements CSGSurface.