| Modifier and Type | Field and Description |
|---|---|
protected float |
m_height |
protected float |
m_width |
m_allowSleep, m_angle, m_angularDamping, m_angularVelocity, m_body, m_bullet, m_categoryBits, m_density, m_filterBits, m_force, m_friction, m_grabbable, m_groupIndex, m_isSleeping, m_linearDamping, m_linearVelocity, m_name, m_parent, m_position, m_restitution, m_rotatable, m_sensor, m_shape, m_static, m_torque, m_worldm_drawable, m_fill, m_fillColor, m_image, m_imageAlpha, m_mask, m_stroke, m_strokeColor, m_strokeWeight| Constructor and Description |
|---|
FBox(float width,
float height)
Constructs a rectangular body that can be added to a world.
|
| Modifier and Type | Method and Description |
|---|---|
void |
draw(def.processing.core.PGraphics applet)
This method is called when calling
world.draw(). |
void |
drawDebug(def.processing.core.PGraphics applet)
This method is called when calling
world.drawDebug(). |
float |
getHeight()
Returns the height of the rectangle.
|
protected org.jbox2d.collision.shapes.ShapeDef |
getShapeDef() |
protected org.jbox2d.collision.shapes.ShapeDef |
getTransformedShapeDef() |
float |
getWidth()
Returns the width of the rectangle.
|
void |
setHeight(float height)
Sets the height of the rectangle.
|
void |
setWidth(float width)
Sets the width of the rectangle.
|
addForce, addForce, addImpulse, addImpulse, addTorque, addToWorld, adjustAngularVelocity, adjustPosition, adjustRotation, adjustVelocity, applyMatrix, getAABB, getAngularVelocity, getBB, getBodies, getBox2dBody, getCategoryBits, getContacts, getDensity, getFilterBits, getForceX, getForceY, getGroupIndex, getJoints, getLocalWorldPoint, getMass, getName, getParent, getProcessedShapeDef, getRotation, getShapeDefs, getTouching, getVelocityX, getVelocityY, getX, getY, isConnected, isResting, isSensor, isSleeping, isStatic, isTouchingBody, postDraw, postDrawDebug, preDraw, preDrawDebug, processBody, processShapeDef, recreateInWorld, removeFromWorld, resetForces, setAllowSleeping, setAngularDamping, setAngularVelocity, setBullet, setCategoryBits, setDamping, setDensity, setFilterBits, setForce, setFriction, setGrabbable, setGroupIndex, setName, setParent, setPosition, setPosition, setRestitution, setRotatable, setRotation, setSensor, setState, setStateFromWorld, setStatic, setStaticBody, setVelocity, updateMass, wakeUpappletFill, appletFillStroke, appletStroke, attachImage, dettachImage, drawImage, getFillColor, getImageAlpha, isDrawable, setDrawable, setFill, setFill, setFill, setFill, setFillColor, setImageAlpha, setNoFill, setNoStroke, setStroke, setStroke, setStroke, setStroke, setStrokeColor, setStrokeWeight, updateStylepublic FBox(float width,
float height)
width - the width of the rectangleheight - the height of the rectangleprotected org.jbox2d.collision.shapes.ShapeDef getShapeDef()
getShapeDef in class FBodyprotected org.jbox2d.collision.shapes.ShapeDef getTransformedShapeDef()
getTransformedShapeDef in class FBodypublic float getHeight()
getWidth()public float getWidth()
getHeight()public void setHeight(float height)
getWidth()public void setWidth(float width)
getWidth()public void draw(def.processing.core.PGraphics applet)
FDrawableworld.draw().
This method may be overriden to allow custom drawing of the object.public void drawDebug(def.processing.core.PGraphics applet)
FDrawableworld.drawDebug().
This method may be overriden to allow custom debug drawing of the object.