Virtual Testbed
Ship dynamics simulator for extreme conditions
|
Functions that are exported to Guile. More...
Functions | |
SCM | vtb::guile::get_testbed () |
Get the current instance of virtual testbed. More... | |
SCM | vtb::guile::set_testbed (SCM other) |
Replace the current instance of virtual testbed with other . More... | |
SCM | vtb::guile::testbed_gui_start_recording () |
Start screen recording. More... | |
SCM | vtb::guile::testbed_gui_stop_recording () |
Stop screen recording. More... | |
SCM | vtb::guile::testbed_gui_start () |
Start real-time simulation. More... | |
SCM | vtb::guile::testbed_gui_pause () |
Pause real-time simulation (and screen recording). More... | |
SCM | vtb::guile::testbed_gui_stop () |
Stop real-time simulation (and screen recording). More... | |
SCM | vtb::guile::import_asset (SCM rest) |
Import an asset from file using options . Options are specified as rest argument. File path is specified as input-path option. More... | |
SCM | vtb::guile::export_asset (SCM s_asset, SCM rest) |
Export asset asset to file using options . Options are specified as rest argument. File path is specified as output-path option. More... | |
SCM | vtb::guile::convert_asset (SCM s_asset, SCM rest) |
Convert asset asset using options . Options are specified as rest argument. Output format is specified as output-format option. More... | |
SCM | vtb::guile::import_polyhedron (SCM path, SCM rest) |
Import polyhedron from file path using options . Options are specified as rest argument. More... | |
SCM | vtb::guile::export_polyhedron (SCM polyhedron, SCM path, SCM rest) |
Export polyhedron polyhedron to file path using options . Options are specified as rest argument. More... | |
SCM | vtb::guile::import_hull (SCM path, SCM rest) |
Import ship hull from file path using options . Options are specified as rest argument. More... | |
SCM | vtb::guile::import_compartments (SCM path, SCM rest) |
Import ship compartments from file path using options . Options are specified as rest argument. More... | |
SCM | vtb::guile::vtestbed_gc () |
Run garbage collection and all object destructors. More... | |
SCM | vtb::guile::make_compartment (SCM polyhedron, SCM rest) |
Construct ship compartment using polyhedron and optional name. More... | |
SCM | vtb::guile::generate_compartments (SCM hull, SCM nrooms) |
Generate ship compartments for hull using 3-d grid of size nrooms . More... | |
SCM | vtb::guile::make_gerstner_solver (SCM rest) |
Construct Gerstner solver. More... | |
SCM | vtb::guile::make_grid (SCM rest) |
Construct multidimensional rectangular grid. More... | |
SCM | vtb::guile::grid_min (SCM object) |
Get grid lower bound. More... | |
SCM | vtb::guile::grid_max (SCM object) |
Get grid upper bound. More... | |
SCM | vtb::guile::grid_begin_index (SCM object) |
Get grid begin index (inclusive). More... | |
SCM | vtb::guile::grid_end_index (SCM object) |
Get grid end index (exclusive). More... | |
SCM | vtb::guile::make_hull () |
Construct ship hull. More... | |
SCM | vtb::guile::polyhedron_reorder (SCM object) |
Fix face winding. More... | |
SCM | vtb::guile::polyhedron_normalise (SCM object) |
Compute vertex and face normals. More... | |
SCM | vtb::guile::polyhedron_unique (SCM object) |
Remove redundant vertices and faces. More... | |
SCM | vtb::guile::polyhedron_move (SCM object, SCM arg) |
Move the polyhedron to a specified amount in three dimensions. More... | |
SCM | vtb::guile::polyhedron_scale (SCM object, SCM arg) |
Scale the polyhedron by a specified factor in three dimensions. More... | |
SCM | vtb::guile::polyhedron_flip (SCM object, SCM arg) |
Flip the polyhedron relative to the origin in a specified dimension. More... | |
SCM | vtb::guile::polyhedron_mirror (SCM object, SCM arg) |
Mirror the polhedron relative to the origin in a specified dimension. More... | |
SCM | vtb::guile::polyhedron_rotate (SCM object, SCM arg1, SCM arg2) |
Rotate the polhedron relative to the origin in a specified dimension by an angle that is multiple of 90 degrees. More... | |
SCM | vtb::guile::polyhedron_empty (SCM object) |
Check if polyhedron is not initialised. More... | |
SCM | vtb::guile::polyhedron_signed_volume (SCM object) |
Compute signed volume of the polyhedron. More... | |
SCM | vtb::guile::polyhedron_signed_volume_below (SCM object, SCM dimension, SCM level) |
Compute signed volume of the polyhedron below certain level of dimension. More... | |
SCM | vtb::guile::polyhedron_volume (SCM object) |
Compute absolute volume of the polyhedron. More... | |
SCM | vtb::guile::polyhedron_centroid (SCM object) |
Compute centroid of the polyhedron. More... | |
SCM | vtb::guile::polyhedron_bounding_box (SCM object) |
Compute bounding box of the polyhedron. More... | |
SCM | vtb::guile::polyhedron_bounds (SCM object, SCM dimension) |
Compute the extent of the polyhedron in specified dimension. More... | |
SCM | vtb::guile::make_polyhedron () |
Construct polyhedron. More... | |
SCM | vtb::guile::make_ship (SCM rest) |
Construct ship from hull and compartments mass/displacement/draught. More... | |
SCM | vtb::guile::ship_mass (SCM object) |
Get ship mass. More... | |
SCM | vtb::guile::make_testbed (SCM rest) |
Construct virtual testbed. More... | |
SCM | vtb::guile::testbed_policy (SCM object, SCM policy) |
Get policy. More... | |
SCM | vtb::guile::testbed_step (SCM object, SCM dt) |
Simulate one time step dt . More... | |
SCM | vtb::guile::testbed_reset (SCM object) |
Reset virtual testbed state. More... | |
SCM | vtb::guile::testbed_time_instant (SCM object) |
Get current simulation time instant. More... | |
SCM | vtb::guile::testbed_grid (SCM object) |
Get simulation grid. More... | |
SCM | vtb::guile::make_wave (SCM type, SCM rest) |
Construct wave from amplitude, length and direction using dispersion relation. More... | |
SCM | vtb::guile::make_calm_sea_generator () |
Construct calm sea wavy surface generator. More... | |
SCM | vtb::guile::make_plain_wave_generator (SCM rest) |
Construct plain wave wavy surface generator. More... | |
Functions that are exported to Guile.
SCM vtb::guile::convert_asset | ( | SCM | s_asset, |
SCM | rest | ||
) |
Convert asset asset
using options
. Options are specified as rest
argument. Output format is specified as output-format option.
SCM vtb::guile::export_asset | ( | SCM | s_asset, |
SCM | rest | ||
) |
Export asset asset
to file using options
. Options are specified as rest
argument. File path is specified as output-path option.
SCM vtb::guile::export_polyhedron | ( | SCM | polyhedron, |
SCM | path, | ||
SCM | rest | ||
) |
Export polyhedron polyhedron
to file path
using options
. Options are specified as rest
argument.
SCM vtb::guile::generate_compartments | ( | SCM | hull, |
SCM | nrooms | ||
) |
Generate ship compartments for hull
using 3-d grid of size nrooms
.
Fits the grid of rooms in the bounding box of the hull.
Definition at line 53 of file guile/compartment.cc.
SCM vtb::guile::get_testbed | ( | ) |
Get the current instance of virtual testbed.
This can only be done when the pipeline is stopped.
Definition at line 20 of file TestbedPipelineInstance.cc.
SCM vtb::guile::grid_begin_index | ( | SCM | object | ) |
Get grid begin index (inclusive).
Definition at line 271 of file guile/grid.cc.
SCM vtb::guile::grid_end_index | ( | SCM | object | ) |
Get grid end index (exclusive).
Definition at line 288 of file guile/grid.cc.
SCM vtb::guile::grid_max | ( | SCM | object | ) |
SCM vtb::guile::grid_min | ( | SCM | object | ) |
SCM vtb::guile::import_asset | ( | SCM | rest | ) |
Import an asset from file using options
. Options are specified as rest
argument. File path is specified as input-path option.
Definition at line 51 of file assets.cc.
Referenced by vtb::guile::import_compartments(), vtb::guile::import_hull(), and vtb::guile::import_polyhedron().
SCM vtb::guile::import_compartments | ( | SCM | path, |
SCM | rest | ||
) |
Import ship compartments from file path
using options
. Options are specified as rest
argument.
Definition at line 197 of file assets.cc.
References vtb::guile::import_asset().
SCM vtb::guile::import_hull | ( | SCM | path, |
SCM | rest | ||
) |
Import ship hull from file path
using options
. Options are specified as rest
argument.
This function is the same as import-polyhedron but also computes ship mass.
Definition at line 173 of file assets.cc.
References vtb::guile::import_asset().
SCM vtb::guile::import_polyhedron | ( | SCM | path, |
SCM | rest | ||
) |
Import polyhedron from file path
using options
. Options are specified as rest
argument.
Definition at line 115 of file assets.cc.
References vtb::guile::import_asset().
|
inline |
Construct calm sea wavy surface generator.
Definition at line 35 of file wave_generator.cc.
SCM vtb::guile::make_compartment | ( | SCM | polyhedron, |
SCM | rest | ||
) |
Construct ship compartment using polyhedron
and optional name.
Definition at line 32 of file guile/compartment.cc.
|
inline |
SCM vtb::guile::make_grid | ( | SCM | rest | ) |
Construct multidimensional rectangular grid.
Definition at line 169 of file guile/grid.cc.
SCM vtb::guile::make_hull | ( | ) |
|
inline |
Construct plain wave wavy surface generator.
Definition at line 48 of file wave_generator.cc.
|
inline |
Construct polyhedron.
Definition at line 229 of file guile/polyhedron.cc.
SCM vtb::guile::make_ship | ( | SCM | rest | ) |
Construct ship from hull
and compartments
mass/displacement/draught.
Definition at line 32 of file guile/ship.cc.
SCM vtb::guile::make_testbed | ( | SCM | rest | ) |
Construct virtual testbed.
Definition at line 33 of file guile/testbed.cc.
SCM vtb::guile::make_wave | ( | SCM | type, |
SCM | rest | ||
) |
SCM vtb::guile::polyhedron_bounding_box | ( | SCM | object | ) |
Compute bounding box of the polyhedron.
Definition at line 204 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_bounds | ( | SCM | object, |
SCM | dimension | ||
) |
Compute the extent of the polyhedron in specified dimension.
Definition at line 217 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_centroid | ( | SCM | object | ) |
Compute centroid of the polyhedron.
Definition at line 192 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_empty | ( | SCM | object | ) |
Check if polyhedron is not initialised.
Definition at line 142 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_flip | ( | SCM | object, |
SCM | arg | ||
) |
Flip the polyhedron relative to the origin in a specified dimension.
Definition at line 114 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_mirror | ( | SCM | object, |
SCM | arg | ||
) |
Mirror the polhedron relative to the origin in a specified dimension.
Definition at line 123 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_move | ( | SCM | object, |
SCM | arg | ||
) |
Move the polyhedron to a specified amount in three dimensions.
Definition at line 96 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_normalise | ( | SCM | object | ) |
SCM vtb::guile::polyhedron_reorder | ( | SCM | object | ) |
SCM vtb::guile::polyhedron_rotate | ( | SCM | object, |
SCM | arg1, | ||
SCM | arg2 | ||
) |
Rotate the polhedron relative to the origin in a specified dimension by an angle that is multiple of 90 degrees.
Definition at line 133 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_scale | ( | SCM | object, |
SCM | arg | ||
) |
Scale the polyhedron by a specified factor in three dimensions.
Definition at line 105 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_signed_volume | ( | SCM | object | ) |
Compute signed volume of the polyhedron.
Definition at line 154 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_signed_volume_below | ( | SCM | object, |
SCM | dimension, | ||
SCM | level | ||
) |
Compute signed volume of the polyhedron below certain level
of dimension.
Definition at line 166 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_unique | ( | SCM | object | ) |
Remove redundant vertices and faces.
Definition at line 87 of file guile/polyhedron.cc.
SCM vtb::guile::polyhedron_volume | ( | SCM | object | ) |
Compute absolute volume of the polyhedron.
Definition at line 180 of file guile/polyhedron.cc.
SCM vtb::guile::set_testbed | ( | SCM | other | ) |
Replace the current instance of virtual testbed with other
.
This can only be done when the pipeline is stopped.
Definition at line 34 of file TestbedPipelineInstance.cc.
SCM vtb::guile::ship_mass | ( | SCM | object | ) |
SCM vtb::guile::testbed_grid | ( | SCM | object | ) |
Get simulation grid.
Definition at line 107 of file guile/testbed.cc.
SCM vtb::guile::testbed_gui_pause | ( | ) |
Pause real-time simulation (and screen recording).
Definition at line 89 of file TestbedPipelineInstance.cc.
SCM vtb::guile::testbed_gui_start | ( | ) |
Start real-time simulation.
Definition at line 77 of file TestbedPipelineInstance.cc.
SCM vtb::guile::testbed_gui_start_recording | ( | ) |
Start screen recording.
Can be done before or after the pipeline has been started. The screen is recorded os OGV file in the current working directory. When testbed gui is stopped or paused, screen recording is stopped.
Definition at line 51 of file TestbedPipelineInstance.cc.
SCM vtb::guile::testbed_gui_stop | ( | ) |
Stop real-time simulation (and screen recording).
Definition at line 101 of file TestbedPipelineInstance.cc.
SCM vtb::guile::testbed_gui_stop_recording | ( | ) |
Stop screen recording.
This procedure is needed to properly close output file.
Definition at line 65 of file TestbedPipelineInstance.cc.
SCM vtb::guile::testbed_policy | ( | SCM | object, |
SCM | policy | ||
) |
SCM vtb::guile::testbed_reset | ( | SCM | object | ) |
Reset virtual testbed state.
Definition at line 86 of file guile/testbed.cc.
SCM vtb::guile::testbed_step | ( | SCM | object, |
SCM | dt | ||
) |
Simulate one time step dt
.
Definition at line 75 of file guile/testbed.cc.
SCM vtb::guile::testbed_time_instant | ( | SCM | object | ) |
Get current simulation time instant.
Definition at line 97 of file guile/testbed.cc.
|
inline |