| plot_qsm3d | R Documentation |
Renders a 3D visualization of tree cylinders (from a Quantitative Structure Model, QSM) using actual geometric radii. Each cylinder is drawn between its start and end coordinates with the radius provided in the QSM data.
plot_qsm3d(qsm, bg = "white", color = "black", alpha = 0.7)
qsm |
A data frame or tibble containing QSM cylinder data with columns:
|
bg |
Background color for the 3D plot. Defaults to |
color |
Cylinder color. Defaults to |
alpha |
Transparency level for cylinders, between 0 (fully transparent) and 1 (fully opaque).
Defaults to |
This function uses rgl to draw 3D cylinders representing each segment of a tree model. It is intended for visualizing QSM output such as that produced by PyTLidar or other tree reconstruction algorithms.
For large models, rendering may be slow because each cylinder is drawn as a separate mesh. Consider downsampling or filtering before plotting.
Opens an interactive 3D rgl window with rendered cylinders.
Returns NULL invisibly.
A 'ggplot' object combining multiple diagnostic panels.
# Load QSM output (example path)
qsm_file = system.file('extdata',"tree_0744_qsm.txt", package='tReeTraits')
qsm = load_qsm(qsm_file)
# Plot with real radii
plot_qsm3d(qsm, color = "forestgreen", alpha = 0.6)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.