Skip to content

fossil_remesh

Source: src/lib/fossil_remesh.f90

Dependencies

Contents

Variables

NameTypeAttributesDescription
MAX_VALinteger(kind=I4P)parameter
FEATURE_DIHEDRAL_DEGreal(kind=R8P)parameter
REM_STATUS_OKinteger(kind=I4P)parameter
REM_STATUS_BAD_INPUTinteger(kind=I4P)parameter

Subroutines

isotropic_remesh

fortran
subroutine isotropic_remesh(facet, target_length, iterations, preserve_features, reference_facet, reference_tree, status)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)inoutallocatable
target_lengthreal(kind=R8P)in
iterationsinteger(kind=I4P)in
preserve_featureslogicalin
reference_facettype(facet_object)intarget, optional
reference_treetype(aabb_tree_object)intarget, optional
statusinteger(kind=I4P)outoptional

Call graph

run_split_only

fortran
subroutine run_split_only(facet, target_length, n_iterations)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)inoutallocatable
target_lengthreal(kind=R8P)in
n_iterationsinteger(kind=I4P)in

Call graph

run_split_and_collapse

fortran
subroutine run_split_and_collapse(facet, target_length, n_iterations)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)inoutallocatable
target_lengthreal(kind=R8P)in
n_iterationsinteger(kind=I4P)in

Call graph

run_split_collapse_flip

fortran
subroutine run_split_collapse_flip(facet, target_length, n_iterations)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)inoutallocatable
target_lengthreal(kind=R8P)in
n_iterationsinteger(kind=I4P)in

Call graph

run_full_pipeline

fortran
subroutine run_full_pipeline(facet, target_length, n_iterations, reference_facet, reference_tree)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)inoutallocatable
target_lengthreal(kind=R8P)in
n_iterationsinteger(kind=I4P)in
reference_facettype(facet_object)intarget
reference_treetype(aabb_tree_object)intarget

Call graph

collect_state

fortran
subroutine collect_state(facet, f_v, vcoord, nv, st)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)in
f_vinteger(kind=I4P)outallocatable
vcoordreal(kind=R8P)outallocatable
nvinteger(kind=I4P)out
stinteger(kind=I4P)out

Call graph

materialize

fortran
subroutine materialize(facet, f_v, vcoord, facet_alive)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)inoutallocatable
f_vinteger(kind=I4P)in
vcoordreal(kind=R8P)in
facet_alivelogicalin

Call graph

collect_state_for_edges

fortran
subroutine collect_state_for_edges(facet, f_v, nv, st)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)in
f_vinteger(kind=I4P)outallocatable
nvinteger(kind=I4P)out
stinteger(kind=I4P)out

Call graph

build_edge_list

fortran
subroutine build_edge_list(f_v, e_v, ne)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)in
e_vinteger(kind=I4P)outallocatable
neinteger(kind=I4P)out

Call graph

qsort_he

Attributes: recursive

fortran
subroutine qsort_he(he_lo, he_hi, order, lo, hi)

Arguments

NameTypeIntentAttributesDescription
he_lointeger(kind=I4P)in
he_hiinteger(kind=I4P)in
orderinteger(kind=I4P)inout
lointeger(kind=I4P)in
hiinteger(kind=I4P)in

Call graph

ensure_facet_capacity

fortran
subroutine ensure_facet_capacity(f_v, facet_alive, used, needed)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)inoutallocatable
facet_alivelogicalinoutallocatable
usedinteger(kind=I4P)in
neededinteger(kind=I4P)in

Call graph

build_vertex_lock

fortran
subroutine build_vertex_lock(f_v, vcoord, nv, preserve_features, vertex_locked)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)in
vcoordreal(kind=R8P)in
nvinteger(kind=I4P)in
preserve_featureslogicalin
vertex_lockedlogicaloutallocatable

Call graph

grow_lock

fortran
subroutine grow_lock(vertex_locked, new_size)

Arguments

