summaryrefslogtreecommitdiff
path: root/legacy
diff options
context:
space:
mode:
authorRicardo de Almeida Gonzaga <ricardo@profusion.mobi>2012-10-04 22:37:47 +0000
committerBruno Dilly <bdilly@profusion.mobi>2012-10-04 22:37:47 +0000
commit45c3c60ea3691f4b5468bdb4488b3409f6f8bb0a (patch)
tree3b880a0b48f6d3ab6e3080eec0eb4e7e8f0d0151 /legacy
parentfcea4e820ac852c56f3a289c27f4f12215682734 (diff)
ephysics: add some references to technical terms.
Patch by: Ricardo de Almeida Gonzaga <ricardo@profusion.mobi> SVN revision: 77452
Diffstat (limited to 'legacy')
-rw-r--r--legacy/ephysics/src/lib/EPhysics.h92
1 files changed, 73 insertions, 19 deletions
diff --git a/legacy/ephysics/src/lib/EPhysics.h b/legacy/ephysics/src/lib/EPhysics.h
index ddadbf4..7d9c0ba 100644
--- a/legacy/ephysics/src/lib/EPhysics.h
+++ b/legacy/ephysics/src/lib/EPhysics.h
@@ -432,8 +432,14 @@ EAPI void ephysics_camera_tracked_body_get(EPhysics_Camera *camera, EPhysics_Bod
432 * @{ 432 * @{
433 * 433 *
434 * A world is required to simulate physics between bodies. 434 * A world is required to simulate physics between bodies.
435 * It will setup collision configuration, constraint solver, the 435 * It will setup collision configuration,
436 * broadphase interface and a dispatcher to dispatch calculations 436 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
437 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
438 * constraint solver</a></b>,
439 * the
440 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Broadphase">
441 * broadphase</a></b>
442 * interface and a dispatcher to dispatch calculations
437 * for overlapping pairs. 443 * for overlapping pairs.
438 * 444 *
439 * A new world can be created with @ref ephysics_world_new() and deleted with 445 * A new world can be created with @ref ephysics_world_new() and deleted with
@@ -469,7 +475,10 @@ typedef enum _EPhysics_Callback_World_Type
469 * @enum _EPhysics_World_Constraint_Solver_Mode 475 * @enum _EPhysics_World_Constraint_Solver_Mode
470 * typedef EPhysics_World_Constraint_Solver_Mode 476 * typedef EPhysics_World_Constraint_Solver_Mode
471 * 477 *
472 * Identifies the worlds contact and joint constraint solver mode. By default 478 * Identifies the worlds contact and
479 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Glossary_of_
480 * Terms#Joint.2C_constraint"> joint constraint</a></b>
481 * solver mode. By default
473 * EPHYSICS_WORLD_SOLVER_USE_WARMSTARTING is the only enabled solver mode. 482 * EPHYSICS_WORLD_SOLVER_USE_WARMSTARTING is the only enabled solver mode.
474 * 483 *
475 * @see ephysics_world_constraint_solver_mode_enable_set() 484 * @see ephysics_world_constraint_solver_mode_enable_set()
@@ -508,7 +517,12 @@ typedef void (*EPhysics_World_Event_Cb)(void *data, EPhysics_World *world, void
508 * Create a new physics world. 517 * Create a new physics world.
509 * 518 *
510 * A new world will be created with set collision configuration, 519 * A new world will be created with set collision configuration,
511 * constraint solver, broadphase interface and dispatcher. 520 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
521 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
522 * constraint solver</a></b>,
523 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Broadphase">
524 * broadphase</a></b>
525 * interface and dispatcher.
512 * 526 *
513 * It can be paused / unpaused with @ref ephysics_world_running_set() and its 527 * It can be paused / unpaused with @ref ephysics_world_running_set() and its
514 * gravity can be changed with @ref ephysics_world_gravity_set(). 528 * gravity can be changed with @ref ephysics_world_gravity_set().
@@ -688,15 +702,28 @@ EAPI void ephysics_world_gravity_set(EPhysics_World *world, double gx, double gy
688 702
689/** 703/**
690 * @brief 704 * @brief
691 * Set the number of iterations the constraint solver will have for contact and 705 * Set the number of iterations the
692 * joint constraints. 706 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
707 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
708 * constraint solver</a></b>
709 * will have for contact and
710 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Glossary_of_
711 * Terms#Joint.2C_constraint">
712 * joint constraints</a></b>.
693 * 713 *
694 * The default value is set to 10. The greater number of iterations more 714 * The default value is set to 10. The greater number of iterations more
695 * quality and precise the result but with performance penalty. 715 * quality and precise the result but with performance penalty.
696 * 716 *
697 * By default, the Projected Gauss Seidel constraint solver is used for contact 717 * By default, the Projected Gauss Seidel
698 * and joint constraints. The algorithm is an iterative LCP solver, informally 718 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
699 * known as 'sequential impulse'. 719 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
720 * constraint solver</a></b>
721 * is used for contact and
722 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Glossary_of_
723 * Terms#Joint.2C_constraint">
724 * joint constraints</a></b>.
725 * The algorithm is an iterative LCP solver, informally known as 'sequential
726 * impulse'.
700 * 727 *
701 * A reasonable range of iterations is from 4 (low quality, good performance) 728 * A reasonable range of iterations is from 4 (low quality, good performance)
702 * to 20 (good quality, less but still reasonable performance). 729 * to 20 (good quality, less but still reasonable performance).
@@ -711,8 +738,14 @@ EAPI void ephysics_world_constraint_solver_iterations_set(EPhysics_World *world,
711 738
712/** 739/**
713 * @brief 740 * @brief
714 * Get the number of iterations the constraint solver will have for contact and 741 * Get the number of iterations the
715 * joint constraints. 742 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
743 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
744 * constraint solver</a></b>
745 * will have for contact and
746 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Glossary_of_
747 * Terms#Joint.2C_constraint">
748 * joint constraints</a></b>.
716 * 749 *
717 * @param world The world to get number of iterations from. 750 * @param world The world to get number of iterations from.
718 * @return the number of iterations set to @p world, or 0 on failure. 751 * @return the number of iterations set to @p world, or 0 on failure.
@@ -724,8 +757,16 @@ EAPI int ephysics_world_constraint_solver_iterations_get(const EPhysics_World *w
724 757
725/** 758/**
726 * @brief 759 * @brief
727 * Enable or disable a constraint solver mode to @p world. A world can operate 760 * Enable or disable a
728 * on several constraint solver modes. 761 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
762 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
763 * constraint solver</a></b>
764 * mode to @p world. A world can operate
765 * on several
766 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
767 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
768 * constraint solver</a></b>
769 * modes.
729 * 770 *
730 * @param world The world to be set. 771 * @param world The world to be set.
731 * @param solver_mode The solver mode to set. 772 * @param solver_mode The solver mode to set.
@@ -908,17 +949,27 @@ EAPI void *ephysics_world_event_callback_del_full(EPhysics_World *world, EPhysic
908 * @brief 949 * @brief
909 * Set linear slop to be used by world. 950 * Set linear slop to be used by world.
910 * 951 *
911 * Constraint solver can be configured using some advanced settings, like 952 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
953 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
954 * Constraint solver</a></b>
955 * can be configured using some advanced settings, like
912 * the solver slop factor. 956 * the solver slop factor.
913 * 957 *
914 * The default value is set to 0 with a small value results in a smoother 958 * The default value is set to 0 with a small value results in a smoother
915 * stabilization for stacking bodies. 959 * stabilization for stacking bodies.
916 * 960 *
917 * Linear slop on sequencial impulse constraint solver is used as a factor 961 * Linear slop on sequencial impulse
918 * for penetration. The penetration will the manifold distance + linear slop. 962 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
963 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
964 * constraint solver</a></b>
965 * is used as a factor for penetration. The penetration will the manifold
966 * distance + linear slop.
919 * 967 *
920 * @param world The physics world. 968 * @param world The physics world.
921 * @param linear_slop New linear slop value to be used by constraint solver 969 * @param linear_slop New linear slop value to be used by
970 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
971 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
972 * constraint solver</a></b>
922 * of physics engine. 973 * of physics engine.
923 * 974 *
924 * @ingroup EPhysics_World 975 * @ingroup EPhysics_World
@@ -930,8 +981,11 @@ EAPI void ephysics_world_linear_slop_set(EPhysics_World *world, double linear_sl
930 * Get linear slop used by world. 981 * Get linear slop used by world.
931 * 982 *
932 * @param world The physics world. 983 * @param world The physics world.
933 * @return Linear slop value used by constraint solver of physics engine or 0 984 * @return Linear slop value used by
934 * on failure. 985 * <b><a href="http://bulletphysics.org/mediawiki-1.5.8/index.php/Collision_
986 * Detection_and_Physics_FAQ#How_do_most_physics_engines_solve_constraints.3F">
987 * constraint solver</a></b>
988 * of physics engine or 0 on failure.
935 * 989 *
936 * @see ephysics_world_linear_slop_set() for details. 990 * @see ephysics_world_linear_slop_set() for details.
937 * 991 *