A window with quadrotors over a floor of 2 m tiles, with posts to see them move against and a start pad. Each drone is two arms in a cross, a body and four rotors, the front one red, and leaves a trail. The positions and the angles come from dynamics::QuadrotorDynamics, whose world is NED; the window's is z up.
More...
#include <quadrotor_view.h>
|
| | QuadrotorView (const std::string &title, const std::vector< QuadrotorStyle > &styles={QuadrotorStyle()}, const std::string &record_dir="", real_t record_rate=10.0) |
| void | follow (uint_t drone) |
| | Follow a drone from behind; the default, with the first drone.
|
| void | fix_camera (const RealColVec3d &eye_ned, const RealColVec3d &target_ned) |
| | Look from eye at target, both in NED [m], instead of following a drone.
|
| void | set_targets (const std::vector< RealColVec3d > &targets_ned) |
| | Show targets at the given NED positions [m]; none by default.
|
| bool | show (const std::vector< const dynamics::QuadrotorDynamics * > &drones, real_t time, const std::string &status) |
| | Draw the drones, one per style, at simulation time [s], with a status line.
|
| chrono::irrlicht::ChVisualSystemIrrlicht & | vis () |
| const FrameRecorder & | recorder () const noexcept |
A window with quadrotors over a floor of 2 m tiles, with posts to see them move against and a start pad. Each drone is two arms in a cross, a body and four rotors, the front one red, and leaves a trail. The positions and the angles come from dynamics::QuadrotorDynamics, whose world is NED; the window's is z up.
The camera follows one of the drones from behind, along its heading, or looks from a fixed place. Targets, drawn as crosses with a line down to the floor, show where a controller is taking the drones. With a record directory, a FrameRecorder writes the window there.
◆ Style
◆ QuadrotorView()
| bitsim::utils::render::QuadrotorView::QuadrotorView |
( |
const std::string & | title, |
|
|
const std::vector< QuadrotorStyle > & | styles = {QuadrotorStyle()}, |
|
|
const std::string & | record_dir = "", |
|
|
real_t | record_rate = 10.0 ) |
- Parameters
-
| title | The title of the window |
| styles | One per drone |
| record_dir | Where to write the window, or empty for nowhere |
| record_rate | Pictures per second of simulation |
◆ fix_camera()
Look from eye at target, both in NED [m], instead of following a drone.
◆ follow()
| void bitsim::utils::render::QuadrotorView::follow |
( |
uint_t | drone | ) |
|
Follow a drone from behind; the default, with the first drone.
◆ recorder()
| const FrameRecorder & bitsim::utils::render::QuadrotorView::recorder |
( |
| ) |
const |
|
inlinenoexcept |
◆ set_targets()
| void bitsim::utils::render::QuadrotorView::set_targets |
( |
const std::vector< RealColVec3d > & | targets_ned | ) |
|
|
inline |
Show targets at the given NED positions [m]; none by default.
◆ show()
Draw the drones, one per style, at simulation time [s], with a status line.
- Returns
- False once the window has been closed
◆ vis()
| chrono::irrlicht::ChVisualSystemIrrlicht & bitsim::utils::render::QuadrotorView::vis |
( |
| ) |
|
|
inline |
The documentation for this class was generated from the following files: