Description
Class with static functions which help with the integration of Chrono and Irrlicht 3D rendering library.
#include <ChIrrTools.h>
Static Public Member Functions | |
static void | alignIrrlichtNodeToChronoCsys (irr::scene::ISceneNode *mnode, const ChCoordsys<> &mcoords) |
Function to align an Irrlicht object to a Chrono coordsys. | |
static int | drawAllContactPoints (std::shared_ptr< ChContactContainer > mcontactcontainer, irr::video::IVideoDriver *driver, double mlen=1.0, eCh_ContactsDrawMode drawtype=CONTACT_NORMALS) |
Easy-to-use function which draws contact points used by a ChSystem in the current Irrlicht viewer (the IVideoDriver). More... | |
static int | drawAllContactLabels (std::shared_ptr< ChContactContainer > mcontactcontainer, irr::IrrlichtDevice *device, eCh_ContactsLabelMode labeltype=CONTACT_FORCES_N_VAL, irr::video::SColor mcol=irr::video::SColor(255, 255, 255, 255)) |
Easy-to-use function which draws contact informations as labels at the contact point. | |
static int | drawAllLinks (ChSystem &mphysicalSystem, irr::video::IVideoDriver *driver, double mlen=1.0, eCh_LinkDrawMode drawtype=LINK_REACT_FORCE) |
Easy-to-use function which draws reaction forces in all contacts in current Irrlicht viewer (the IVideoDriver). | |
static int | drawAllLinkLabels (ChSystem &mphysicalSystem, irr::IrrlichtDevice *device, eCh_LinkLabelMode labeltype=LINK_REACT_FORCE_X, irr::video::SColor mcol=irr::video::SColor(255, 255, 255, 255)) |
Easy-to-use function which draws contact informations as labels at the contact point. | |
static int | drawAllBoundingBoxes (ChSystem &mphysicalSystem, irr::video::IVideoDriver *driver) |
Easy-to-use function which draws collision objects bounding boxes for rigid bodies - if they have a collision shape. | |
static int | drawAllCOGs (ChSystem &mphysicalSystem, irr::video::IVideoDriver *driver, double scale=0.01) |
Easy-to-use function which draws coordinate systems of ChBody objects. | |
static int | drawAllLinkframes (ChSystem &mphysicalSystem, irr::video::IVideoDriver *driver, double scale=0.01) |
Easy-to-use function which draws coordinate systems of link frames. | |
static void | drawHUDviolation (irr::video::IVideoDriver *driver, irr::IrrlichtDevice *mdevice, ChSystem &asystem, int mx=10, int my=290, int sx=300, int sy=100, double spfact=100.0) |
– | |
static void | drawChFunction (irr::IrrlichtDevice *mdevice, ChFunction *fx, double xmin=0, double xmax=1, double ymin=-1, double ymax=1, int mx=10, int my=290, int sx=300, int sy=100) |
– | |
static void | drawSegment (irr::video::IVideoDriver *driver, ChVector<> mstart, ChVector<> mend, irr::video::SColor mcol=irr::video::SColor(255, 0, 0, 0), bool use_Zbuffer=false) |
Easy-to-use function to draw segment lines in 3D space, with given color. | |
static void | drawPolyline (irr::video::IVideoDriver *driver, std::vector< ChVector<> > &mpoints, irr::video::SColor mcol=irr::video::SColor(255, 0, 0, 0), bool use_Zbuffer=false) |
Easy-to-use function to draw a polyline in 3D space, given the array of points as a std::vector. | |
static void | drawCircle (irr::video::IVideoDriver *driver, double radius, ChCoordsys<> mpos=CSYSNORM, irr::video::SColor mcol=irr::video::SColor(255, 0, 0, 0), int mresolution=36, bool use_Zbuffer=false) |
Easy-to-use function to draw a circle line in 3D space, with given color. More... | |
static void | drawSpring (irr::video::IVideoDriver *driver, double radius, ChVector<> start, ChVector<> end, irr::video::SColor mcol=irr::video::SColor(255, 0, 0, 0), int mresolution=65, double turns=5, bool use_Zbuffer=false) |
Easy-to-use function to draw a spring in 3D space, with given color. More... | |
static void | drawGrid (irr::video::IVideoDriver *driver, double ustep=0.1, double vstep=0.1, int nu=20, int nv=20, ChCoordsys<> mpos=CSYSNORM, irr::video::SColor mcol=irr::video::SColor(50, 80, 110, 110), bool use_Zbuffer=false) |
Easy-to-use function to draw grids in 3D space, with given orientation, color and spacing. | |
static void | drawColorbar (double vmin, double vmax, const std::string &label, irr::IrrlichtDevice *mdevice, int mx=740, int my=20, int sx=30, int sy=300) |
Easy-to-use function to draw color bar with a color map and 2D legend. More... | |
static void | drawCollisionShapes (ChSystem &asystem, irr::IrrlichtDevice *mdevice, irr::video::SColor mcol=irr::video::SColor(50, 0, 0, 110)) |
Draw the collision shapes as wireframe, overlayed to shapes. More... | |
static void | drawPlot3D (irr::video::IVideoDriver *driver, ChMatrixConstRef X, ChMatrixConstRef Y, ChMatrixConstRef Z, ChCoordsys<> mpos=CSYSNORM, irr::video::SColor mcol=irr::video::SColor(50, 80, 110, 110), bool use_Zbuffer=false) |
– | |
static void | drawProfiler (irr::IrrlichtDevice *device) |
Draw run-time profiler infos. | |
Member Function Documentation
◆ drawAllContactPoints()
|
static |
Easy-to-use function which draws contact points used by a ChSystem in the current Irrlicht viewer (the IVideoDriver).
The contact points are visually represented with short lines, of length mlen, aligned to contact normals.
◆ drawCircle()
|
static |
Easy-to-use function to draw a circle line in 3D space, with given color.
Specify the center as coordsys position. Orientation as coordsys quaternion (default in xy plane)
◆ drawCollisionShapes()
|
static |
Draw the collision shapes as wireframe, overlayed to shapes.
Note: this works only for the Bullet collision system (i.e. not working for Chrono Parallel)
◆ drawColorbar()
|
static |
Easy-to-use function to draw color bar with a color map and 2D legend.
Easy-to-use function to draw color map 2D legend.
◆ drawSpring()
|
static |
Easy-to-use function to draw a spring in 3D space, with given color.
Specify the radius, the end points in absolute space, the resolution (i.e. the number of segments approximating the helix) and the number of turns.
The documentation for this class was generated from the following files:
- /builds/uwsbel/chrono/src/chrono_irrlicht/ChIrrTools.h
- /builds/uwsbel/chrono/src/chrono_irrlicht/ChIrrTools.cpp