Skip to contents

Re-scale mesh based on a fixed area

Usage

scale_area(mesh, target_area = 1)

Arguments

mesh

A triangular mesh of class mesh3d.

target_area

The target area of the scaled 3D mesh. Defaults to 1.

Value

A mesh with area = target_area (1 as default).

Examples

Rvcg::vcgArea(mcap)
#> [1] 0.2698101
mcap_scaled <- scale_area(mcap)
Rvcg::vcgArea(mcap_scaled)
#> [1] 1