From 0ea5fc66924303d1bf73ba283a383e2aadee02f2 Mon Sep 17 00:00:00 2001 From: neodarz Date: Sat, 11 Aug 2018 20:21:34 +0200 Subject: Initial commit --- .../doxygen/nel/classNL3D_1_1CIsotropicForceT.html | 463 +++++++++++++++++++++ 1 file changed, 463 insertions(+) create mode 100644 docs/doxygen/nel/classNL3D_1_1CIsotropicForceT.html (limited to 'docs/doxygen/nel/classNL3D_1_1CIsotropicForceT.html') diff --git a/docs/doxygen/nel/classNL3D_1_1CIsotropicForceT.html b/docs/doxygen/nel/classNL3D_1_1CIsotropicForceT.html new file mode 100644 index 00000000..5e17214f --- /dev/null +++ b/docs/doxygen/nel/classNL3D_1_1CIsotropicForceT.html @@ -0,0 +1,463 @@ + + + + nevrax.org : docs + + + + + + + + + + + + + + +
# Home   # nevrax.com   
+ + + + +
Nevrax
+ + + + + + + + + + +
+ + +
+ Nevrax.org
+ + + + + + + +
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
+
+ + +
+ + +
+Docs + +
+  + + + + + +
Documentation 
+ +
+Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  
+

NL3D::CIsotropicForceT Class Template Reference

a helper class to create isotropic force : they are independant of the basis, and have no position (fluid friction for example) To use this class you should provide to it a functor class that define the () operator with 3 parameters param1 = a const reference to the position of the particle param2 = a reference to the position, that must be updated param3 = a float giving the inverse of the mass param4 = the ellapsed time, in second (has the TAnimationTime type). +More... +

+#include <ps_force.h> +

+

Inheritance diagram for NL3D::CIsotropicForceT: +

+ +NL3D::CPSForce +NL3D::CPSTargetLocatedBindable +NL3D::CPSLocatedBindable +NLMISC::IStreamable +NLMISC::IClassable + +List of all members. + + + + + + + + + + + + + + + + + + + +

Public Methods

virtual void performDynamic (TAnimationTime ellapsedTime)
 Compute the force on the targets. More...

virtual void serial (NLMISC::IStream &f) throw (NLMISC::EStream)
 serialization. More...

void show (TAnimationTime ellapsedTime)
 Show the force (edition mode). More...

virtual void setupFunctor (uint32 index)
 setup the functor object. The default does nothing. More...


Protected Methods

virtual void newElement (CPSLocated *emitterLocated, uint32 emitterIndex)
 Generate a new element for this bindable. More...

virtual void deleteElement (uint32 index)
 Delete an element given its index Attributes of the located that hold this bindable are still accessible for of the index given index out of range -> nl_assert. More...

virtual void resize (uint32 size)
 Resize the bindable attributes containers DERIVERS SHOULD CALL THEIR PARENT VERSION should not be called directly. More...


Protected Attributes

_F
 the functor object. More...

+

Detailed Description

+

template<class T>
+ class NL3D::CIsotropicForceT< T >

+ +a helper class to create isotropic force : they are independant of the basis, and have no position (fluid friction for example) To use this class you should provide to it a functor class that define the () operator with 3 parameters param1 = a const reference to the position of the particle param2 = a reference to the position, that must be updated param3 = a float giving the inverse of the mass param4 = the ellapsed time, in second (has the TAnimationTime type). +

+Example of use : class MyForceFunctor { public: /// it is strongly recommended to have your operator inlined void operator() (const NLMISC::CVector &pos, NLMISC::CVector &speed, float invMass , CanimationTime ellapsedTime) { // perform the speed update there } +

+// you can provide a serialization method. Note that that if the functor parameters are set before each use, // it useless to serial something ... void serial(NLMISC::IStream &f) throw(NLMISC::EStream) +

+protected: ... }; +

