Bayeux  3.4.1
Core Foundation library for SuperNEMO
Namespaces | Classes | Typedefs | Enumerations | Functions
geomtools Namespace Reference

Top-level namespace of the Bayeux/geomtools module library. More...

Namespaces

 intersection
 Nested namespace of the Bayeux/geomtools module library (intersection)
 
 stl
 Nested namespace of the Bayeux/geomtools module library (STereoLithography)
 

Classes

class  address_set
 A set of indexes representing subaddresses in a geometry ID (see geomtools::geom_id) More...
 
class  angular_range
 Angular range. More...
 
class  base_hit
 The base class for hit objects that locate events in a geometry model. More...
 
class  base_locator
 
class  blur_spot
 A blur spot is a measurement hit that may represents a vertex with 1D, 2D or 3D dimension. More...
 
class  bounding_data
 Bounding volume data for i_shape_3d derived solid shapes. More...
 
class  box
 The 3D shape model for a box. More...
 
class  circle
 A circular arc (1D shape) More...
 
struct  classified_segment
 A classified segment consists in a 3D segment with a first and a last point in an arbitrary reference frame and which is assigned a property that details if the segment lies inside a volume, outside a volume or is contained on the surface of a volume. More...
 
class  color
 Color. More...
 
class  composite_surface
 The abstract base class for all 2D shapes/surfaces. More...
 
class  cone
 Cone utilities. More...
 
struct  constants
 Some constants. More...
 
class  cylinder
 The 3D shape model for a cylinder. More...
 
class  cylindric_extrusion_boxed_model
 A geometry model implementing a box with a cylindrical extrusion, open on both bottom and top faces of the box. More...
 
class  cylindrical_sector
 A spherical sector (2D shape) More...
 
class  disk
 A disk/ring sector surface (2D shape) More...
 
class  display_data
 
class  ellipse
 A circular arc (1D shape) More...
 
class  ellipsoid
 The 3D shape model for an ellipsoid. More...
 
class  ellipsoid_sector
 The 2D shape/surface model for an ellipsoid sector. More...
 
class  elliptical_cylinder
 The 3D shape model for an elliptical cylinder. More...
 
class  elliptical_cylinder_sector
 The 2D shape/surface model for an elliptical cylinder sector. More...
 
class  elliptical_sector
 A elliptical_sector sector surface (2D shape) More...
 
class  extruded_box
 The 3D shape model for an extruded box. More...
 
class  extruded_box_model
 A geometry model implementing a box with a cylindrical extrusion. More...
 
class  face_identifier
 Identifier of a face attached to a solid shape. More...
 
class  face_info
 Information about the nature and positioning of a face of the solid. More...
 
class  face_intercept_info
 The face_intercept_info class hosts the parameters of. More...
 
class  facet34
 A triangle or convex quadrangle facet of a tessellated solid. More...
 
class  facet_segment
 A segment associated to a facet. More...
 
struct  facet_vertex
 A vertex (corner) of a triangle or quadrangle facet in a tessellated solid. More...
 
class  filled_utils
 
struct  foot_point_on_quadric_finder
 Marching method to find the foot point of a point on the surface of a quadric. More...
 
class  gdml_export
 GDML export class. More...
 
class  gdml_writer
 GDML writer class used by the geomtools GDML export functionalities. More...
 
class  geom_id
 
class  geom_info
 A record for geometry information about a physical volume in a virtual geometry. More...
 
class  geom_map
 
class  geometry_service
 Generic geometry service. More...
 
class  geomtools_driver
 
struct  geomtools_driver_params
 
class  gnuplot_draw
 Drawing primitives for various solid shapes. More...
 
class  gnuplot_drawer
 An Gnuplot driver object responsible of the display of a virtual geometry. More...
 
class  grid_model
 A geometry model implementing a mother box volume with some daughter volumes positioned on a 2D grid. More...
 
struct  has_geom_type_predicate
 Predicate that tests if a geom_info object has a given geometry Id. More...
 
class  helix_3d
 An helix (1D shape) in a 3D space. More...
 
class  i_base_locator
 
class  i_composite_shape_3d
 Base class for binary composite shapes. More...
 
class  i_find_intercept
 Abstract interface for all objects for which we can compute the intercept with a ray emitted from a point. More...
 
class  i_locator
 
class  i_model
 The base class for geometry models. More...
 
class  i_object_3d
 Mother abstract class for all 3D object classes. More...
 
class  i_placement
 Abstract interface for all placement objects. More...
 
class  i_polygon
 Polygon 2D shape. More...
 
class  i_shape_1d
 The abstract base class for all 1D curves/shapes. More...
 
class  i_shape_2d
 The abstract base class for all 2D shapes/surfaces. More...
 
class  i_shape_3d
 Mother abstract class for all 3D solid shapes. More...
 
class  i_stackable
 Abstract base stackable object. More...
 
class  i_wires_3d_rendering
 brief Abstract interface for objects that can describe themselves as a collection of polylines for 3D rendering More...
 
class  i_wires_drawer
 Base class for all shape drawer objects in wires mode. More...
 
class  id_mgr
 
class  id_selector
 A selector of geometry IDs using a specific geometry category. More...
 
class  intersection_3d
 Intersection of two 3D shapes. More...
 
struct  io
 I/O constants for the serialization of vector(2D/3D) and rotation objects. More...
 
class  line_3d
 An line/segment (1D shape) in a 3D space. More...
 
class  logical_volume
 A logical geometry volume (ala GDML) More...
 
class  manager
 Geometry manager for virtual geometry modelling. Main geometry manager for the modelisation of various experimental setups in the framework of the nuclear and particle physics experiments. More...
 
class  mapping
 The geometry ID mapping. More...
 
class  mapping_plugin
 A geometry manager plugin with embeded mapping with its specific mapping rules. More...
 
struct  mapping_utils
 Mapping utilities. More...
 
class  material
 
class  materials_plugin
 A plugin for the geomtools' geometry manager that embeds an isotope/element/material manager. More...
 
class  model_factory
 The factory of geometry models. More...
 
class  model_with_internal_items_tools
 Handler for internal items. More...
 
class  model_with_internal_mesh_data
 Handler to add daughter volumes on a regular 3D mesh in a mother logical volume. More...
 
class  multiple_items_model
 A geometry model implementing a simple box with several daughter volumes. More...
 
class  multiple_placement
 Multiple placement with an arbitrary collection of single placements addressed by index. More...
 
class  overlapping
 Volume overlapping detection algorithms. More...
 
class  physical_volume
 A physical geometry volume (ala GDML) More...
 
class  placement
 The placement for a geometry volume with its translation and rotation with respect to some mother reference frame. More...
 
class  plane
 A plane (2D shape) in a 3D space. More...
 
class  plate_with_hole_model
 A geometry model implementing a box/plate with cylindrical hole This class is similar to the geomtools::cylindric_extrusion_boxed_model class. More...
 
