Fixed some internal documentation (thanks to clang's -Wdocumentation)

This commit is contained in:
Alex Szpakowski
2013-09-23 21:52:28 -03:00
parent 06f2ec8e31
commit 8d5ddb9e34
18 changed files with 71 additions and 85 deletions
+20 -18
View File
@@ -91,29 +91,31 @@ public:
/**
* Gets the current position of the Body.
* @returns The current position.
* @param[out] x_o The x-component of the position.
* @param[out] y_o The y-component of the position.
**/
void getPosition(float &x_o, float &y_o);
/**
* Gets the velocity in the current center of mass.
* @returns The velocity in the current center of mass.
* @param[out] x_o The x-component of the velocity.
* @param[out] y_o The y-component of the velocity.
**/
void getLinearVelocity(float &x_o, float &y_o);
/**
* The current center of mass for the Body in world
* coordinates.
* @returns The x-component of the point.
* @returns The y-component of the point.
* @param[out] x_o The x-component of the center of mass.
* @param[out] y_o The y-component of the center of mass.
**/
void getWorldCenter(float &x_o, float &y_o);
/**
* The current center of mass for the Body in local
* coordinates.
* @returns The x-component of the point.
* @returns The y-component of the point.
* @param[out] x_o The x-component of the center of mass.
* @param[out] y_o The y-component of the center of mass.
**/
void getLocalCenter(float &x_o, float &y_o);
@@ -269,8 +271,8 @@ public:
* to world coordinates.
* @param x The x-coordinate of the local point.
* @param y The y-coordinate of the local point.
* @returns The x-coordinate of the point in world coordinates.
* @returns The y-coordinate of the point in world coordinates.
* @param[out] x_o The x-coordinate of the point in world coordinates.
* @param[out] y_o The y-coordinate of the point in world coordinates.
**/
void getWorldPoint(float x, float y, float &x_o, float &y_o);
@@ -279,8 +281,8 @@ public:
* to world coordinates.
* @param x The x-coordinate of the local vector.
* @param y The y-coordinate of the local vector.
* @returns The x-coordinate of the vector in world coordinates.
* @returns The y-coordinate of the vector in world coordinates.
* @param[out] x_o The x-coordinate of the vector in world coordinates.
* @param[out] y_o The y-coordinate of the vector in world coordinates.
**/
void getWorldVector(float x, float y, float &x_o, float &y_o);
@@ -295,8 +297,8 @@ public:
* to local coordinates.
* @param x The x-coordinate of the world point.
* @param y The y-coordinate of the world point.
* @returns The x-coordinate of the point in local coordinates.
* @returns The y-coordinate of the point in local coordinates.
* @param[out] x_o The x-coordinate of the point in local coordinates.
* @param[out] y_o The y-coordinate of the point in local coordinates.
**/
void getLocalPoint(float x, float y, float &x_o, float &y_o);
@@ -305,8 +307,8 @@ public:
* to local coordinates.
* @param x The x-coordinate of the world vector.
* @param y The y-coordinate of the world vector.
* @returns The x-coordinate of the vector in local coordinates.
* @returns The y-coordinate of the vector in local coordinates.
* @param[out] x_o The x-coordinate of the vector in local coordinates.
* @param[out] y_o The y-coordinate of the vector in local coordinates.
**/
void getLocalVector(float x, float y, float &x_o, float &y_o);
@@ -314,8 +316,8 @@ public:
* Gets the velocity on the Body for the given world point.
* @param x The x-coordinate of the world point.
* @param y The y-coordinate of the world point.
* @returns The x-component of the velocity vector.
* @returns The y-component of the velocity vector.
* @param[out] x_o The x-component of the velocity vector.
* @param[out] y_o The y-component of the velocity vector.
**/
void getLinearVelocityFromWorldPoint(float x, float y, float &x_o, float &y_o);
@@ -323,8 +325,8 @@ public:
* Gets the velocity on the Body for the given local point.
* @param x The x-coordinate of the local point.
* @param y The y-coordinate of the local point.
* @returns The x-component of the velocity vector.
* @returns The y-component of the velocity vector.
* @param[out] x_o The x-component of the velocity vector.
* @param[out] y_o The y-component of the velocity vector.
**/
void getLinearVelocityFromLocalPoint(float x, float y, float &x_o, float &y_o);
+2 -4
View File
@@ -45,10 +45,8 @@ class CircleShape : public Shape
public:
/**
* Create a new CircleShape from the parent body and a
* Box2D CircleShape definition.
* @param body The parent body.
* @param def The CircleShape definition.
* Create a new CircleShape from the a Box2D CircleShape definition.
* @param c The CircleShape definition.
**/
CircleShape(b2CircleShape *c, bool own = true);
+1 -1
View File
@@ -53,7 +53,7 @@ public:
* Creates a new Contact by copying a Box2D contact
* point. It does not store the pointer, but copy the
* data pointed to.
* @param point Pointer to the Box2D contact.
* @param contact Pointer to the Box2D contact.
**/
Contact(b2Contact *contact);
+3 -3
View File
@@ -274,10 +274,10 @@ int Physics::getDistance(lua_State *L)
return 5;
}
void Physics::setMeter(int meter)
void Physics::setMeter(int scale)
{
if (meter < 1) throw love::Exception("Physics error: invalid meter");
Physics::meter = meter;
if (scale < 1) throw love::Exception("Physics error: invalid meter");
Physics::meter = scale;
}
int Physics::getMeter()
+8 -10
View File
@@ -75,7 +75,7 @@ public:
* Creates a new Body at the specified position.
* @param world The world to create the Body in.
* @param x The position along the x-axis.
* @param x The position along the y-axis.
* @param y The position along the y-axis.
* @param type The type of body to create.
**/
Body *newBody(World *world, float x, float y, Body::Type type);
@@ -141,14 +141,12 @@ public:
EdgeShape *newEdgeShape(float x1, float y1, float x2, float y2);
/**
* Creates a new PolygonShape.
* @param ... A variable number of vertices.
* Creates a new PolygonShape from a variable number of vertices.
**/
int newPolygonShape(lua_State *L);
/**
* Creates a new ChainShape.
* @param ... A variable number of vertices.
* Creates a new ChainShape from a variable number of vertices.
**/
int newChainShape(lua_State *L);
@@ -272,13 +270,13 @@ public:
/**
* Sets the number of pixels in one meter.
* @param pixels The number of pixels in one meter. (1m ~= 3.3ft).
* @param scale The number of pixels in one meter. (1m ~= 3.3ft).
**/
static void setMeter(int meter);
static void setMeter(int scale);
/**
* Gets the number of pixels in one meter.
* @param pixels The number of pixels in one meter. (1m ~= 3.3ft).
* @return The number of pixels in one meter. (1m ~= 3.3ft).
**/
static int getMeter();
@@ -326,14 +324,14 @@ public:
/**
* Scales a b2AABB down according to the current meter in pixels.
* @param v The unscaled input AABB.
* @param aabb The unscaled input AABB.
* @return The scaled AABB.
**/
static b2AABB scaleDown(const b2AABB &aabb);
/**
* Scales a b2AABB up according to the current meter in pixels.
* @param v The unscaled input AABB.
* @param aabb The unscaled input AABB.
* @return The scaled AABB.
**/
static b2AABB scaleUp(const b2AABB &aabb);
+2 -4
View File
@@ -43,10 +43,8 @@ class PolygonShape : public Shape
public:
/**
* Create a new PolygonShape from the parent Body and
* a Box2D polygon definition.
* @param body The parent Body.
* @param def The polygon definition.
* Create a new PolygonShape from a Box2D polygon definition.
* @param p The polygon definition.
**/
PolygonShape(b2PolygonShape *p, bool own = true);