30#ifndef _GranOO_LibShape_ConeTruncated_hh_
31#define _GranOO_LibShape_ConeTruncated_hh_
36#include <vtkUnstructuredGrid.h>
59 static std::string
class_ID() {
return std::string(
"ConeTruncated");}
75 virtual void to_vtk(vtkUnstructuredGrid* data);
93 GRANOO_DECLARE_SHAPE_COLLISION();
109 GRANOO_ACCESS_SHAPE_DIM(radius1,
double,
_radius1);
110 GRANOO_ACCESS_SHAPE_DIM(radius2,
double,
_radius2);
111 GRANOO_ACCESS_SHAPE_DIM(length,
double,
_length);
122 template<
class Archive>
void serialize(Archive&,
const unsigned int);
179 double max = get_radius1()*2.;
180 if (get_length() > max)
196 double minPoint[] = { xMin, yMin, zMin };
197 double maxPoint[] = { xMax, yMax, zMax };
209 template<
class Archive>
213 ar & boost::serialization::base_object<Volume>(*
this);
223#include <boost/serialization/export.hpp>
226#include <boost/serialization/version.hpp>
228GRANOO_SERIALIZE_SHAPE(ConeTruncated)
232 extern template class Core::ObjectFactoryInterface<Shape::Base, Shape::ConeTruncated>;
BOOST_CLASS_EXPORT_KEY(GranOO3::Shape::Box) namespace GranOO3
Definition Box.hpp:319
BOOST_CLASS_VERSION(GranOO3::Core::Base, 1) namespace GranOO3
Definition Base.hpp:277
#define SafeModeAssert(condition, message)
Definition Macro.hpp:47
Definition ObjectFactory.hpp:235
const Geom::Frame & _frame
Definition Base.hpp:143
Definition ConeTruncated.hpp:47
static std::string class_ID()
Definition ConeTruncated.hpp:59
double get_centre_of_mass() const
bool collide_inside(const Geom::Point &p1, double radius, Collision::Data &info) const
double get_radius_at(double) const
Definition ConeTruncated.hpp:203
void make_equal_to(const ConeTruncated &)
std::ostream & to_povray(std::ostream &out, const Core::Color &) const
double _radius1
Definition ConeTruncated.hpp:125
void update_bounding_box()
void set_contact_regions(const std::string ®ions)
double get_volume() const
Definition ConeTruncated.hpp:171
Interference locate(const Geom::Point &) const
AABB aabb() const
Definition ConeTruncated.hpp:187
void read_xml_element(const TiXmlElement *el)
void update_bounding_sphere()
ContactRegion _cRegion
Definition ConeTruncated.hpp:130
Box * _bounding_box
Definition ConeTruncated.hpp:128
ConeTruncated()
Definition ConeTruncated.hpp:151
bool collide_outside(const Geom::Point &p1, double radius, Collision::Data &info) const
virtual std::istream & read_ascii(std::istream &in)
Interference locate(const Geom::Point &, double radius) const
Geom::Point farthest_point_along(const Geom::Vector &) const
double get_greatest_dimension() const
Definition ConeTruncated.hpp:177
ConeTruncated & operator=(const ConeTruncated &)
double _radius2
Definition ConeTruncated.hpp:126
double get_half_angle() const
Definition ConeTruncated.hpp:101
static std::string desc()
friend class boost::serialization::access
Definition ConeTruncated.hpp:121
double _length
Definition ConeTruncated.hpp:127
virtual void to_vtk(vtkUnstructuredGrid *data)
void serialize(Archive &, const unsigned int)
Definition ConeTruncated.hpp:211
virtual std::ostream & write_ascii(std::ostream &out) const
Sphere * _bounding_sphere
Definition ConeTruncated.hpp:129
void compute_inertia_tensor(double density, Geom::Tensor &) const
ContactRegion
Definition ConeTruncated.hpp:52
@ RADIUS
Definition ConeTruncated.hpp:54
@ XMAX
Definition ConeTruncated.hpp:55
@ XMIN
Definition ConeTruncated.hpp:53
Volume(const Geom::Frame &frame)
Definition Volume.cpp:40
void set_face_ID(const T &, Args... args)
Definition Volume.hpp:185
static AABB new_lonely_aabb(double minPoint[3], double maxPoint[3], unsigned int primtiveIndex=-1)
Creates a new 'lonely' AABB with given extreme points.
Definition StaticAABBTree.cpp:415
This namespace group the entire Geom library.
This namespace group the entire Shape library.
Interference
Definition Volume.hpp:100
Definition Common.hpp:198
Definition StaticAABBTree.hpp:38