struct  point_on_quadric_finder
 Marching method to find a point on the surface of a quadric. More...
 
class  polycone
 Polycone 3D solid shape. More...
 
class  polyhedra
 Polyhedra 3D solid shape. More...
 
class  polyline_3d
 A sequence of connected linear segments (3D) More...
 
class  quadrangle
 A quadrangle. More...
 
class  quadric
 A general quadric a 3D space. More...
 
class  rectangle
 A rectangular surface (2D shape) More...
 
class  regular_3d_mesh_placement
 Regular 3D mesh placement of small daughter volumes with respect to a mother logical volume. More...
 
class  regular_circular_placement
 Regular circular placement. More...
 
class  regular_grid_placement
 
class  regular_linear_placement
 Regular linear placement. More...
 
class  regular_polygon
 A regular polygon. More...
 
class  replicated_boxed_model
 
class  replicated_circular_model
 
class  replicated_model
 
class  right_circular_conical_frustrum
 Right circular conical frustrum (3D shape) More...
 
class  right_circular_conical_nappe
 Right circular conical nappe (2D shape) More...
 
class  right_polygonal_frustrum
 Right polygonal frustrum (3D shape) More...
 
class  rotated_boxed_model
 A geometry model implementing a box with an unique rotated boxed model. More...
 
class  rotation_wrapper_type
 Wrapper for rotation object. More...
 
class  sensitive
 
class  shape_factory
 The factory of shapes. More...
 
class  simple_boxed_model
 A geometry model implementing a single box with no daughter volumes. More...
 
class  simple_polygon
 A simple polygon in the XY plane. More...
 
class  simple_shaped_model
 A geometry model implementing an unique simple 3D shape, possibly with internal/daughter volumes. More...
 
class  simple_world_model
 A geometry model implementing a top-level/world box volume with an unique setup daughter volume. More...
 
class  smart_id_locator
 Locator of geometry volumes by thier geometry Id. More...
 
class  sphere
 A spherical volume (3D solid) More...
 
class  spherical_extrusion_box_model
 A box volume with a spherical extrusion. More...
 
class  spherical_extrusion_cylinder_model
 A cylinder volume with a spherical extrusion. More...
 
class  spherical_sector
 A sperical sector (2D shape) More...
 
class  split_segment_wrt_shape
 This algorithm splits a segment, a polyline or a collection of polylines in a sequence of smaller segments that are classified as inside, outside or on surface of a given shape. More...
 
class  stackable
 Static methods and constants to handle stackable data/information. More...
 
class  stackable_data
 Data for stacking along X, Y and/or Z axis. More...
 
class  stacked_model
 A geometry model with some stacked boxed models along a specific axis (X, Y or Z) More...
 
class  subtraction_3d
 Subtraction of two 3D shapes. More...
 
class  surrounded_boxed_model
 A geometry model with a boxed model surrounded by up to 6 other models. More...
 
class  tessellated_solid
 Tessellated solid made of facets. More...
 
class  toroid_nappe
 A toroid nappe (2D shape) More...
 
class  torus
 The 3D shape model for a solid torus. More...
 
class  triangle
 A triangle. More...
 
class  tube
 The 3D shape model for a tube. More...
 
class  union_3d
 Union of two 3D shapes. More...
 
struct  version
 Describe the geomtools API version and features. More...
 
class  visibility
 Utilities to manipulate visibility properties. More...
 
class  wall_solid
 The 3D shape model for a wall solid. More...
 

Typedefs

typedef CLHEP::Hep2Vector vector_2d
 Alias for the CLHEP 2D-vector class. More...
 
typedef CLHEP::Hep3Vector vector_3d
 Alias for the CLHEP 3D-vector class. More...
 
typedef CLHEP::HepRotation rotation_3d
 Alias for the CLHEP 3D-rotation class. More...
 
typedef rotation_3d rotation
 Alias for the 3D-rotation class. More...
 
typedef std::map< std::string, i_model * > models_col_type
 Type alias for dictionary of geometry model plain handles. More...
 
typedef i_model *(* model_creator_type) (const std::string &name_, const datatools::properties &configuration_, models_col_type *models_)
 
typedef std::map< std::string, model_creator_typemodel_creator_dict_type
 
typedef elliptical_cylinder elliptical_tube
 
typedef std::vector< face_infoface_info_collection_type
 Type alias for a collection of face information objects. More...
 
typedef std::map< geom_id, geom_infogeom_info_dict_type
 Dictionary of geometry information objects (key type is: geomtools::geom_id) More...
 
typedef datatools::handle< i_shape_2dshape_2d_handle_type
 Type aliases for a handle to a 2D shape. More...
 
typedef shape_2d_handle_type face_handle_type
 
typedef line_3d segment_3d
 Type alias for the line_3d class. More...
 
typedef model_with_internal_items_tools MWIM
 
typedef right_circular_conical_frustrum conical_frustrum
 Type alias. More...
 
typedef right_circular_conical_nappe conical_nappe
 Type alias. More...
 
typedef right_polygonal_frustrum polygonal_frustrum
 Type alias. More...
 
typedef std::list< vector_2dbasic_polyline_2d
 Alias for a list of 2D vertice as a 2D-polyline. More...
 
typedef std::pair< vector_3d, vector_3dbasic_segment_3d
 Aliases for a segment made of two 3D vertice. More...
 
typedef basic_segment_3d segment_type
 
typedef std::list< vector_3dbasic_polyline_3d
 Aliases for a list of 3D vertice as a 3D-polyline. More...
 
typedef std::list< vector_3dpolyline_type
 
typedef std::vector< vector_3dvertex_col_type
 Aliases for an ordered collection of 3D vertice. More...
 
typedef std::list< polyline_typewires_type
 Alias for a list of 3D-polylines. More...
 
typedef side_2d_type edge_2d_type
 
typedef rotation_wrapper_type rotation_wrapper_t
 Type alias. More...
 

Enumerations

enum  orientation_type {
  ORIENTATION_INVALID = -1, ORIENTATION_VERTICAL = 0, VERTICAL = 0, ORIENTATION_HORIZONTAL = 1,
  HORIZONTAL = 1
}
 Orientation constants. More...
 
enum  direction_flags_type {
  DIRECTION_FLAGS_NONE = 0x0, DIRECTION_FLAGS_BACK = datatools::bit_mask::bit00, DIRECTION_FLAGS_FRONT = datatools::bit_mask::bit01, DIRECTION_FLAGS_LEFT = datatools::bit_mask::bit02,
  DIRECTION_FLAGS_RIGHT = datatools::bit_mask::bit03, DIRECTION_FLAGS_BOTTOM = datatools::bit_mask::bit04, DIRECTION_FLAGS_TOP = datatools::bit_mask::bit05
}
 Direction flags. More...
 
