Syntax
h=VLTLplot(VL,TL,[c,so])
Input Parameter
VL : | | Vertex list |
TL : | | Tetrahedrons list |
c : | | color |
so : | | true = single handle, false = separated handles |
Output Parameter
h : | | handles to graphics object |
Copyright 2014-2025 Tim C. Lueth. All rights reserved. The code is the property of Tim C. Lueth and may not be redistributed or modified without explicit written permission. This software may be used free of charge for academic research and teaching purposes only. Commercial use, redistribution, modification, or reverse engineering is strictly prohibited. Access to source code is restricted and granted only under specific agreements. For licensing inquiries or commercial use, please contact: Tim C. Lueth
Algorithm (Workflow)
This algorithm is designed to plot a list of tetrahedrons using the function VLTLplot
. It utilizes the tetramesh
function to render the tetrahedrons either as a single volume or as separate entities.
Input Parameters
- VL: Vertex list - A matrix containing the coordinates of the vertices.
- TL: Tetrahedrons list - A matrix where each row represents a tetrahedron by indexing into the vertex list.
- c: Color - An optional parameter to specify the color of the tetrahedrons. Default is 'r' (red).
- so: Single handle - An optional boolean parameter. If true, all tetrahedrons are plotted as a single graphics object. If false, each tetrahedron is plotted separately. Default is true.
Output
- h: Handles to graphics object - Returns handles to the plotted graphics objects.
Algorithm Steps
- Check if the vertex list
VL
or tetrahedron list TL
is empty. If either is empty, return an empty handle h
.
- Set the default color
c
to 'r' (red). If a color is provided as an argument, use that instead.
- Set the default for
so
(single object) to true. If a value is provided, use that instead.
- Set the colormap using
VLcol
and determine the color mapping cmc
using the specified color c
.
- Set the color limits with
clim([0 7])
.
- If
so
is true, plot all tetrahedrons as a single object using tetramesh
with the color applied to all tetrahedrons.
- If
so
is false, iterate over each tetrahedron and plot them individually using tetramesh
.
- Call
VLFLplotlight(0,1)
to adjust the lighting of the plot.
Algorithm explaination created using ChatGPT on 2025-08-18 23:40. (Please note: No guarantee for the correctness of this explanation)
Last html export of this page out of FM database by TL: 2025-09-21