Go to the documentation of this file.
64 const float y = 15.0f;
68 for (
int32 i = 0; i < N; ++i)
86 sfd.
shape = &circleShape;
96 b2Vec2 anchor(
float(i), y);
105 float extraLength = 0.01f;
void Initialize(b2Body *bodyA, b2Body *bodyB, const b2Vec2 &anchor)
IMGUI_API void SetNextWindowPos(const ImVec2 &pos, ImGuiCond cond=0, const ImVec2 &pivot=ImVec2(0, 0))
b2Vec2 localAnchorB
The local anchor point relative to bodyB's origin.
void Step(Settings &settings) override
b2Joint * m_distanceJoint
A rigid body. These are created via b2World::CreateBody.
void DestroyJoint(b2Joint *joint)
void SetZero()
Set this vector to all zeros.
void Set(float x_, float y_)
Set this vector to some specified coordinates.
void SetTwoSided(const b2Vec2 &v1, const b2Vec2 &v2)
Set this as an isolated edge. Collision is two-sided.
float maxLength
Maximum length. Must be greater than or equal to the minimum length.
b2Joint * CreateJoint(const b2JointDef *def)
float friction
The friction coefficient, usually in the range [0,1].
void DrawString(int x, int y, const char *string,...)
b2Filter filter
Contact filtering data.
bool collideConnected
Set this flag to true if the attached bodies should collide.
IMGUI_API bool Checkbox(const char *label, bool *v)
void SetAsBox(float hx, float hy)
float density
The density, usually in kg/m^2.
float minLength
Minimum length. Clamped to a stable minimum value.
IMGUI_API void SetNextWindowSize(const ImVec2 &size, ImGuiCond cond=0)
b2Body * CreateBody(const b2BodyDef *def)
@ ImGuiWindowFlags_NoMove
int RegisterTest(const char *category, const char *name, TestCreateFcn *fcn)
IMGUI_API bool Begin(const char *name, bool *p_open=NULL, ImGuiWindowFlags flags=0)
uint16 categoryBits
The collision category bits. Normally you would just set one bit.
virtual void Step(Settings &settings)
@ ImGuiWindowFlags_NoResize
b2DistanceJointDef m_distanceJointDef
b2Body * bodyA
The first attached body.
b2Vec2 localAnchorA
The local anchor point relative to bodyA's origin.
b2Fixture * CreateFixture(const b2FixtureDef *def)
b2Body * bodyB
The second attached body.
mvsim
Author(s):
autogenerated on Wed May 28 2025 02:13:08