+because of the serialization process, you must proceed like the following. (but you don't need to redefine serial, which will serilize the functor object you passed for you +

+class MyForce : public CHomogenousForceT<MyForceFunctor> { public: MyForce(); NLMISC_DECLARE_CLASS(Myforce); +

+protected: ... +

+}; +

+not that each functor may have its own parameter. the setupFunctor method will be called each time +

+ +

+Definition at line 278 of file ps_force.h.


Member Function Documentation

+

+ + + + +
+ + + + + + + + + + + + + +
+template<class T>
virtual void NL3D::CIsotropicForceT< T >::deleteElement uint32   index [inline, protected, virtual]
+
+ + + + + +
+   + + +

+Delete an element given its index Attributes of the located that hold this bindable are still accessible for of the index given index out of range -> nl_assert. +

+ +

+Implements NL3D::CPSForce. +

+Reimplemented in NL3D::CPSFluidFriction. +

+Definition at line 314 of file ps_force.h.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + + + + +
+template<class T>
virtual void NL3D::CIsotropicForceT< T >::newElement CPSLocated  emitterLocated,
uint32   emitterIndex
[inline, protected, virtual]
+
+ + + + + +
+   + + +

+Generate a new element for this bindable. +

+They are generated according to the propertie of the class +

+Implements NL3D::CPSForce. +

+Reimplemented in NL3D::CPSFluidFriction. +

+Definition at line 313 of file ps_force.h.

+

+ + + + +
+ + + + + + + + + + + + + +
+template<class T>
void NL3D::CIsotropicForceT< T >::performDynamic TAnimationTime   ellapsedTime [virtual]
+
+ + + + + +
+   + + +

+Compute the force on the targets. +

+ +

+Implements NL3D::CPSForce. +

+Definition at line 325 of file ps_force.h. +

+References _F, NL3D::CPSLocatedBindable::_Owner, NL3D::CPSTargetLocatedBindable::_Targets, setupFunctor, and NL3D::TAnimationTime.

+

+ + + + +
+ + + + + + + + + + + + + +
+template<class T>
virtual void NL3D::CIsotropicForceT< T >::resize uint32   size [inline, protected, virtual]
+
+ + + + + +
+   + + +

+Resize the bindable attributes containers DERIVERS SHOULD CALL THEIR PARENT VERSION should not be called directly. +

+Call CPSLOcated::resize instead +

+Implements NL3D::CPSForce. +

+Reimplemented in NL3D::CPSFluidFriction. +

+Definition at line 315 of file ps_force.h.

+

+ + + + +
+ + + + + + + + + + + + + +
+template<class T>
virtual void NL3D::CIsotropicForceT< T >::serial NLMISC::IStream  f throw (NLMISC::EStream) [inline, virtual]
+
+ + + + + +
+   + + +

+serialization. +

+ +

+Reimplemented from NL3D::CPSForce. +

+Reimplemented in NL3D::CPSFluidFriction. +

+Definition at line 287 of file ps_force.h.

+

+ + + + +
+ + + + + + + + + + + + + +
+template<class T>
virtual void NL3D::CIsotropicForceT< T >::setupFunctor uint32   index [inline, virtual]
+
+ + + + + +
+   + + +

+setup the functor object. The default does nothing. +

+ +

+Reimplemented in NL3D::CPSFluidFriction. +

+Definition at line 304 of file ps_force.h. +

+Referenced by performDynamic.

+

+ + + + +
+ + + + + + + + + + + + + +
+template<class T>
void NL3D::CIsotropicForceT< T >::show TAnimationTime   ellapsedTime [inline, virtual]
+
+ + + + + +
+   + + +

+Show the force (edition mode). +

+The default does nothing TODO later +

+Implements NL3D::CPSForce. +

+Definition at line 299 of file ps_force.h.

+


Member Data Documentation

+

+ + + + +
+ + + + + +
+template<class T>
T NL3D::CIsotropicForceT::_F [protected] +
+
+ + + + + +
+   + + +

+the functor object. +

+ +

+Definition at line 309 of file ps_force.h. +

+Referenced by performDynamic, and NL3D::CIsotropicForceT< CPSFluidFrictionFunctor >::serial.

+


The documentation for this class was generated from the following file: + + + +
                                                                                                                                                                    +
+ + -- cgit v1.2.1