TinyURDF 1.0.0
A Modern C++ Library for Parsing and Visualizing URDF Model Files
Loading...
Searching...
No Matches
material.h
Go to the documentation of this file.
1#ifndef TINYURDF_MATERIAL_H
2#define TINYURDF_MATERIAL_H
3
4// Copyright 2025 Wissem CHIHA
5
6#include <filesystem>
7#include <memory>
8#include <string>
9
10#include <loguru/loguru.hpp>
11
12#include "property_base.h"
13#include "color.h"
14
15class Material : public PropertyBase {
16public:
17 Material();
18 void clear() override;
19 void setFilename(std::string& path);
20 void setName(const std::string& name_);
21 void setDensity(double d);
22 void setColor(double r, double g, double b, double a = 1.0);
23 bool isA(const char* name) override;
24 void print(std::ostream& os) override;
25private:
26 std::string name;
27 std::string texture_filename;
28 std::shared_ptr<Color> color;
29 double density;
30};
31#endif // TINYURDF_MATERIAL_H
Definition material.h:15
Material()
Definition material.cc:3
bool isA(const char *name) override
Definition material.cc:45
void setFilename(std::string &path)
Definition material.cc:17
void setName(const std::string &name_)
Definition material.cc:25
void setColor(double r, double g, double b, double a=1.0)
Definition material.cc:37
void print(std::ostream &os) override
Definition material.cc:49
void setDensity(double d)
Definition material.cc:31
void clear() override
Definition material.cc:8
Definition property_base.h:9