tem_box_type Derived Type

type, public :: tem_box_type

This type contains origin and vec of box in each direction


Inherits

type~~tem_box_type~2~~InheritsGraph type~tem_box_type~2 tem_box_type type~tem_plane_type tem_plane_type type~tem_box_type~2->type~tem_plane_type plane type~tem_triangle_type tem_triangle_type type~tem_plane_type->type~tem_triangle_type triangle

Inherited by

type~~tem_box_type~2~~InheritedByGraph type~tem_box_type~2 tem_box_type type~grw_boxarray_type~2 grw_boxarray_type type~grw_boxarray_type~2->type~tem_box_type~2 val

Contents

Source Code


Components

Type Visibility Attributes Name Initial
real(kind=rk), public :: center(3)

center of the box

real(kind=rk), public :: halfvec(3,3)

vector which defines length of the box in x,y,z direction 1st dimension contains x,y,z coord and 2nd dimension defines three direction of vector. This vector is need to do transformation of box

real(kind=rk), public :: halfwidth(3)

halfwidth of the box from center in each direction. It is computed from halfvec during initialization since it is needed for boxboxoverlap

real(kind=rk), public :: normal(3,3)

unit normal vectors which defines the box orientation. It is computed from halfvec during initialization

logical, public :: only_surface

To choose what to do with intersection of box if only_surface = true than the only the surface of the object is intersected if only_surface = false then the whole object is intersected default is set to false

type(tem_plane_type), public :: plane(6)

For only_surface, box is converted into 6 planes and each plane is converted further into triangles


Source Code

  type tem_box_type
    !> center of the box
    real(kind=rk) :: center(3)
    !> vector which defines length of the box in x,y,z direction
    !! 1st dimension contains x,y,z coord and
    !! 2nd dimension defines three direction of vector.
    !! This vector is need to do transformation of box
    real(kind=rk) :: halfvec(3,3)
    !> halfwidth of the box from center in each direction.
    !! It is computed from halfvec during initialization
    !! since it is needed for boxboxoverlap
    real(kind=rk) :: halfwidth(3)
    !> unit normal vectors which defines the box orientation.
    !! It is computed from halfvec during initialization
    real(kind=rk) :: normal(3,3)
    !> To choose what to do with intersection of box
    !! if only_surface = true than the only the surface of the object
    !! is intersected
    !! if only_surface = false then the whole object is intersected
    !! default is set to false
    logical :: only_surface
    !> For only_surface, box is converted into 6 planes and each
    !! plane is converted further into triangles
    type(tem_plane_type) :: plane(6)
  end type tem_box_type