mesh_material.cpp
Go to the documentation of this file.
1 
29 
30 namespace tesseract_geometry
31 {
32 MeshMaterial::MeshMaterial(const Eigen::Vector4d& base_color_factor, // NOLINT(modernize-pass-by-value)
33  double metallic_factor,
34  double roughness_factor,
35  const Eigen::Vector4d& emissive_factor) // NOLINT(modernize-pass-by-value)
36  : base_color_factor_(base_color_factor)
37  , metallic_factor_(metallic_factor)
38  , roughness_factor_(roughness_factor)
39  , emissive_factor_(emissive_factor)
40 {
41 }
42 
43 Eigen::Vector4d MeshMaterial::getBaseColorFactor() const { return base_color_factor_; }
44 
46 
48 
49 Eigen::Vector4d MeshMaterial::getEmissiveFactor() const { return emissive_factor_; }
50 
51 MeshTexture::MeshTexture(std::shared_ptr<tesseract_common::Resource> texture_image,
52  std::shared_ptr<const tesseract_common::VectorVector2d> uvs)
53  : uvs_(std::move(uvs)), texture_image_(std::move(texture_image))
54 {
55 }
56 
57 std::shared_ptr<tesseract_common::Resource> MeshTexture::getTextureImage() const { return texture_image_; }
58 
59 const std::shared_ptr<const tesseract_common::VectorVector2d>& MeshTexture::getUVs() { return uvs_; }
60 
61 } // namespace tesseract_geometry
tesseract_geometry::MeshMaterial::getMetallicFactor
double getMetallicFactor() const
Get the Metallic Factor of the mesh (PBR parameter)
Definition: mesh_material.cpp:45
tesseract_geometry::MeshMaterial::MeshMaterial
MeshMaterial()=default
tesseract_geometry::MeshTexture::getUVs
const std::shared_ptr< const tesseract_common::VectorVector2d > & getUVs()
Get the texture UV coordinates.
Definition: mesh_material.cpp:59
tesseract_geometry::MeshMaterial::metallic_factor_
double metallic_factor_
Definition: mesh_material.h:119
resource_locator.h
tesseract_geometry::MeshMaterial::getRoughnessFactor
double getRoughnessFactor() const
Get the Roughness Factor of the mesh (PBR parameter)
Definition: mesh_material.cpp:47
tesseract_geometry::MeshTexture::getTextureImage
std::shared_ptr< tesseract_common::Resource > getTextureImage() const
Get the texture image.
Definition: mesh_material.cpp:57
tesseract_geometry::MeshTexture::texture_image_
std::shared_ptr< tesseract_common::Resource > texture_image_
Definition: mesh_material.h:172
tesseract_geometry::MeshMaterial::roughness_factor_
double roughness_factor_
Definition: mesh_material.h:120
tesseract_geometry::MeshTexture::MeshTexture
MeshTexture(std::shared_ptr< tesseract_common::Resource > texture_image, std::shared_ptr< const tesseract_common::VectorVector2d > uvs)
Construct a new MeshTexture.
Definition: mesh_material.cpp:51
mesh_material.h
Tesseract Mesh Material read from a mesh file.
tesseract_geometry::MeshTexture::uvs_
std::shared_ptr< const tesseract_common::VectorVector2d > uvs_
Definition: mesh_material.h:169
tesseract_geometry::MeshMaterial::emissive_factor_
Eigen::Vector4d emissive_factor_
Definition: mesh_material.h:121
tesseract_geometry::MeshMaterial::getBaseColorFactor
Eigen::Vector4d getBaseColorFactor() const
Get the base color of the mesh.
Definition: mesh_material.cpp:43
tesseract_geometry
Definition: fwd.h:31
tesseract_geometry::MeshMaterial::getEmissiveFactor
Eigen::Vector4d getEmissiveFactor() const
Get the emissive factor of the mesh.
Definition: mesh_material.cpp:49
tesseract_geometry::MeshMaterial::base_color_factor_
Eigen::Vector4d base_color_factor_
Definition: mesh_material.h:118


tesseract_geometry
Author(s): Levi Armstrong
autogenerated on Sun May 18 2025 03:01:46