type_vtk Derived Type

type, public :: type_vtk


Inherits

type~~type_vtk~~InheritsGraph type~type_vtk type_vtk c_ptr c_ptr type~type_vtk->c_ptr handle type~type_dp_3d type_dp_3d type~type_vtk->type~type_dp_3d points type~type_vtk_cell type_vtk_cell type~type_vtk->type~type_vtk_cell cells

Inherited by

type~~type_vtk~~InheritedByGraph type~type_vtk type_vtk type~type_geometry type_geometry type~type_geometry->type~type_vtk vtk type~type_input type_input type~type_input->type~type_geometry geometry

Components

Type Visibility Attributes Name Initial
type(type_vtk_cell), public, allocatable :: cells(:)
character(len=:), public, allocatable :: dataset
character(len=:), public, allocatable :: format
type(c_ptr), private :: handle = c_null_ptr
integer(kind=int32), public :: num_points
integer(kind=int32), public :: num_total_cells
type(type_dp_3d), public :: points
character(len=4), private :: reader_type = "none"

Finalization Procedures

final :: finalize_vtk_object


Type-Bound Procedures

procedure, public :: get_active_region_info

  • private subroutine get_active_region_info(self, unique_ids, ierr)

    Arguments

    Type IntentOptional Attributes Name
    class(type_vtk), intent(in) :: self

    VTK data

    integer(kind=int32), intent(inout), allocatable :: unique_ids(:)
    integer(kind=int32), intent(out) :: ierr

procedure, public :: initialize_vtk => type_vtk_vtk_initialize

  • private subroutine type_vtk_vtk_initialize(self, file_name, cell_id_array_name, field_names, field_values)

    Read VTK file using C++ backend with the handle pattern

    Arguments

    Type IntentOptional Attributes Name
    class(type_vtk), intent(inout) :: self
    character(len=*), intent(in) :: file_name
    character(len=*), intent(in) :: cell_id_array_name
    character(len=*), intent(in), optional :: field_names(:)
    real(kind=real64), intent(inout), optional, allocatable :: field_values(:,:)

procedure, public :: initialize_vtu => type_vtk_vtu_initialize

  • private subroutine type_vtk_vtu_initialize(self, file_name, cell_id_array_name, field_names, field_values)

    Read VTK file using C++ backend with the handle pattern

    Arguments

    Type IntentOptional Attributes Name
    class(type_vtk), intent(inout) :: self
    character(len=*), intent(in) :: file_name
    character(len=*), intent(in) :: cell_id_array_name
    character(len=*), intent(in), optional :: field_names(:)
    real(kind=real64), intent(inout), optional, allocatable :: field_values(:,:)

Source Code

    type :: type_vtk
        character(:), allocatable :: format
        character(:), allocatable :: dataset
        ! VTK Points data
        integer(int32) :: num_points
        type(type_dp_3d) :: points
        ! VTK Cells data
        integer(int32) :: num_total_cells
        type(type_vtk_cell), allocatable :: cells(:)

        type(c_ptr), private :: handle = c_null_ptr
        character(4), private :: reader_type = "none"
    contains
        procedure :: initialize_vtk => type_vtk_vtk_initialize
        procedure :: initialize_vtu => type_vtk_vtu_initialize
        procedure :: get_active_region_info
        final :: finalize_vtk_object
    end type type_vtk