Tesseract
Motion Planning Environment
Loading...
Searching...
No Matches
benchmark_utils.hpp
Go to the documentation of this file.
1#ifndef TESSERACT_COLLISION_BENCHMARK_UTILS_HPP
2#define TESSERACT_COLLISION_BENCHMARK_UTILS_HPP
3
4#include <benchmark/benchmark.h>
5#include <Eigen/Eigen>
6#include <console_bridge/console.h>
7
8using namespace tesseract_collision;
9using namespace test_suite;
10using namespace tesseract_geometry;
11
13 const double scale = 1.0)
14{
16 switch (type)
17 {
19 geom = std::make_shared<tesseract_geometry::Box>(scale, scale, scale);
20 break;
22 geom = std::make_shared<tesseract_geometry::Cone>(scale, scale);
23 break;
25 geom = std::make_shared<tesseract_geometry::Plane>(scale, scale, scale, scale);
26 break;
28 geom = std::make_shared<tesseract_geometry::Sphere>(scale);
29 break;
31 geom = std::make_shared<tesseract_geometry::Capsule>(scale, scale);
32 break;
34 geom = std::make_shared<tesseract_geometry::Cylinder>(scale, scale);
35 break;
36 default:
37 CONSOLE_BRIDGE_logError("Invalid Geometry Type. Can only create primatives");
38 break;
39 }
40 return geom;
41}
42#endif
tesseract_geometry::Geometry::Ptr CreateUnitPrimative(const tesseract_geometry::GeometryType type, const double scale=1.0)
Definition: benchmark_utils.hpp:12
std::shared_ptr< Geometry > Ptr
Definition: geometry.h:62
double scale
Definition: collision_margin_data_unit.cpp:133
Definition: bullet_cast_bvh_manager.h:49
Definition: geometry.h:39
GeometryType
Definition: geometry.h:41
@ BOX
Definition: geometry.h:47
@ CAPSULE
Definition: geometry.h:45
@ CONE
Definition: geometry.h:46
@ PLANE
Definition: geometry.h:48
@ CYLINDER
Definition: geometry.h:44
@ SPHERE
Definition: geometry.h:43
mCollisionCheckConfig contact_request type
Definition: tesseract_environment_collision.cpp:103
auto geom
Definition: tesseract_geometry_unit.cpp:51