enum  direction_type {
  DIRECTION_INVALID = -1, DIRECTION_BACK = 0, DIRECTION_XMINUS = DIRECTION_BACK, DIRECTION_FRONT = 1,
  DIRECTION_XPLUS = DIRECTION_FRONT, DIRECTION_LEFT = 2, DIRECTION_YMINUS = DIRECTION_LEFT, DIRECTION_RIGHT = 3,
  DIRECTION_YPLUS = DIRECTION_RIGHT, DIRECTION_BOTTOM = 4, DIRECTION_ZMINUS = DIRECTION_BOTTOM, DIRECTION_TOP = 5,
  DIRECTION_ZPLUS = DIRECTION_TOP
}
 Direction type. More...
 
enum  vertex_1d_type { VERTEX_NONE = 0x0, VERTEX_ALL_BITS = datatools::bit_mask::nbits31, VERTEX_ALL = VERTEX_ALL_BITS }
 
enum  path_1d_type { PATH_NONE = 0x0, PATH_ALL_BITS = datatools::bit_mask::nbits31, PATH_ALL = PATH_ALL_BITS }
 
enum  side_2d_type {
  SIDE_NONE = 0x0, EDGE_NONE = SIDE_NONE, SIDE_ALL_BITS = datatools::bit_mask::nbits31, EDGE_ALL_BITS = SIDE_ALL_BITS,
  SIDE_ALL = SIDE_ALL_BITS, EDGE_ALL = SIDE_ALL
}
 
enum  shape_domain_flags_type {
  SHAPE_DOMAIN_NONE = 0x0, SHAPE_DOMAIN_INSIDE = datatools::bit_mask::bit00, SHAPE_DOMAIN_OUTSIDE = datatools::bit_mask::bit01, SHAPE_DOMAIN_ON_SURFACE = datatools::bit_mask::bit02,
  SHAPE_DOMAIN_INSIDE_DAUGHTER = datatools::bit_mask::bit03, SHAPE_DOMAIN_ON_DAUGHTER_SURFACE = datatools::bit_mask::bit04
}
 Flags determining the position of a point with respect to a 3D shape. More...
 
enum  euler_angles_type {
  EULER_ANGLES_INVALID = -1, EULER_ANGLES_ZXZ = 0, EULER_ANGLES_XYX = 1, EULER_ANGLES_YZY = 2,
  EULER_ANGLES_ZYZ = 3, EULER_ANGLES_XZX = 4, EULER_ANGLES_YXY = 5, EULER_ANGLES_XYZ = 6,
  EULER_ANGLES_YZX = 7, EULER_ANGLES_ZXY = 8, EULER_ANGLES_XZY = 9, EULER_ANGLES_ZYX = 10,
  EULER_ANGLES_YXZ = 11
}
 Type of Euler angles. More...
 
enum  special_rotation_angle_type {
  ROTATION_ANGLE_INVALID = -1, ROTATION_ANGLE_0 = 0, ROTATION_ANGLE_90 = 1, ROTATION_ANGLE_180 = 2,
  ROTATION_ANGLE_270 = 3
}
 Special rotation angle values. More...
 
enum  axis_type { AXIS_INVALID = -1, AXIS_X = 0, AXIS_Y = 1, AXIS_Z = 2 }
 Axis type. More...
 
enum  rotation_axis_type { ROTATION_AXIS_INVALID = -1, ROTATION_AXIS_X = AXIS_X, ROTATION_AXIS_Y = AXIS_Y, ROTATION_AXIS_Z = AXIS_Z }
 Rotation axis type. More...
 

Functions

void print_face_infos (const face_info_collection_type &, std::ostream &out_, const std::string &title_="", const std::string &indent_="")
 Smart print. More...
 
 GEOMTOOLS_MODEL_CLASS_DECLARE (i_boxed_model)
 
void transform_wire_to (const placement &p_, const polyline_type &wire_, polyline_type &tr_wire_)
 Transform a polyline. More...
 
void transform_wires_to (const placement &p_, const wires_type &wires_, wires_type &tr_wires_)
 Transform a collection of polylines. More...
 
bool parse_wires (std::istream &in_, wires_type &wires_)
 Parse a collection of polylines from an ASCII stream. More...
 
void save_wires (std::ostream &out_, const wires_type &wires_, uint32_t flags_=0)
 Save a collection of polylines in an ASCII stream. More...
 
void classify_in_out_segment (const segment_type &segment_, const i_shape_3d &shape_, const placement &shape_placement_, double step_, double tolerance_, std::list< classified_segment > &classified_)
 
void export_gdml (const materials::manager &, gdml_writer &gw_)
 
void export_gdml (const materials::manager &, std::ostream &out_)
 
std::ostream & operator<< (std::ostream &out_, const placement &)
 
std::string get_resource_dir (bool overriden_env=false)
 
std::string get_resource (const std::string &rname, bool overriden_env=false)
 
bool position_is_in (double position_, double start_position_, double delta_position_, double tolerance_=0.0, bool bounds_excluded_=false)
 Check if a position is inside a position interval. More...
 
bool angle_is_in (double angle_, double start_angle_, double delta_angle_, double angular_tolerance_=0.0, bool bounds_excluded_=false)
 Check if an angle is inside an angular interval. More...
 
void print_xy (std::ostream &out_, const vector_2d &p_, bool endl_=true)
 
std::string to_xy (const vector_2d &p_)
 
std::string vector_2d_to_xy (const vector_2d &p_)
 
void print_xy_stdout (const vector_2d &p_)
 
void print_xy_stderr (const vector_2d &p_)
 
void print_xyz (std::ostream &out_, const vector_3d &p_, bool endl_=true)
 
void print (std::ostream &out_, const vector_3d &p_)
 
std::string to_xyz (const vector_3d &p_)
 
std::string vector_3d_to_xyz (const vector_3d &p_)
 
void print_xyz_stdout (const vector_3d &p_)
 
void print_xyz_stderr (const vector_3d &p_)
 
void set_vector_2d (const std::vector< double > &source_, vector_2d &target_)
 
void set_vector_3d (const std::vector< double > &source_, vector_3d &target_)
 
bool parse (std::istream &in_, vector_3d &position_, bool nothing_more_=false)
 Parse a vector 3D object from an input stream. More...
 
bool parse (const std::string &token_, vector_3d &position_)
 Parse a vector 3D object from an input string. More...
 
void print_xy (std::ostream &out_, const basic_polyline_2d &p_, bool endl_=true)
 
std::string to_xy (const basic_polyline_2d &p_)
 
std::string basic_polyline_2d_to_xy (const basic_polyline_2d &p_)
 
void print_xy_stdout (const basic_polyline_2d &p_)
 
void print_xy_stderr (const basic_polyline_2d &p_)
 
void print_xyz (std::ostream &out_, const basic_polyline_3d &p_, bool endl_=true)
 
std::string to_xyz (const basic_polyline_3d &p_)
 
std::string basic_polyline_3d_to_xyz (const basic_polyline_3d &p_)
 
