get_trunk_file {tree3d}R Documentation

Get Trunk File

Description

This function retrieves a trunk OBJ file. The trunk OBJ file can be used to create a tree trunk in a 3D scene. The function has an option to scale the trunk model based on the radius.

Usage

get_trunk_file(scaled = TRUE, offset = TRUE)

Arguments

scaled

Default TRUE. This parameter determines whether the trunk model should be scaled from a radius of 0.1 to 1. If TRUE, the trunk model will be scaled; otherwise, it will use the original size.

offset

Default TRUE. This parameter determines whether the trunk model should be offset to start at the origin, or centered at the origin (FALSE).

Value

Returns the filename of the selected OBJ file (as a .txt file) for the tree trunk. This file can be used to create tree trunk models in a 3D scene.

Examples

# Fetch an trunk OBJ path
get_trunk_file()

[Package tree3d version 0.1.2 Index]