|
Avara3D 0.2.0
C++ API reference
|
Box mesh element centered at the origin. More...
#include <a3d/mesh/primitive/Box.h>
Public Member Functions | |
| Box (float width, float height, float length, unsigned widthSegments=DEFAULT_SEGMENTS, unsigned heightSegments=DEFAULT_SEGMENTS, unsigned lengthSegments=DEFAULT_SEGMENTS) | |
| Generates box geometry with the supplied dimensions and subdivision counts. More... | |
| float | length () const |
| Returns the configured box length along Z. More... | |
| float | width () const |
| Returns the configured box width along X. More... | |
| float | height () const |
| Returns the configured box height along Y. More... | |
| unsigned | lengthSegments () const |
| Returns the stored length subdivision count. More... | |
| unsigned | widthSegments () const |
| Returns the stored width subdivision count. More... | |
| unsigned | heightSegments () const |
| Returns the stored height subdivision count. More... | |
Public Member Functions inherited from a3d::MeshElement | |
| MeshElement (VertexLayout layout, std::span< const std::byte > vertexBytes, uint32_t vertexCount, uint16_t vertexStride, PrimitiveTopology topology, IndexFormat indexFormat, std::span< const std::byte > indexBytes, uint32_t indexCount) | |
| Creates a MeshElement by copying the supplied vertex and index data. More... | |
Static Public Member Functions | |
| static std::shared_ptr< Mesh > | Mesh (float width, float height, float length, unsigned widthSegments=DEFAULT_SEGMENTS, unsigned heightSegments=DEFAULT_SEGMENTS, unsigned lengthSegments=DEFAULT_SEGMENTS, std::shared_ptr< Material > material=nullptr) |
Creates a Mesh containing a Box and optional material. More... | |
Box mesh element centered at the origin.
Width spans the X axis, height spans Y, and length spans Z.
| a3d::Box::Box | ( | float | width, |
| float | height, | ||
| float | length, | ||
| unsigned | widthSegments = DEFAULT_SEGMENTS, |
||
| unsigned | heightSegments = DEFAULT_SEGMENTS, |
||
| unsigned | lengthSegments = DEFAULT_SEGMENTS |
||
| ) |
Generates box geometry with the supplied dimensions and subdivision counts.
| float a3d::Box::height | ( | ) | const |
Returns the configured box height along Y.
| unsigned a3d::Box::heightSegments | ( | ) | const |
Returns the stored height subdivision count.
| float a3d::Box::length | ( | ) | const |
Returns the configured box length along Z.
| unsigned a3d::Box::lengthSegments | ( | ) | const |
Returns the stored length subdivision count.
| float a3d::Box::width | ( | ) | const |
Returns the configured box width along X.
| unsigned a3d::Box::widthSegments | ( | ) | const |
Returns the stored width subdivision count.