void print_xyz_stdout (const basic_polyline_3d &p_)
 
void print_xyz_stderr (const basic_polyline_3d &p_)
 
direction_type get_direction_from_label (const std::string &)
 
std::string get_direction_label (direction_type)
 
std::string shape_domain_flag_label (shape_domain_flags_type flag_)
 
void create (rotation_3d &rot_, double angle0_, double angle1_, double angle2_, euler_angles_type et_)
 
void create_zyz (rotation_3d &rot_, double phi_, double theta_, double delta_)
 
void create (rotation_3d &rot_, double phi_, double theta_, double delta_)
 
void create_zxz (rotation_3d &rot_, double phi_, double theta_, double psi_)
 Create a rotation using ZXZ Euler angles. More...
 
void create_xyz (rotation_3d &rot_, double phi_, double theta_, double psi_)
 Create a rotation using XYZ Euler angles. More...
 
void create_rotation_3d (rotation_3d &rot_, double phi_, double theta_, double delta_)
 
void create_rotation_from_zyz_euler_angles (rotation_3d &rot_, double phi_, double theta_, double delta_)
 
void create_rotation (rotation_3d &rot_, double phi_, double theta_, double delta_)
 
bool is_identity (const rotation_3d &rot_)
 Check if a rotation is the identity. More...
 
void extract_xyz_euler_angle_from_rotation (const rotation_3d &rot_, double &a_, double &b_, double &c_)
 Extract the XYZ Euler angles from a rotation. More...
 
void extract_zyz_euler_angle_from_rotation (const rotation_3d &rot_, double &a_, double &b_, double &c_)
 Extract the ZYZ Euler angles from a rotation. More...
 
bool check_special_rotation_angle (int)
 
double get_special_rotation_angle (int)
 
int get_special_rotation_angle_from_label (const std::string &)
 
std::string get_special_rotation_angle_label (int)
 
bool check_rotation_axis (int)
 
int get_rotation_axis_from_label (const std::string &)
 
std::string get_rotation_label (int)
 
void create_rotation_from_axis (rotation_3d &rot_, int axis_, double angle_)
 
void create_rotation (rotation_3d &rot_, int axis_, double angle_)
 
void create_rotation (rotation_3d &rot_, int axis_, int special_angle_)
 
void create_rotation_from (rotation_3d &rot_, const std::string &)
 
void reset (rotation_3d &rot_)
 Invalidate a rotation 3D object. More...
 
void reset_rotation_3d (rotation_3d &rot_)
 Invalidate a rotation 3D object. More...
 
void tree_dump (const rotation_3d &rot_, std::ostream &out_, const std::string &title_="", const std::string &indent_="")
 Smart print for rotation 3D object. More...
 
void invalidate (rotation_3d &rot_)
 Invalidate a rotation 3D object. More...
 
void rectify (rotation_3d &rot_)
 Rectify a rotation 3D object. More...
 
void invalidate_rotation_3d (rotation_3d &rot_)
 Invalidate a rotation 3D object. More...
 
bool is_valid (const rotation_3d &rot_)
 Check if a rotation 3D object is valid. More...
 
bool is_valid_rotation_3d (const rotation_3d &rot_)
 Check if a rotation 3D object is valid. More...
 
void create (vector_3d &, double x_, double y_, double z_)
 Create/set coordinates of a vector 3D object (cartesian) More...
 
void create_xyz (vector_3d &, double x_, double y_, double z_)
 Create/set coordinates of a vector 3D object (cartesian) More...
 
void create_polar (vector_3d &, double r_, double theta_, double z_)
 Create/set coordinates of a vector 3D object (polar) More...
 
void create_spherical (vector_3d &, double r_, double phi_, double theta_)
 Create/set coordinates of a vector 3D object (spherical) More...
 
void set (vector_3d &vec_, double x_, double y_, double z_)
 Set coordinates of a vector 3D object (cartesian) More...
 
void set_r_theta_phi (vector_3d &vec_, double r_, double theta_, double phi_)
 Set coordinates of a vector 3D object (spherical) More...
 
void set_rho_phi_z (vector_3d &vec_, double rho_, double phi_, double z_)
 Set coordinates of a vector 3D object (polar) More...
 
void zero (vector_3d &vec_)
 Zero a vector 3D object. More...
 
const vector_3dinvalid_vector_3d ()
 Return an invalid vector 3D object (static singleton) More...
 
void invalidate (vector_3d &vec_)
 Invalidate a vector 3D object. More...
 
void invalidate_vector_3d (vector_3d &vec_)
 Invalidate a vector 3D object. More...
 
bool is_valid (const vector_3d &vec_)
 Check if a vector 3D object is valid. More...
 
bool is_valid_vector_3d (const vector_3d &vec_)
 Check if a vector 3D object is valid. More...
 
bool are_near (const vector_3d &vec1_, const vector_3d &vec2_, double tolerance_=constants::DEFAULT_TOLERANCE)
 Check if two vector 3D objects are close to each other given a tolerance. More...
 
bool are_near_vector_3d (const vector_3d &vec1_, const vector_3d &vec2_, double tolerance_)
 Check if two vector 3D objects are close to each other given a tolerance. More...
 
void set (vector_2d &vec_, double x_, double y_)
 Set coordinates of a vector 2D object (cartesian) More...
 
void set_r_phi (vector_2d &vec_, double r_, double phi_)
 Set coordinates of a vector 2D object (polar) More...
 
void zero (vector_2d &vec_)
 Zero a vector 2D object. More...
 
void invalidate (vector_2d &vec_)
 Invalidate a vector 2D object. More...
 
void invalidate_vector_2d (vector_2d &vec_)
 Invalidate a vector 2D object. More...
 
const vector_2dinvalid_vector_2d ()
 Return an invalid vector 2D object (static singleton) More...
 
bool is_valid (const vector_2d &vec_)
 Check if a vector 2D object is valid. More...
 
bool is_valid_vector_2d (const vector_2d &vec_)
 Check if a vector 2D object is valid. More...
 
void vector_2d_to_vector_3d (const vector_2d &v2d_, vector_3d &v3d_)
 Convert a vector 2D object to a vector 3D object (export x and y coordinates, setting z to zero) More...
 
void vector_3d_to_vector_2d (const vector_3d &v3d_, vector_2d &v2d_)
 Convert a vector 3D object to a vector 2D object (export only x and y coordinates) More...
 
void make_phi_theta (vector_3d &vec_, double phi_, double theta_)
 Create a vector 3D object from spherical angular coordinates (magnitude is set to 1) More...
 
template<class ran_func >
void randomize_direction (ran_func &ran_, vector_3d &ran_dir_)
 Isotropically randomize the direction of an unit vector. More...
 
template<class ran_func >
vector_3d randomize_direction (ran_func &ran_)
 Isotropically randomize the direction of an unit vector. More...
 
