36 for (_k = 0; _k < point_count; _k++)
45 point_indices[0] = _k;
58 m_points[_k] = points[point_indices[_k]];
73 if (dis0 > 0.0f && dis1 > 0.0f && dis2 > 0.0f)
return false;
82 if (dis0 > 0.0f && dis1 > 0.0f && dis2 > 0.0f)
return false;
100 if (clipped_count == 0)
return 0;
109 if (clipped_count == 0)
return 0;
115 edgeplane, temp_points1, clipped_count, clipped_points);
117 return clipped_count;
135 if (clipped_count == 0)
152 if (clipped_count == 0)
191 if (dis0 > 0.0f && dis1 > 0.0f && dis2 > 0.0f)
return false;
200 if (dis0 > 0.0f && dis1 > 0.0f && dis2 > 0.0f)
return false;
SIMD_FORCE_INLINE btScalar bt_distance_point_plane(const btVector4 &plane, const btVector3 &point)
SIMD_FORCE_INLINE int bt_plane_clip_triangle(const btVector4 &plane, const btVector3 &point0, const btVector3 &point1, const btVector3 &point2, btVector3 *clipped)
Clips a polygon by a plane.
SIMD_FORCE_INLINE int bt_plane_clip_polygon(const btVector4 &plane, const btVector3 *polygon_points, int polygon_point_count, btVector3 *clipped)
Clips a polygon by a plane.
virtual btScalar getMargin() const =0
float btScalar
The btScalar type abstracts floating point numbers, to easily switch between double and single floati...
btVector3
btVector3 can be used to represent 3D points and vectors. It has an un-used w component to suit 16-by...
bool find_triangle_collision_clip_method(btPrimitiveTriangle &other, GIM_TRIANGLE_CONTACT &contacts)
Find collision using the clipping method.
SIMD_FORCE_INLINE void get_edge_plane(int edge_index, btVector4 &plane) const
Calcs the plane which is paralele to the edge and perpendicular to the triangle plane.
int clip_triangle(btPrimitiveTriangle &other, btVector3 *clipped_points)
Clips the triangle against this.
bool overlap_test_conservative(const btPrimitiveTriangle &other)
Test if triangles could collide.
Helper class for colliding Bullet Triangle Shapes.
SIMD_FORCE_INLINE void buildTriPlane(btVector4 &plane) const
bool overlap_test_conservative(const btTriangleShapeEx &other)
class btTriangleShapeEx: public btTriangleShape