Public Member Functions | Private Member Functions | Private Attributes | List of all members
b2Rope Class Reference

#include <b2_rope.h>

Public Member Functions

 b2Rope ()
 
void Create (const b2RopeDef &def)
 
void Draw (b2Draw *draw) const
 
void Reset (const b2Vec2 &position)
 
void SetTuning (const b2RopeTuning &tuning)
 
void Step (float timeStep, int32 iterations, const b2Vec2 &position)
 
 ~b2Rope ()
 

Private Member Functions

void ApplyBendForces (float dt)
 
void SolveBend_PBD_Angle ()
 
void SolveBend_PBD_Distance ()
 
void SolveBend_PBD_Height ()
 
void SolveBend_PBD_Triangle ()
 
void SolveBend_XPBD_Angle (float dt)
 
void SolveStretch_PBD ()
 
void SolveStretch_XPBD (float dt)
 

Private Attributes

b2RopeBendm_bendConstraints
 
int32 m_bendCount
 
b2Vec2m_bindPositions
 
int32 m_count
 
b2Vec2 m_gravity
 
float * m_invMasses
 
b2Vec2m_p0s
 
b2Vec2 m_position
 
b2Vec2m_ps
 
b2RopeStretchm_stretchConstraints
 
int32 m_stretchCount
 
b2RopeTuning m_tuning
 
b2Vec2m_vs
 

Detailed Description

Definition at line 101 of file b2_rope.h.

Constructor & Destructor Documentation

◆ b2Rope()

b2Rope::b2Rope ( )

Definition at line 50 of file b2_rope.cpp.

◆ ~b2Rope()

b2Rope::~b2Rope ( )

Definition at line 66 of file b2_rope.cpp.

Member Function Documentation

◆ ApplyBendForces()

void b2Rope::ApplyBendForces ( float  dt)
private

Definition at line 592 of file b2_rope.cpp.

◆ Create()

void b2Rope::Create ( const b2RopeDef def)

Definition at line 77 of file b2_rope.cpp.

◆ Draw()

void b2Rope::Draw ( b2Draw draw) const

Definition at line 793 of file b2_rope.cpp.

◆ Reset()

void b2Rope::Reset ( const b2Vec2 position)

Definition at line 332 of file b2_rope.cpp.

◆ SetTuning()

void b2Rope::SetTuning ( const b2RopeTuning tuning)

Definition at line 187 of file b2_rope.cpp.

◆ SolveBend_PBD_Angle()

void b2Rope::SolveBend_PBD_Angle ( )
private

Definition at line 433 of file b2_rope.cpp.

◆ SolveBend_PBD_Distance()

void b2Rope::SolveBend_PBD_Distance ( )
private

Definition at line 673 of file b2_rope.cpp.

◆ SolveBend_PBD_Height()

void b2Rope::SolveBend_PBD_Height ( )
private

Definition at line 709 of file b2_rope.cpp.

◆ SolveBend_PBD_Triangle()

void b2Rope::SolveBend_PBD_Triangle ( )
private

Definition at line 758 of file b2_rope.cpp.

◆ SolveBend_XPBD_Angle()

void b2Rope::SolveBend_XPBD_Angle ( float  dt)
private

Definition at line 504 of file b2_rope.cpp.

◆ SolveStretch_PBD()

void b2Rope::SolveStretch_PBD ( )
private

Definition at line 354 of file b2_rope.cpp.

◆ SolveStretch_XPBD()

void b2Rope::SolveStretch_XPBD ( float  dt)
private

Definition at line 385 of file b2_rope.cpp.

◆ Step()

void b2Rope::Step ( float  timeStep,
int32  iterations,
const b2Vec2 position 
)

Definition at line 244 of file b2_rope.cpp.

Member Data Documentation

◆ m_bendConstraints

b2RopeBend* b2Rope::m_bendConstraints
private

Definition at line 140 of file b2_rope.h.

◆ m_bendCount

int32 b2Rope::m_bendCount
private

Definition at line 137 of file b2_rope.h.

◆ m_bindPositions

b2Vec2* b2Rope::m_bindPositions
private

Definition at line 142 of file b2_rope.h.

◆ m_count

int32 b2Rope::m_count
private

Definition at line 135 of file b2_rope.h.

◆ m_gravity

b2Vec2 b2Rope::m_gravity
private

Definition at line 148 of file b2_rope.h.

◆ m_invMasses

float* b2Rope::m_invMasses
private

Definition at line 147 of file b2_rope.h.

◆ m_p0s

b2Vec2* b2Rope::m_p0s
private

Definition at line 144 of file b2_rope.h.

◆ m_position

b2Vec2 b2Rope::m_position
private

Definition at line 133 of file b2_rope.h.

◆ m_ps

b2Vec2* b2Rope::m_ps
private

Definition at line 143 of file b2_rope.h.

◆ m_stretchConstraints

b2RopeStretch* b2Rope::m_stretchConstraints
private

Definition at line 139 of file b2_rope.h.

◆ m_stretchCount

int32 b2Rope::m_stretchCount
private

Definition at line 136 of file b2_rope.h.

◆ m_tuning

b2RopeTuning b2Rope::m_tuning
private

Definition at line 150 of file b2_rope.h.

◆ m_vs

b2Vec2* b2Rope::m_vs
private

Definition at line 145 of file b2_rope.h.


The documentation for this class was generated from the following files:


mvsim
Author(s):
autogenerated on Tue Jul 4 2023 03:08:22