template<class ran_func >
void randomize_orthogonal_direction (ran_func &ran_, const vector_3d &dir_, vector_3d &ran_dir_)
 Isotropically randomize the direction of an unit vector orthogonal to a given direction. More...
 
template<class ran_func >
vector_3d randomize_orthogonal_direction (ran_func &ran_, const vector_3d &ref_dir_)
 Isotropically randomize the direction of an unit vector orthogonal to a given direction. More...
 
void compute_barycenter (const std::vector< vector_3d > &points_, vector_3d &barycenter_)
 
vector_3d compute_barycenter (const std::vector< vector_3d > &points_)
 
void compute_weighted_barycenter (const std::vector< vector_3d > &points_, const std::vector< double > &weights_, vector_3d &weighted_barycenter_)
 
vector_3d compute_weighted_barycenter (const std::vector< vector_3d > &points_, const std::vector< double > &weights_)
 

Detailed Description

Top-level namespace of the Bayeux/geomtools module library.

mapping_plugin.h

Typedef Documentation

◆ basic_polyline_2d

Alias for a list of 2D vertice as a 2D-polyline.

◆ basic_polyline_3d

Aliases for a list of 3D vertice as a 3D-polyline.

◆ basic_segment_3d

Aliases for a segment made of two 3D vertice.

◆ conical_frustrum

Type alias.

◆ conical_nappe

Type alias.

◆ edge_2d_type

◆ elliptical_tube

◆ face_handle_type

◆ face_info_collection_type

Type alias for a collection of face information objects.

◆ geom_info_dict_type

Dictionary of geometry information objects (key type is: geomtools::geom_id)

◆ model_creator_dict_type

◆ model_creator_type

typedef i_model*(* geomtools::model_creator_type) (const std::string &name_, const datatools::properties &configuration_, models_col_type *models_)

◆ models_col_type

typedef std::map<std::string, i_model *> geomtools::models_col_type

Type alias for dictionary of geometry model plain handles.

◆ MWIM

◆ polygonal_frustrum

Type alias.

◆ polyline_type

typedef std::list<vector_3d> geomtools::polyline_type

◆ rotation

Alias for the 3D-rotation class.

◆ rotation_3d

typedef CLHEP::HepRotation geomtools::rotation_3d

Alias for the CLHEP 3D-rotation class.

◆ rotation_wrapper_t

Type alias.

◆ segment_3d

Type alias for the line_3d class.

◆ segment_type

◆ shape_2d_handle_type

Type aliases for a handle to a 2D shape.

◆ vector_2d

typedef CLHEP::Hep2Vector geomtools::vector_2d

Alias for the CLHEP 2D-vector class.

◆ vector_3d

typedef CLHEP::Hep3Vector geomtools::vector_3d

Alias for the CLHEP 3D-vector class.

◆ vertex_col_type

typedef std::vector<vector_3d> geomtools::vertex_col_type

Aliases for an ordered collection of 3D vertice.

◆ wires_type

Alias for a list of 3D-polylines.

Enumeration Type Documentation

◆ axis_type

Axis type.

Enumerator
AXIS_INVALID 

Invalid axis.

AXIS_X 

X axis.

AXIS_Y 

Y axis.

AXIS_Z 

Z axis.

◆ direction_flags_type

Direction flags.

Enumerator
DIRECTION_FLAGS_NONE 
DIRECTION_FLAGS_BACK 

-x direction

DIRECTION_FLAGS_FRONT 

+x direction

DIRECTION_FLAGS_LEFT 

-y direction

DIRECTION_FLAGS_RIGHT 

+y direction

DIRECTION_FLAGS_BOTTOM 

-z direction

DIRECTION_FLAGS_TOP 

+z direction

◆ direction_type

Direction type.

Enumerator
DIRECTION_INVALID 

Invalid direction.

DIRECTION_BACK 

-x direction

DIRECTION_XMINUS 

-x direction

DIRECTION_FRONT 

+x direction

DIRECTION_XPLUS 

+x direction

DIRECTION_LEFT 

-y direction

DIRECTION_YMINUS 

-y direction

DIRECTION_RIGHT 

+y direction

DIRECTION_YPLUS 

+y direction

DIRECTION_BOTTOM 

-y direction

DIRECTION_ZMINUS 

-y direction

DIRECTION_TOP 

+z direction

DIRECTION_ZPLUS 

+z direction

◆ euler_angles_type

Type of Euler angles.

Enumerator
EULER_ANGLES_INVALID 

Invalid Euler angles.

EULER_ANGLES_ZXZ 

ZXZ classic Euler angles.

EULER_ANGLES_XYX 

XYX classic Euler angles.

EULER_ANGLES_YZY 

YZY classic Euler angles.

EULER_ANGLES_ZYZ 

ZYZ classic Euler angles.

EULER_ANGLES_XZX 

XZX classic Euler angles.

EULER_ANGLES_YXY 

YXY classic Euler angles.

EULER_ANGLES_XYZ 

XYZ Tait-Bryan angles.

EULER_ANGLES_YZX 

YZX Tait-Bryan angles.

EULER_ANGLES_ZXY 

ZXY Tait-Bryan angles.

EULER_ANGLES_XZY 

XZY Tait-Bryan angles.

EULER_ANGLES_ZYX 

ZYX Tait-Bryan angles.

EULER_ANGLES_YXZ 

YXZ Tait-Bryan angles.

◆ orientation_type

Orientation constants.

Enumerator
ORIENTATION_INVALID 

Invalid orientation.

ORIENTATION_VERTICAL 

Vertical orientation.

VERTICAL 

Vertical orientation.

ORIENTATION_HORIZONTAL 

Horizontal orientation.

HORIZONTAL 

Horizontal orientation.

◆ path_1d_type

Enumerator
PATH_NONE 
PATH_ALL_BITS 
PATH_ALL 

◆ rotation_axis_type

Rotation axis type.

Enumerator
ROTATION_AXIS_INVALID 

Invalid rotation axis.

ROTATION_AXIS_X 

X rotation axis.

ROTATION_AXIS_Y 

Y rotation axis.

ROTATION_AXIS_Z 

Z rotation axis.

◆ shape_domain_flags_type

Flags determining the position of a point with respect to a 3D shape.

Enumerator
SHAPE_DOMAIN_NONE 
SHAPE_DOMAIN_INSIDE 
SHAPE_DOMAIN_OUTSIDE 
SHAPE_DOMAIN_ON_SURFACE 
SHAPE_DOMAIN_INSIDE_DAUGHTER 
SHAPE_DOMAIN_ON_DAUGHTER_SURFACE 

◆ side_2d_type

Enumerator
SIDE_NONE 
EDGE_NONE 
SIDE_ALL_BITS 
EDGE_ALL_BITS 
SIDE_ALL 
EDGE_ALL 

◆ special_rotation_angle_type

Special rotation angle values.

Enumerator
ROTATION_ANGLE_INVALID 