NameTypeIntentAttributesDescription
vertex_lockedlogicalinoutallocatable
new_sizeinteger(kind=I4P)in

Call graph

apply_split_pass

fortran
subroutine apply_split_pass(L, f_v, vcoord, facet_alive, nv, nf_alive)

Arguments

NameTypeIntentAttributesDescription
Lreal(kind=R8P)in
f_vinteger(kind=I4P)inoutallocatable
vcoordreal(kind=R8P)inoutallocatable
facet_alivelogicalinoutallocatable
nvinteger(kind=I4P)inout
nf_aliveinteger(kind=I4P)inout

Call graph

apply_collapse_pass

fortran
subroutine apply_collapse_pass(L, f_v, vcoord, facet_alive, nf_alive, vertex_locked)

Arguments

NameTypeIntentAttributesDescription
Lreal(kind=R8P)in
f_vinteger(kind=I4P)inoutallocatable
vcoordreal(kind=R8P)inoutallocatable
facet_alivelogicalinoutallocatable
nf_aliveinteger(kind=I4P)inout
vertex_lockedlogicalin

Call graph

build_v2f

fortran
subroutine build_v2f(f_v, facet_alive, v2f, v2f_count)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)in
facet_alivelogicalin
v2finteger(kind=I4P)inout
v2f_countinteger(kind=I4P)inout

Call graph

try_collapse_edge

fortran
subroutine try_collapse_edge(va, vb, f1, f2, target, f_v, vcoord, facet_alive, v2f, v2f_count, nf_alive)

Arguments

NameTypeIntentAttributesDescription
vainteger(kind=I4P)in
vbinteger(kind=I4P)in
f1integer(kind=I4P)in
f2integer(kind=I4P)in
targetreal(kind=R8P)in
f_vinteger(kind=I4P)inout
vcoordreal(kind=R8P)inout
facet_alivelogicalinout
v2finteger(kind=I4P)in
v2f_countinteger(kind=I4P)in
nf_aliveinteger(kind=I4P)inout

Call graph

apply_flip_pass

fortran
subroutine apply_flip_pass(f_v, vcoord, facet_alive, vertex_locked)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)inout
vcoordreal(kind=R8P)in
facet_alivelogicalinout
vertex_lockedlogicalin

Call graph

compute_valences

fortran
subroutine compute_valences(e_v, ne, nv, valence)

Arguments

NameTypeIntentAttributesDescription
e_vinteger(kind=I4P)in
neinteger(kind=I4P)in
nvinteger(kind=I4P)in
valenceinteger(kind=I4P)outallocatable

Call graph

apply_relax_pass

fortran
subroutine apply_relax_pass(f_v, vcoord, facet_alive, reference_facet, reference_tree, vertex_locked)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)in
vcoordreal(kind=R8P)inout
facet_alivelogicalin
reference_facettype(facet_object)in
reference_treetype(aabb_tree_object)in
vertex_lockedlogicalin

Call graph

build_edges_with_facets

fortran
subroutine build_edges_with_facets(f_v, facet_alive, e_v, e_facets, ne)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)in
facet_alivelogicalin
e_vinteger(kind=I4P)outallocatable
e_facetsinteger(kind=I4P)outallocatable
neinteger(kind=I4P)out

Call graph

append_vertex

fortran
subroutine append_vertex(vcoord, nv, x, y, z, v_idx)

Arguments

NameTypeIntentAttributesDescription
vcoordreal(kind=R8P)inoutallocatable
nvinteger(kind=I4P)inout
xreal(kind=R8P)in
yreal(kind=R8P)in
zreal(kind=R8P)in
v_idxinteger(kind=I4P)out

Call graph

replace_facet_with_split

fortran
subroutine replace_facet_with_split(f_v, facet_alive, nf_alive, used, f_old, va, vb, vm, w)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)inoutallocatable
facet_alivelogicalinoutallocatable
nf_aliveinteger(kind=I4P)inout
usedinteger(kind=I4P)inout
f_oldinteger(kind=I4P)in
vainteger(kind=I4P)in
vbinteger(kind=I4P)in
vminteger(kind=I4P)in
winteger(kind=I4P)in

Call graph

append_facet

fortran
subroutine append_facet(f_v, facet_alive, used, vrt, f_idx)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)inoutallocatable
facet_alivelogicalinoutallocatable
usedinteger(kind=I4P)inout
vrtinteger(kind=I4P)in
f_idxinteger(kind=I4P)out

Call graph

qsort_real

Attributes: recursive

fortran
subroutine qsort_real(a, lo, hi)

Arguments

NameTypeIntentAttributesDescription
areal(kind=R8P)inout
lointeger(kind=I4P)in
hiinteger(kind=I4P)in

Call graph

Functions

count_unique_edges

Returns: integer(kind=I4P)

fortran
function count_unique_edges(facet) result(ne)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)in

Call graph

compute_median_edge_length

Returns: real(kind=R8P)

fortran
function compute_median_edge_length(facet) result(med)

Arguments

NameTypeIntentAttributesDescription
facettype(facet_object)in

Call graph

facet_would_flip

Attributes: pure

Returns: logical

fortran
function facet_would_flip(f_v, vcoord, f, va, vb, target) result(yes)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)in
vcoordreal(kind=R8P)in
finteger(kind=I4P)in
vainteger(kind=I4P)in
vbinteger(kind=I4P)in
targetreal(kind=R8P)in

Call graph

cross

Attributes: pure

Returns: real(kind=R8P)

fortran
function cross(a, b) result(c)

Arguments

NameTypeIntentAttributesDescription
areal(kind=R8P)in
breal(kind=R8P)in

Call graph

vertex_neighbor_of

Attributes: pure

Returns: logical

fortran
function vertex_neighbor_of(va, w, f_v, v2f, v2f_count, facet_alive, exclude1, exclude2) result(yes)

Arguments

NameTypeIntentAttributesDescription
vainteger(kind=I4P)in
winteger(kind=I4P)in
f_vinteger(kind=I4P)in
v2finteger(kind=I4P)in
v2f_countinteger(kind=I4P)in
facet_alivelogicalin
exclude1integer(kind=I4P)in
exclude2integer(kind=I4P)in

Call graph

edge_exists

Attributes: pure

Returns: logical

fortran
function edge_exists(e_v, ne, va, vb) result(yes)

Arguments

NameTypeIntentAttributesDescription
e_vinteger(kind=I4P)in
neinteger(kind=I4P)in
vainteger(kind=I4P)in
vbinteger(kind=I4P)in

Call graph

flip_would_break

Attributes: pure

Returns: logical

fortran
function flip_would_break(va, vb, w1, w2, f1, f2, f_v, vcoord) result(yes)

Arguments

NameTypeIntentAttributesDescription
vainteger(kind=I4P)in
vbinteger(kind=I4P)in
w1integer(kind=I4P)in
w2integer(kind=I4P)in
f1integer(kind=I4P)in
f2integer(kind=I4P)in
f_vinteger(kind=I4P)in
vcoordreal(kind=R8P)in

Call graph

facet_normal_uv

Attributes: pure

Returns: real(kind=R8P)

fortran
function facet_normal_uv(f_v, vcoord, f) result(n)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)in
vcoordreal(kind=R8P)in
finteger(kind=I4P)in

Call graph

facet_area

Attributes: pure

Returns: real(kind=R8P)

fortran
function facet_area(f_v, vcoord, f) result(area)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)in
vcoordreal(kind=R8P)in
finteger(kind=I4P)in

Call graph

facet_apex

Attributes: pure

Returns: integer(kind=I4P)

fortran
function facet_apex(f_v, f, va, vb) result(w)

Arguments

NameTypeIntentAttributesDescription
f_vinteger(kind=I4P)in
finteger(kind=I4P)in
vainteger(kind=I4P)in
vbinteger(kind=I4P)in

Call graph