Visual Computing Library
|
The Quality class represents a component that stores the quality of a mesh element, that is represented by a scalar. More...
#include <vclib/mesh/components/quality.h>
Public Types | |
using | QualityType = Scalar |
Exposes the scalar used as Quality type. | |
Public Member Functions | |
Quality ()=default | |
Initilizes the Quality value to 0. | |
const QualityType & | quality () const |
Returns a const reference of the quality of the element. | |
QualityType & | quality () |
Returns a reference of the quality of the element. | |
Protected Member Functions | |
template<typename Element > | |
void | importFrom (const Element &e, bool=true) |
void | serialize (std::ostream &os) const |
void | deserialize (std::istream &is) |
Private Types | |
using | Base = Component< Quality< Scalar, ParentElemType, OPT >, CompId::QUALITY, Scalar, ParentElemType, !std::is_same_v< ParentElemType, void >, OPT > |
The Quality class represents a component that stores the quality of a mesh element, that is represented by a scalar.
This scalar is actually used for a lot of different purposes, depending on the applications.
For example, if you have a Vertex Element v
with the Quality component, you'll be able to access to this component member functions from v
:
Scalar | The scalar type of the Quality value. |
ParentElemType | This template argument must be void if the component needs to be stored horizontally, or the type of the parent element that will contain this component if the component needs to be stored vertically. |
OPT | If true, the component will be optional. This argument is considered only if the component is stored vertically. |
|
inline |
Returns a reference of the quality of the element.
|
inline |
Returns a const reference of the quality of the element.