Invalid special rotation angle.

ROTATION_ANGLE_0 

Null rotation angle.

ROTATION_ANGLE_90 

90° rotation angle

ROTATION_ANGLE_180 

180° rotation angle

ROTATION_ANGLE_270 

270° rotation angle

◆ vertex_1d_type

Enumerator
VERTEX_NONE 
VERTEX_ALL_BITS 
VERTEX_ALL 

Function Documentation

◆ angle_is_in()

bool geomtools::angle_is_in ( double  angle_,
double  start_angle_,
double  delta_angle_,
double  angular_tolerance_ = 0.0,
bool  bounds_excluded_ = false 
)

Check if an angle is inside an angular interval.

◆ are_near()

bool geomtools::are_near ( const vector_3d vec1_,
const vector_3d vec2_,
double  tolerance_ = constants::DEFAULT_TOLERANCE 
)

Check if two vector 3D objects are close to each other given a tolerance.

◆ are_near_vector_3d()

bool geomtools::are_near_vector_3d ( const vector_3d vec1_,
const vector_3d vec2_,
double  tolerance_ 
)

Check if two vector 3D objects are close to each other given a tolerance.

◆ basic_polyline_2d_to_xy()

std::string geomtools::basic_polyline_2d_to_xy ( const basic_polyline_2d p_)

◆ basic_polyline_3d_to_xyz()

std::string geomtools::basic_polyline_3d_to_xyz ( const basic_polyline_3d p_)

◆ check_rotation_axis()

bool geomtools::check_rotation_axis ( int  )

◆ check_special_rotation_angle()

bool geomtools::check_special_rotation_angle ( int  )

◆ classify_in_out_segment()

void geomtools::classify_in_out_segment ( const segment_type segment_,
const i_shape_3d shape_,
const placement shape_placement_,
double  step_,
double  tolerance_,
std::list< classified_segment > &  classified_ 
)

Split a given segment into a collection of classified segments with respect to a given 3D shape/solid volume.

◆ compute_barycenter() [1/2]

void geomtools::compute_barycenter ( const std::vector< vector_3d > &  points_,
vector_3d barycenter_ 
)

Compute the barycenter of a collection of 3D points

  • points_ the input collection of 3D points
  • barycenter_ the output computed barycenter

◆ compute_barycenter() [2/2]

vector_3d geomtools::compute_barycenter ( const std::vector< vector_3d > &  points_)

Compute the barycenter of a collection of 3D points

  • points_ the input collection of 3D points
    Returns
    the computed barycenter

◆ compute_weighted_barycenter() [1/2]

void geomtools::compute_weighted_barycenter ( const std::vector< vector_3d > &  points_,
const std::vector< double > &  weights_,
vector_3d weighted_barycenter_ 
)

Compute the weighted barycenter of a collection of 3D points

  • points_ the input collection of 3D points
  • weights_ the input collection of weights associated to 3D points
  • weighted_barycenter_ the output computed weighted barycenter

◆ compute_weighted_barycenter() [2/2]

vector_3d geomtools::compute_weighted_barycenter ( const std::vector< vector_3d > &  points_,
const std::vector< double > &  weights_ 
)

Compute the weighted barycenter of a collection of 3D points

  • points_ the input collection of 3D points
  • weights_ the input collection of weights associated to 3D points
    Returns
    the computed weighted barycenter

◆ create() [1/3]

void geomtools::create ( rotation_3d rot_,
double  angle0_,
double  angle1_,
double  angle2_,
euler_angles_type  et_ 
)

Create a rotation using Euler angles

Parameters
rot_the rotation matrix to be initialized
angle0_the first Euler angle
angle1_the second Euler angle
angle2_the third Euler angle
et_the type of Euler angles

◆ create() [2/3]

void geomtools::create ( rotation_3d rot_,
double  phi_,
double  theta_,
double  delta_ 
)

Create a rotation (default is using ZYZ Euler angles)

Parameters
rot_the rotation matrix to be initialized
phi_the azimuthal angle
theta_the polar/zenith angle
delta_the tilt angle

◆ create() [3/3]

void geomtools::create ( vector_3d ,
double  x_,
double  y_,
double  z_ 
)

Create/set coordinates of a vector 3D object (cartesian)

◆ create_polar()

void geomtools::create_polar ( vector_3d ,
double  r_,
double  theta_,
double  z_ 
)

Create/set coordinates of a vector 3D object (polar)

◆ create_rotation() [1/3]

void geomtools::create_rotation ( rotation_3d rot_,
double  phi_,
double  theta_,
double  delta_ 
)

Create a rotation (default is using ZYZ Euler angles)

Parameters
rot_the rotation matrix to be initialized
phi_the azimuthal angle
theta_the polar/zenith angle
delta_the tilt angle

◆ create_rotation() [2/3]

void geomtools::create_rotation ( rotation_3d rot_,
int  axis_,
double  angle_ 
)

◆ create_rotation() [3/3]

void geomtools::create_rotation ( rotation_3d rot_,
int  axis_,
int  special_angle_ 
)

◆ create_rotation_3d()

void geomtools::create_rotation_3d ( rotation_3d rot_,
double  phi_,
double  theta_,
double  delta_ 
)

Create a rotation(default is using ZYZ Euler angles)

Parameters
rot_the rotation matrix to be initialized
phi_the azimuthal angle
theta_the polar/zenith angle
delta_the tilt angle

◆ create_rotation_from()

void geomtools::create_rotation_from ( rotation_3d rot_,
const std::string &   
)

◆ create_rotation_from_axis()

void geomtools::create_rotation_from_axis ( rotation_3d rot_,
int  axis_,
double  angle_ 
)

◆ create_rotation_from_zyz_euler_angles()

void geomtools::create_rotation_from_zyz_euler_angles ( rotation_3d rot_,
double  phi_,
double  theta_,
double  delta_ 
)

Create a rotation (default is using ZYZ Euler angles)

Parameters
rot_the rotation matrix to be initialized
phi_the azimuthal angle
theta_the polar/zenith angle
delta_the tilt angle

◆ create_spherical()

void geomtools::create_spherical ( vector_3d ,
double  r_,
double  phi_,
double  theta_ 
)

Create/set coordinates of a vector 3D object (spherical)

◆ create_xyz() [1/2]

void geomtools::create_xyz ( rotation_3d rot_,
double  phi_,
double  theta_,
double  psi_ 
)

Create a rotation using XYZ Euler angles.

◆ create_xyz() [2/2]

void geomtools::create_xyz ( vector_3d ,
double  x_,
double  y_,
double  z_ 
)

Create/set coordinates of a vector 3D object (cartesian)

◆ create_zxz()

void geomtools::create_zxz ( rotation_3d rot_,
double  phi_,
double  theta_,
double  psi_ 
)

Create a rotation using ZXZ Euler angles.

◆ create_zyz()

