summaryrefslogtreecommitdiff
path: root/legacy/ephysics/src/lib/EPhysics.h
diff options
context:
space:
mode:
authorLeandro Dorileo <dorileo@profusion.mobi>2012-11-23 21:43:49 +0000
committerBruno Dilly <bdilly@profusion.mobi>2012-11-23 21:43:49 +0000
commitcf2d140f8c3ef2b91d55e653188a48c4d5640a66 (patch)
tree3ebbe2b550e17714c01613a1a2375bafd27e6d78 /legacy/ephysics/src/lib/EPhysics.h
parent5d49f5912a749f9ea067db7f97bb8ebf63b207af (diff)
EPhysics: add soft body triangle impulse API
Patch by: Leandro Dorileo <dorileo@profusion.mobi> SVN revision: 79594
Diffstat (limited to '')
-rw-r--r--legacy/ephysics/src/lib/EPhysics.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/legacy/ephysics/src/lib/EPhysics.h b/legacy/ephysics/src/lib/EPhysics.h
index a9ac03d381..49e3f80d9c 100644
--- a/legacy/ephysics/src/lib/EPhysics.h
+++ b/legacy/ephysics/src/lib/EPhysics.h
@@ -2370,6 +2370,33 @@ EAPI int ephysics_body_soft_body_triangle_index_get(EPhysics_Body *body, Evas_Co
2370 2370
2371/** 2371/**
2372 * @brief 2372 * @brief
2373 * Apply an impulse on a given soft body triangle.
2374 *
2375 * The impulse is equal to the change of momentum of the body.
2376 * Impulse is the product of the force over the time this force is applied. In
2377 * ephysics case, it would be the time of a tick, so it behaves just summing
2378 * current linear velocity to impulse per mass(per triangle mass).
2379 *
2380 * When a impulse is applied over a body, it will have its velocity changed. This
2381 * impulse will be applied on body's specified triangle @p idx, so it won't
2382 * imply in rotating the body.
2383 *
2384 * @note Impulse is measured in kg * p / s.
2385 *
2386 * @param body The body to apply impulse to.
2387 * @param idx The soft body triangle index.
2388 * @param x The axis @p x component of impulse.
2389 * @param y The axis @p y component of impulse
2390 * @param z The axis @p z component of impulse
2391 *
2392 * @see ephysics_body_soft_body_triangle_index_get().
2393 *
2394 * @ingroup EPhysics_Body
2395 */
2396EAPI void ephysics_body_soft_body_triangle_impulse_apply(EPhysics_Body * body, int idx, double x, double y, double z);
2397
2398/**
2399 * @brief
2373 * Set the soft body number of position iterations. 2400 * Set the soft body number of position iterations.
2374 * 2401 *
2375 * Both soft body and cloth can have its number of position iterations changed. 2402 * Both soft body and cloth can have its number of position iterations changed.