gz/math/Material.hh
void SetToNearestDensity(const double _value, const double _epsilon=std::numeric_limits< double >::max())
Set this Material to the built-in Material with the nearest density value within _epsilon....
Definition: gz/math/AdditivelySeparableScalarField3.hh:27
STL class.
Contains information about a single material.
Definition: gz/math/Material.hh:65
void SetName(const std::string &_name)
Set the name of the material.
std::string Name() const
Get the name of the material. This will match the enum type names used in MaterialType,...
double Density() const
Get the density value of the material in kg/m^3.
STL class.
void SetType(const MaterialType _type)
Set the material's type. This will only set the type value. Other properties, such as density,...
bool operator==(const Material &_material) const
Equality operator. This compares type and density values.
bool operator!=(const Material &_material) const
Inequality operator. This compares type and density values.
MaterialType
This enum lists the supported material types. A value can be used to create a Material instance....
Definition: gz/math/MaterialType.hh:37
void SetDensity(const double _density)
Set the density value of the material in kg/m^3.
static const std::map< MaterialType, Material > & Predefined()
Get all the built-in materials.