void geomtools::create_zyz ( rotation_3d rot_,
double  phi_,
double  theta_,
double  delta_ 
)

Create a rotation using ZYZ Euler angles

Parameters
rot_the rotation matrix to be initialized
phi_the azimuthal angle
theta_the polar/zenith angle
delta_the tilt angle

◆ export_gdml() [1/2]

void geomtools::export_gdml ( const materials::manager ,
gdml_writer gw_ 
)

◆ export_gdml() [2/2]

void geomtools::export_gdml ( const materials::manager ,
std::ostream &  out_ 
)

◆ extract_xyz_euler_angle_from_rotation()

void geomtools::extract_xyz_euler_angle_from_rotation ( const rotation_3d rot_,
double &  a_,
double &  b_,
double &  c_ 
)

Extract the XYZ Euler angles from a rotation.

◆ extract_zyz_euler_angle_from_rotation()

void geomtools::extract_zyz_euler_angle_from_rotation ( const rotation_3d rot_,
double &  a_,
double &  b_,
double &  c_ 
)

Extract the ZYZ Euler angles from a rotation.

◆ GEOMTOOLS_MODEL_CLASS_DECLARE()

geomtools::GEOMTOOLS_MODEL_CLASS_DECLARE ( i_boxed_model  )

◆ get_direction_from_label()

direction_type geomtools::get_direction_from_label ( const std::string &  )

◆ get_direction_label()

std::string geomtools::get_direction_label ( direction_type  )

◆ get_resource()

std::string geomtools::get_resource ( const std::string &  rname,
bool  overriden_env = false 
)

Return URL, i.e. a path, to named resource By default the encoded resource root, determined at compile time is used to search for the resource. This can be overriden by setting the GEOMTOOLS_RESOURCE_DIR environment variable to a path holding custom resources.

Parameters
rnamename of resource, given as a path relative to resource root.
overriden_envflag to allow path overriding by the GEOMTOOLS_RESOURCE_DIR environment variable.

◆ get_resource_dir()

std::string geomtools::get_resource_dir ( bool  overriden_env = false)

Return URL, i.e. a path, to the base directory where resource files are installed

Parameters
overriden_envIf set this flag trigger the search for the environment variable GEOMTOOLS_RESOURCE_DIR as a directory path on the filesystem as an alternative base directory for resources in place of the standard installation path

◆ get_rotation_axis_from_label()

int geomtools::get_rotation_axis_from_label ( const std::string &  )

◆ get_rotation_label()

std::string geomtools::get_rotation_label ( int  )

◆ get_special_rotation_angle()

double geomtools::get_special_rotation_angle ( int  )

◆ get_special_rotation_angle_from_label()

int geomtools::get_special_rotation_angle_from_label ( const std::string &  )

◆ get_special_rotation_angle_label()

std::string geomtools::get_special_rotation_angle_label ( int  )

◆ invalid_vector_2d()

const vector_2d& geomtools::invalid_vector_2d ( )

Return an invalid vector 2D object (static singleton)

◆ invalid_vector_3d()

const vector_3d& geomtools::invalid_vector_3d ( )

Return an invalid vector 3D object (static singleton)

◆ invalidate() [1/3]

void geomtools::invalidate ( rotation_3d rot_)

Invalidate a rotation 3D object.

◆ invalidate() [2/3]

void geomtools::invalidate ( vector_3d vec_)

Invalidate a vector 3D object.

◆ invalidate() [3/3]

void geomtools::invalidate ( vector_2d vec_)

Invalidate a vector 2D object.

◆ invalidate_rotation_3d()

void geomtools::invalidate_rotation_3d ( rotation_3d rot_)

Invalidate a rotation 3D object.

◆ invalidate_vector_2d()

void geomtools::invalidate_vector_2d ( vector_2d vec_)

Invalidate a vector 2D object.

◆ invalidate_vector_3d()

void geomtools::invalidate_vector_3d ( vector_3d vec_)

Invalidate a vector 3D object.

◆ is_identity()

bool geomtools::is_identity ( const rotation_3d rot_)

Check if a rotation is the identity.

◆ is_valid() [1/3]

bool geomtools::is_valid ( const rotation_3d rot_)

Check if a rotation 3D object is valid.

◆ is_valid() [2/3]

bool geomtools::is_valid ( const vector_3d vec_)

Check if a vector 3D object is valid.

◆ is_valid() [3/3]

bool geomtools::is_valid ( const vector_2d vec_)

Check if a vector 2D object is valid.

◆ is_valid_rotation_3d()

bool geomtools::is_valid_rotation_3d ( const rotation_3d rot_)

Check if a rotation 3D object is valid.

◆ is_valid_vector_2d()

bool geomtools::is_valid_vector_2d ( const vector_2d vec_)

Check if a vector 2D object is valid.

◆ is_valid_vector_3d()

bool geomtools::is_valid_vector_3d ( const vector_3d vec_)

Check if a vector 3D object is valid.

◆ make_phi_theta()

void geomtools::make_phi_theta ( vector_3d vec_,
double  phi_,
double  theta_ 
)

Create a vector 3D object from spherical angular coordinates (magnitude is set to 1)

◆ operator<<()

std::ostream& geomtools::operator<< ( std::ostream &  out_,
const placement  
)

◆ parse() [1/2]

bool geomtools::parse ( std::istream &  in_,
vector_3d position_,
bool  nothing_more_ = false 
)

Parse a vector 3D object from an input stream.

Supported format is:

x y z [(length unit)]

where x, y and z are the cartesian coordinates in an arbitrary reference frame and the lenght unit is passed optionally as a character string representing the unit symbol. Examples:

1.2 3.4 5.6
1.2 3.4 5.6 (mm)

◆ parse() [2/2]

bool geomtools::parse ( const std::string &  token_,
vector_3d position_ 
)

Parse a vector 3D object from an input string.

◆ parse_wires()

bool geomtools::parse_wires ( std::istream &  in_,
wires_type wires_ 
)

Parse a collection of polylines from an ASCII stream.

◆ position_is_in()

bool geomtools::position_is_in ( double  position_,
double  start_position_,
double  delta_position_,
double  tolerance_ = 0.0,
bool  bounds_excluded_ = false 
)

Check if a position is inside a position interval.

◆ print()

void geomtools::print ( std::ostream &  out_,
const vector_3d p_ 
)

◆ print_face_infos()

void geomtools::print_face_infos ( const face_info_collection_type ,
std::ostream &  out_,
const std::string &  title_ = "",
const std::string &  indent_ = "" 
)

Smart print.

◆ print_xy() [1/2]

void geomtools::print_xy ( std::ostream &  out_,
const vector_2d p_,
bool  endl_ = true 
)

◆ print_xy() [2/2]

void geomtools::print_xy ( std::ostream &  out_,
const basic_polyline_2d p_,
bool  endl_ = true 
)

◆ print_xy_stderr() [1/2]

