14#ifndef __BULLET_CYLINDER_SHAPE_H__
15#define __BULLET_CYLINDER_SHAPE_H__
26class EXPCL_PANDABULLET BulletCylinderShape :
public BulletShape {
29 INLINE BulletCylinderShape();
32 explicit BulletCylinderShape(PN_stdfloat radius, PN_stdfloat height, BulletUpAxis up=Z_up);
33 explicit BulletCylinderShape(
const LVector3 &half_extents, BulletUpAxis up=Z_up);
34 BulletCylinderShape(
const BulletCylinderShape ©);
35 INLINE ~BulletCylinderShape();
37 PN_stdfloat get_radius()
const;
38 LVecBase3 get_half_extents_without_margin()
const;
39 LVecBase3 get_half_extents_with_margin()
const;
41 MAKE_PROPERTY(radius, get_radius);
42 MAKE_PROPERTY(half_extents_without_margin, get_half_extents_without_margin);
43 MAKE_PROPERTY(half_extents_with_margin, get_half_extents_with_margin);
46 virtual btCollisionShape *ptr()
const;
49 LVector3 _half_extents;
50 btCylinderShape *_shape;
58 static TypedWritable *make_from_bam(
const FactoryParams ¶ms);
65 static void init_type() {
66 BulletShape::init_type();
68 BulletShape::get_class_type());
71 return get_class_type();
75 return get_class_type();
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
This is the fundamental interface for extracting binary objects from a Bam file, as generated by a Ba...
static void register_with_read_factory()
Tells the BamReader how to create objects of type BulletShape.
A class to retrieve the individual data elements previously stored in a Datagram.
An ordered list of data elements, formatted in memory for transmission over a socket or writing to a ...
An instance of this class is passed to the Factory when requesting it to do its business and construc...
TypeHandle is the identifier used to differentiate C++ class types.
virtual void fillin(DatagramIterator &scan, BamReader *manager)
This internal function is intended to be called by each class's make_from_bam() method to read in all...
virtual void write_datagram(BamWriter *manager, Datagram &dg)
Writes the contents of this object to the datagram for shipping out to a Bam file.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
void register_type(TypeHandle &type_handle, const std::string &name)
This inline function is just a convenient way to call TypeRegistry::register_type(),...