#include <freecloth/clothApp/clothApp.h>
Inheritance diagram for ClothApp:


Public Member Functions | |
| void | runApp () |
Protected Member Functions | |
| void | keyPressed (GfxWindow &, GfxWindow::KeyID, GfxWindow::ModBitfield) |
| void | windowResized (GfxWindow &, UInt32 x, UInt32 y, UInt32 w, UInt32 h) |
| void | displayReceived (GfxWindow &) |
| void | closeReceived (GfxWindow &) |
| void | uiReceived (GfxWindow &, UInt32 uid) |
| GLUI user interface event. | |
| void | idleReceived () |
| void | render (bool debug_stretch, bool debug_shear, bool debug_bend) |
| void | snap (bool debug) |
Private Types | |
| enum | { ID_CAMERA_ROTATE, ID_ZOOM, ID_LIGHT, ID_FOG_START, ID_FOG_END, ID_AXES, ID_WIREFRAME, ID_CLOTH_SIZE, ID_RUN, ID_STOP, ID_STEP, ID_REWIND, ID_TIME, ID_PATCHES, ID_TIMESTEP, ID_PCG_TOLERANCE, ID_PAR_K_STRETCH, ID_PAR_K_SHEAR, ID_PAR_K_BEND_U, ID_PAR_K_BEND_V, ID_PAR_K_DAMP, ID_PAR_K_DRAG, ID_PAR_B_U, ID_PAR_B_V, ID_PAR_RHO, ID_PAR_G, ID_PAR_RESET, ID_CONSTRAINTS, ID_EN_STRETCH, ID_EN_SHEAR, ID_EN_BEND, ID_TRI_STRETCH, ID_TRI_SHEAR, ID_TRI_BEND, ID_VERT_VEL, ID_VERT_FORCE, ID_VERT_FORCE_DAMP, ID_VERT_FORCE_STRETCH, ID_VERT_FORCE_SHEAR, ID_VERT_FORCE_BEND, ID_VERT_FORCE_GRAVITY, ID_VERT_FORCE_DRAG, ID_SNAPSHOT, ID_MOVIE, ID_QUIT } |
| Control IDs. | |
| enum | ConstraintType { CON_NONE, CON_CENTRE, CON_CORNERS, CON_CORNERS2, CON_CORNERYANK, CON_TABLE_SQUARE, CON_TABLE_CIRCLE, NB_CONSTRAINTS } |
| Constraint IDs. | |
Private Member Functions | |
| void | setupMesh () |
| void | setupSimulator () |
| void | setConstraints () |
| void | setupWindow () |
| void | initGL () |
| void | calcNormals () |
| void | renderCloth () |
| void | renderClothTriDebug (bool showStretch, bool showShear, bool showBend) |
| void | renderClothVertDebug () |
| void | renderClothOutline () |
| void | renderAxes () |
| void | renderFloor () |
| void | updateParamsUI () |
Static Private Member Functions | |
| RCShdPtr< GeMesh > | createRectMesh (Float size, UInt32 nbRows, UInt32 nbColumns) |
| void | initMeshIndices (const GeMesh &mesh, std::vector< UInt32 > &indices) |
Private Attributes | |
| RCShdPtr< GeMesh > | _initialMesh |
| RCShdPtr< GfxGLWindowGLUI > | _glWindow |
| RCShdPtr< GfxGLTexture > | _floorTexture |
| RCShdPtr< GfxGLTexture > | _clothTexture |
| RCShdPtr< SimSimulator > | _simulator |
| GfxConfig | _config |
| std::vector< UInt32 > | _meshIndices |
| Preprocessed list of indices into mesh vertex array. | |
| std::vector< GeVector > | _meshNormals |
| std::vector< GePoint > | _meshTextureVertices |
| RCShdPtr< GeMeshWingedEdge > | _meshWE |
| GePoint | _meshPos |
| SimSimulator::Params | _params |
| UInt32 | _nbPatches |
| Float | _clothSize |
| Float | _h |
| Float | _rho |
| Float | _pcgTolerance |
| ConstraintType | _constraints |
| bool | _quitFlag |
| bool | _rewindFlag |
| bool | _freeRunFlag |
| bool | _stopFlag |
| bool | _stepFlag |
| bool | _snapFlag |
| UInt32 | _snapCount |
| UInt32 | _nextMovieFrame |
| bool | _subStepFlag |
This demonstration application shows off the capabilities of the Freecloth simulator. A lot of auxiliary classes are needed to pull this off, mostly in the gfx/ subdirectory.
Definition at line 81 of file clothApp.h.
1.3-rc3