void geomtools::print_xy_stderr ( const vector_2d p_)

◆ print_xy_stderr() [2/2]

void geomtools::print_xy_stderr ( const basic_polyline_2d p_)

◆ print_xy_stdout() [1/2]

void geomtools::print_xy_stdout ( const vector_2d p_)

◆ print_xy_stdout() [2/2]

void geomtools::print_xy_stdout ( const basic_polyline_2d p_)

◆ print_xyz() [1/2]

void geomtools::print_xyz ( std::ostream &  out_,
const vector_3d p_,
bool  endl_ = true 
)

◆ print_xyz() [2/2]

void geomtools::print_xyz ( std::ostream &  out_,
const basic_polyline_3d p_,
bool  endl_ = true 
)

◆ print_xyz_stderr() [1/2]

void geomtools::print_xyz_stderr ( const vector_3d p_)

◆ print_xyz_stderr() [2/2]

void geomtools::print_xyz_stderr ( const basic_polyline_3d p_)

◆ print_xyz_stdout() [1/2]

void geomtools::print_xyz_stdout ( const vector_3d p_)

◆ print_xyz_stdout() [2/2]

void geomtools::print_xyz_stdout ( const basic_polyline_3d p_)

◆ randomize_direction() [1/2]

template<class ran_func >
void geomtools::randomize_direction ( ran_func &  ran_,
vector_3d ran_dir_ 
)

Isotropically randomize the direction of an unit vector.

  • ran_ a function or object-function (functor) with the following operator defined:
    double operator()();
    that must return an uniform deviated random number in the [0,1) range like drand48 does.
  • ran_dir_ the unit vector to be randomized

◆ randomize_direction() [2/2]

template<class ran_func >
vector_3d geomtools::randomize_direction ( ran_func &  ran_)

Isotropically randomize the direction of an unit vector.

  • ran_ a function or object-function (functor) with the following operator defined:
    double operator()();
    that must return an uniform deviated random number in the [0,1) range like drand48 does.
    Returns
    the unit vector to be randomized

◆ randomize_orthogonal_direction() [1/2]

template<class ran_func >
void geomtools::randomize_orthogonal_direction ( ran_func &  ran_,
const vector_3d dir_,
vector_3d ran_dir_ 
)

Isotropically randomize the direction of an unit vector orthogonal to a given direction.

  • ran_ a function or object-function (functor) with the following operator defined:
    double operator()();
    that must return an uniform deviated random number in the [0,1) range like drand48 does.
  • dir_ the direction the randomized unit vector must be orthogonal to
  • ran_dir_ the unit vector to be randomized

◆ randomize_orthogonal_direction() [2/2]

template<class ran_func >
vector_3d geomtools::randomize_orthogonal_direction ( ran_func &  ran_,
const vector_3d ref_dir_ 
)

Isotropically randomize the direction of an unit vector orthogonal to a given direction.

  • ran_ a function or object-function (functor) with the following operator defined:
    double operator()();
    that must return an uniform deviated random number in the [0,1) range like drand48 does.
  • dir_ the direction the randomized unit vector must be orthogonal to
    Returns
    the unit vector to be randomized

◆ rectify()

void geomtools::rectify ( rotation_3d rot_)

Rectify a rotation 3D object.

◆ reset()

void geomtools::reset ( rotation_3d rot_)

Invalidate a rotation 3D object.

◆ reset_rotation_3d()

void geomtools::reset_rotation_3d ( rotation_3d rot_)

Invalidate a rotation 3D object.

◆ save_wires()

void geomtools::save_wires ( std::ostream &  out_,
const wires_type wires_,
uint32_t  flags_ = 0 
)

Save a collection of polylines in an ASCII stream.

◆ set() [1/2]

void geomtools::set ( vector_3d vec_,
double  x_,
double  y_,
double  z_ 
)

Set coordinates of a vector 3D object (cartesian)

◆ set() [2/2]

void geomtools::set ( vector_2d vec_,
double  x_,
double  y_ 
)

Set coordinates of a vector 2D object (cartesian)

◆ set_r_phi()

void geomtools::set_r_phi ( vector_2d vec_,
double  r_,
double  phi_ 
)

Set coordinates of a vector 2D object (polar)

◆ set_r_theta_phi()

void geomtools::set_r_theta_phi ( vector_3d vec_,
double  r_,
double  theta_,
double  phi_ 
)

Set coordinates of a vector 3D object (spherical)

◆ set_rho_phi_z()

void geomtools::set_rho_phi_z ( vector_3d vec_,
double  rho_,
double  phi_,
double  z_ 
)

Set coordinates of a vector 3D object (polar)

◆ set_vector_2d()

void geomtools::set_vector_2d ( const std::vector< double > &  source_,
vector_2d target_ 
)

◆ set_vector_3d()

void geomtools::set_vector_3d ( const std::vector< double > &  source_,
vector_3d target_ 
)

◆ shape_domain_flag_label()

std::string geomtools::shape_domain_flag_label ( shape_domain_flags_type  flag_)

◆ to_xy() [1/2]

std::string geomtools::to_xy ( const vector_2d p_)

◆ to_xy() [2/2]

std::string geomtools::to_xy ( const basic_polyline_2d p_)

◆ to_xyz() [1/2]

std::string geomtools::to_xyz ( const vector_3d p_)

◆ to_xyz() [2/2]

std::string geomtools::to_xyz ( const basic_polyline_3d p_)

◆ transform_wire_to()

void geomtools::transform_wire_to ( const placement p_,
const polyline_type wire_,
polyline_type tr_wire_ 
)

Transform a polyline.

◆ transform_wires_to()

void geomtools::transform_wires_to ( const placement p_,
const wires_type wires_,
wires_type tr_wires_ 
)

Transform a collection of polylines.

◆ tree_dump()

void geomtools::tree_dump ( const rotation_3d rot_,
std::ostream &  out_,
const std::string &  title_ = "",
const std::string &  indent_ = "" 
)

Smart print for rotation 3D object.

◆ vector_2d_to_vector_3d()

void geomtools::vector_2d_to_vector_3d ( const vector_2d v2d_,
vector_3d v3d_ 
)

Convert a vector 2D object to a vector 3D object (export x and y coordinates, setting z to zero)

◆ vector_2d_to_xy()

std::string geomtools::vector_2d_to_xy ( const vector_2d p_)

◆ vector_3d_to_vector_2d()

void geomtools::vector_3d_to_vector_2d ( const vector_3d v3d_,
vector_2d v2d_ 
)

Convert a vector 3D object to a vector 2D object (export only x and y coordinates)

◆ vector_3d_to_xyz()

std::string geomtools::vector_3d_to_xyz ( const vector_3d p_)

◆ zero() [1/2]

void geomtools::zero ( vector_3d vec_)

Zero a vector 3D object.

◆ zero() [2/2]

void geomtools::zero ( vector_2d vec_)

Zero a vector 2D object.